xlens.simulator.perturbation.utils
Internal helpers shared by perturbation models.
Functions
|
Convert integer n to zero-padded base-3 string with n_digits |
|
Build the standard result dict returned by |
Module Contents
- _ternary(n: int, n_digits: int) str[source]
Convert integer n to zero-padded base-3 string with n_digits length.
- _get_shear_res_dict(lensed_x, lensed_y, gamma1, gamma2, kappa, has_finite_shear)[source]
Build the standard result dict returned by
distort_galaxymethods.- Parameters:
lensed_x (float) – Post-lensing arcsecond positions on the tangent plane.
lensed_y (float) – Post-lensing arcsecond positions on the tangent plane.
gamma1 (float) – Shear components at the galaxy position.
gamma2 (float) – Shear components at the galaxy position.
kappa (float) – Convergence at the galaxy position.
has_finite_shear (bool) – Whether the shear is physically valid (e.g.
|g| < 1).