Skip to content

Conventions

These conventions are load-bearing — getting them wrong silently corrupts results. They are enforced throughout the package.

Units

quantity unit
distances / separations Mpc/\(h\)
velocities km/s
\(aH\) km/s/(Mpc/\(h\))

Conversions happen only at I/O boundaries, never inside the physics or numerics layers.

Moment naming

Pairwise velocity moments are named m_ij(r) / c_ij(r):

  • m_ij — moment about the origin; c_ij — central moment.
  • i is the radial order, j is the tangential order.
  • Odd tangential orders vanish by isotropy and are returned as zero automatically.

The dispatcher is PairwiseVelocityMoments.get_moment(r, r_order, t_order, mode) with mode{"m", "c"}.

moment meaning
m_10 mean radial pairwise velocity (negative = infall)
c_20 radial velocity variance \(\sigma_r^2\)
c_02 tangential velocity variance per component \(\sigma_t^2\)
c_30 third radial central moment
c_12 cross moment \(\langle (v_r-\bar v_r)\, v_t^2\rangle\)
c_40, c_04 fourth radial / tangential central moments
c_22 cross moment \(\langle (v_r-\bar v_r)^2\, v_t^2\rangle\)

GaussianPDF needs m_10, c_20, c_02; the skew-\(t\)/GH PDFs additionally use c_30, c_12, c_40, c_04, c_22. Unspecified higher moments default to the Gaussian + independence values (c_40 = 3 c_20², c_22 = c_20 c_02, …).

Do not introduce parallel APIs

TabulatedMoments accepts sigma_r / sigma_t / gamma_r / kappa_r / kappa_t as inputs for user convenience, but converts them internally to c_ij. Do not add parallel sigma_* / gamma_* / kappa_* accessors — the canonical interface is c_ij / m_ij.

LOS projection

project_to_los(moments, n, mode) projects the radial–tangential moments onto the line of sight using the general binomial expansion. It is geometry, not a model choice, and therefore not an ABC. To extend to higher order, add higher-\(c_{ij}\) methods on the moments class — never hand-unroll per-order formulae. Correctness is checked at \(\mu_r \in \{0, 1, 1/\sqrt2\}\) against hand-computed expectations.

Geometry (recap)

The model integrates over \(y\) (real-space parallel separation), with \(r=\sqrt{s_\perp^2+y^2}\) and \(v_\text{los}=aH(s_\parallel-y)\operatorname{sign}(y)\). The PDF signature is pdf(v_los, r_perp, r_par) with r_par ≥ 0 — callers must pass \(|y|\). See The streaming model.