diff --git a/.mailmap b/.mailmap index d8cfde25435..ed00506c00f 100644 --- a/.mailmap +++ b/.mailmap @@ -286,3 +286,5 @@ Israel Roldan AirvZxf airv_zxf Michael Zingale + +Akash Kaushik \ No newline at end of file diff --git a/tardis/spectrum/formal_integral.py b/tardis/spectrum/formal_integral.py index dfe7d755f17..fdbef19ebf8 100644 --- a/tardis/spectrum/formal_integral.py +++ b/tardis/spectrum/formal_integral.py @@ -24,7 +24,7 @@ ) C_INV = 3.33564e-11 -M_PI = np.arccos(-1) +PI = np.pi KB_CGS = 1.3806488e-16 H_CGS = 6.62606957e-27 @@ -197,7 +197,7 @@ def numba_formal_integral( pJred_lu += direction pJblue_lu += direction I_nu[p_idx] *= p - L[nu_idx] = 8 * M_PI * M_PI * trapezoid_integration(I_nu, R_max / N) + L[nu_idx] = 8 * PI * PI * trapezoid_integration(I_nu, R_max / N) return L, I_nu_p @@ -640,7 +640,7 @@ def formal_integral(self, nu, N): I_nu = self.transport.I_nu_p * ps L_test = np.array( [ - 8 * M_PI * M_PI * trapezoid_integration((I_nu)[i, :], R_max / N) + 8 * PI * PI * trapezoid_integration((I_nu)[i, :], R_max / N) for i in range(nu.shape[0]) ] ) diff --git a/tardis/spectrum/formal_integral_cuda.py b/tardis/spectrum/formal_integral_cuda.py index 2a65783e862..d398dc25fd5 100644 --- a/tardis/spectrum/formal_integral_cuda.py +++ b/tardis/spectrum/formal_integral_cuda.py @@ -6,7 +6,7 @@ from tardis.transport.montecarlo.configuration.constants import SIGMA_THOMSON C_INV = 3.33564e-11 -M_PI = np.arccos(-1) +PI = np.pi KB_CGS = 1.3806488e-16 H_CGS = 6.62606957e-27 @@ -28,7 +28,7 @@ def cuda_vector_integrator(L, I_nu, N, R_max): """ nu_idx = cuda.grid(1) L[nu_idx] = ( - 8 * M_PI * M_PI * trapezoid_integration_cuda(I_nu[nu_idx], R_max / N) + 8 * PI * PI * trapezoid_integration_cuda(I_nu[nu_idx], R_max / N) )