riix.utils.constants

mathematical constants computed once here to avoid recomputation

 1"""mathematical constants computed once here to avoid recomputation"""
 2import math
 3
 4# general math constants
 5PI2 = math.pi**2.0
 6THREE_OVER_PI_SQUARED = 3.0 / PI2
 7
 8# glicko constants
 9Q = math.log(10.0) / 400.0
10Q2 = Q**2.0
11Q2_3 = 3.0 * Q2
12Q2_3_OVER_PI2 = Q2_3 / PI2
PI2 = 9.869604401089358
THREE_OVER_PI_SQUARED = 0.3039635509270133
Q = 0.005756462732485115
Q2 = 3.3136863190489995e-05
Q2_3 = 9.941058957146998e-05
Q2_3_OVER_PI2 = 1.007239860196398e-05