diff --git a/crates/ekore/src/anomalous_dimensions.rs b/crates/ekore/src/anomalous_dimensions.rs index 55a4dad43..ecb2e4038 100644 --- a/crates/ekore/src/anomalous_dimensions.rs +++ b/crates/ekore/src/anomalous_dimensions.rs @@ -1,3 +1,4 @@ //! The anomalous dimensions for |DGLAP| evolution. +pub mod polarized; pub mod unpolarized; diff --git a/crates/ekore/src/anomalous_dimensions/polarized/spacelike/as1.rs b/crates/ekore/src/anomalous_dimensions/polarized/spacelike/as1.rs index 7a12664c9..2eec91867 100644 --- a/crates/ekore/src/anomalous_dimensions/polarized/spacelike/as1.rs +++ b/crates/ekore/src/anomalous_dimensions/polarized/spacelike/as1.rs @@ -2,17 +2,24 @@ use num::complex::Complex; -use super::super::unpolarized::spacelike::as1::gamma_ns; +use super::super::super::unpolarized::spacelike::as1::gamma_ns as unpol; use crate::constants::{CA, CF, TR}; use crate::harmonics::cache::{Cache, K}; +/// Compute the non-singlet anomalous dimension. +/// +/// Identical to the unpolarized counterpart. +pub fn gamma_ns(c: &mut Cache, nf: u8) -> Complex { + unpol(c, nf) +} + /// Compute the quark-gluon anomalous dimension. /// /// Implements Eq. (A.1) of [\[Gluck:1995yr\]][crate::bib::Gluck1995yr]. -pub fn gamma_qg(c: &mut Cache, _nf: u8) -> Complex { +pub fn gamma_qg(c: &mut Cache, nf: u8) -> Complex { let N = c.n(); - let gamma = -(N - 1) / N / (N + 1); - 2.0 * TR * 2.0 * nf * gamma + let gamma = -(N - 1.) / N / (N + 1.); + 2.0 * TR * 2.0 * (nf as f64) * gamma } /// Compute the gluon-quark anomalous dimension. @@ -20,7 +27,7 @@ pub fn gamma_qg(c: &mut Cache, _nf: u8) -> Complex { /// Implements Eq. (A.1) of [\[Gluck:1995yr\]][crate::bib::Gluck1995yr]. pub fn gamma_gq(c: &mut Cache, _nf: u8) -> Complex { let N = c.n(); - let gamma = -(N + 2) / N / (N + 1); + let gamma = -(N + 2.) / N / (N + 1.); 2.0 * CF * gamma } @@ -30,8 +37,8 @@ pub fn gamma_gq(c: &mut Cache, _nf: u8) -> Complex { pub fn gamma_gg(c: &mut Cache, nf: u8) -> Complex { let N = c.n(); let S1 = c.get(K::S1); - let gamma = -S1 + 2 / N / (N + 1); - CA * (-4.0 * gamma - 11.0 / 3.0) + 4.0 / 3.0 * TR * nf; + let gamma = -S1 + 2. / N / (N + 1.); + CA * (-4.0 * gamma - 11.0 / 3.0) + 4.0 / 3.0 * TR * (nf as f64) } /// Compute the singlet anomalous dimension matrix. @@ -54,25 +61,25 @@ mod tests { #[test] fn quark_momentum_conservation() { - const N: Complex = cmplx![2., 0.]; + const N: Complex = cmplx!(2., 0.); let mut c = Cache::new(N); let me = gamma_ns(&mut c, NF) + gamma_gq(&mut c, NF); - assert_approx_eq_cmplx!(f64, me, Complex::zero(), epsilon = 1e-12); + assert_approx_eq_cmplx!(f64, me, cmplx!((4. * CF) / 3., 0.), epsilon = 1e-12); } #[test] fn gluon_momentum_conservation() { - const N: Complex = cmplx![2., 0.]; + const N: Complex = cmplx!(2., 0.); let mut c = Cache::new(N); let me = gamma_qg(&mut c, NF) + gamma_gg(&mut c, NF); - assert_approx_eq_cmplx!(f64, me, Complex::zero(), epsilon = 1e-12); + assert_approx_eq_cmplx!(f64, me, cmplx!(3. + (NF as f64) / 3., 0.), epsilon = 1e-12); } #[test] fn qg_helicity_conservation() { - const N: Complex = cmplx![1., 0.]; + const N: Complex = cmplx!(1., 0.); let mut c = Cache::new(N); let me = gamma_qg(&mut c, NF); - assert_approx_eq_cmplx!(f64, me, Complex::Zero(), epsilon = 1e-12); + assert_approx_eq_cmplx!(f64, me, Complex::zero(), epsilon = 1e-12); } }