Python math.tau 定数
Python math.tau数学定数 τ = 6.283185... を返します。tau は円周定数であり、2π に等しく、円の周長と半径の比です。
tau の値は 6.283185307179586 です。
構文
math.tau 定数の構文は次のとおりです:
math.tau
戻り値
浮動小数点数 6.283185307179586 を返します。これは円の周長と半径の比を表します。
例
以下の例では tau を返します:
例
# math パッケージをインポート
import math
# tau を出力
print (math.tau)
import math
# tau を出力
print (math.tau)
出力結果:
6.283185307179586その他の拡張
Python math モジュール