Index

XGPaint.CIB_Planck2013Type
CIB_Planck2013{T}(; kwargs...)

Define CIB model parameters. Defaults are from Viero et al. 2013. All numbers not typed are converted to type T. This model has the following parameters and default values:

  • nside::Int64 = 4096
  • min_redshift = 0.0
  • max_redshift = 5.0
  • min_mass = 1e12
  • box_size = 40000
  • shang_zplat = 2.0
  • shang_Td = 20.7
  • shang_betan = 1.6
  • shang_eta = 2.4
  • shang_alpha = 0.2
  • shang_Mpeak = 10^12.3
  • shang_sigmaM = 0.3
  • shang_Msmin = 1e11
  • shang_Mmin = 1e10
  • shang_I0 = 92
  • jiang_gamma_1 = 0.13
  • jiang_alpha_1 = -0.83
  • jiang_gamma_2 = 1.33
  • jiang_alpha_2 = -0.02
  • jiang_beta_2 = 5.67
  • jiang_zeta = 1.19
source
XGPaint.CO_CROWNEDType
CO_CROWNED{T}(; kwargs...)

Define broadband CO model parameters. All numbers not typed are converted to type T. This model has the following parameters and default values:

  • nside::Int64 = 4096
  • hod::String = "shang"
source
XGPaint.LRG_Yuan23Type
LRG_Yuan23{T}(; kwargs...)

Define LRG model parameters. Defaults from Yuan et al. 2023 [arXiv:2306.06314]. All numbers not typed are converted to type T. This model has the following parameters and default values:

  • nside::Int64 = 4096
  • hod::String = "zheng"
  • min_redshift = 0.0
  • max_redshift = 5.0
  • min_mass = 1e12
  • box_size = 40000
  • shang_Msmin = 1e11
  • zheng_Mcut = 10^12.7
  • zheng_M1 = 10^13.6
  • zheng_sigma = 0.2
  • zheng_kappa = 0.08
  • zheng_alpha = 1.15
  • yuan_ic = 0.8
  • jiang_gamma_1 = 0.13
  • jiang_alpha_1 = -0.83
  • jiang_gamma_2 = 1.33
  • jiang_alpha_2 = -0.02
  • jiang_beta_2 = 5.67
  • jiang_zeta = 1.19
source
XGPaint.LogInterpolatorProfileType
LogInterpolatorProfile{T, P, I1}

A profile that interpolates over a positive-definite function (θ, z, M_halo), but internally interpolates over log(θ) and log10(M) using a given interpolator. Evaluation of this profile is then done by exponentiating the result of the interpolator.

    f(θ, z, M) = exp(itp(log(θ), z, log10(M)))

This is useful for interpolating over a large range of scales and masses, where the profile is expected to be smooth in log-log space. It wraps the original model and also the interpolator object itself.

source
XGPaint.Radio_Sehgal2009Type
Radio_Sehgal2009{T}(model parameters...)

Define CIB model parameters. Defaults are from Viero et al. 2013.

model = CIBModel{Float32}(a_0=0.4)
source
XGPaint.SZpackMethod
SZpack(model_szp, θ, M_200, z; showT=false)

Outputs the integrated compton-y signal calculated using SZpack along the line of sight. Note: M_200 requires units.

source
XGPaint.SZpack_rkszMethod
SZpack_rksz(model, r, M_200, z, vel, mu)

Computes the relativistic kSZ signal using the SZpack tables.

source
XGPaint.T_mass_calcMethod
T_mass_calc(model,M,z::T; scale_type="Ty", sim_type="combination") where T

Calculates the temperature for a given halo using https://arxiv.org/pdf/2207.05834.pdf.

source
XGPaint.T_vir_calcMethod
T_vir_calc(model, M, z)

Calculates the virial temperature for a given halo using Wang et al. 2007.

source
XGPaint.build_c_lnm2r_interpolatorMethod
build_c_lnm2r_interpolator(;cmin::T=1f-3, cmax::T=25.0f0,
    mmin::T=-7.1f0, mmax::T=0.0f0, nbin=100) where T

Generate a LinearInterpolation object that turns concentration and ln(M_halo) into satellite radius.

source
XGPaint.build_r2z_interpolatorMethod
build_r2z_interpolator(min_z::T, max_z::T,
    cosmo::Cosmology.AbstractCosmology; n_bins=2000) where T

Construct a fast r2z linear interpolator.

source
XGPaint.chunkMethod

Generates a list of tuples which describe starting and ending chunk indices. Useful for parallelizing an array operation.

source
XGPaint.compton_yMethod
compton_y(model, r, M_200c, z)

Calculate the Compton y parameter for a given model at a given radius, mass, and redshift. Mass needs to have units!

source
XGPaint.ellpadMethod

Utility function which prepends some zeros to an array. It makes a copy instead of modifying the input.

source
XGPaint.generate_sourcesMethod
generate_sources(model, cosmo, halo_pos_inp, halo_mass_inp; verbose=true)

Produce a source catalog from a model and halo catalog. This converts the halo arrays into the type specified by model.

Arguments:

  • model::AbstractCIBModel{T}: source model parameters
  • cosmo::Cosmology.FlatLCDM{T}: background cosmology
  • Healpix_res::Resolution: Healpix map resolution
  • halo_pos_inp::AbstractArray{TH,2}: halo positions with dims (3, nhalos)
  • halo_mass_inp::AbstractArray{TH,1}: halo masses

Keywords

  • verbose::Bool=true: print out progress details
source
XGPaint.generate_sourcesMethod
generate_sources(model, cosmo, halo_pos_inp, halo_mass_inp; verbose=true)

Produce a source catalog from a model and halo catalog. This converts the halo arrays into the type specified by model.

Arguments:

  • model::AbstractCIBModel{T}: source model parameters
  • cosmo::Cosmology.FlatLCDM{T}: background cosmology
  • Healpix_res::Resolution: Healpix map resolution
  • halo_pos_inp::AbstractArray{TH,2}: halo positions with dims (3, nhalos)
  • halo_mass_inp::AbstractArray{TH,1}: halo masses

Keywords

  • verbose::Bool=true: print out progress details
source
XGPaint.generate_subhalo_offsetsMethod

Generate an array where the value at index i corresponds to the index of the first source of halo i. Takes an array where the value at index i corresponds to the number of subhalos that halo i has.

source
XGPaint.get_cosmologyMethod
get_cosmology(::Type{T}; h=0.69, Neff=3.04, OmegaK=0.0,
    OmegaM=0.29, OmegaR=nothing, Tcmb=2.7255, w0=-1, wa=0)

Construct a background cosmology. This function duplicates the cosmology() function in Cosmology.jl, but with the numeric type specified.

Arguments:

  • ::Type{T}: numerical type to use for calculations

Keywords

  • h - Dimensionless Hubble constant
  • OmegaK - Curvature density (Ω_k)
  • OmegaM - Matter density (Ω_m)
  • OmegaR - Radiation density (Ω_r)
  • Tcmb - CMB temperature in Kelvin; used to compute Ω_γ
  • Neff - Effective number of massless neutrino species; used to compute Ω_ν
  • w0 - CPL dark energy equation of state; w = w0 + wa(1-a)
  • wa - CPL dark energy equation of state; w = w0 + wa(1-a)

Example

julia> get_cosmology(Float32; h=0.7)
Cosmology.FlatLCDM{Float32}(0.7f0, 0.7099147f0, 0.29f0, 8.5307016f-5)
source
XGPaint.hod_sehgalMethod

Populate halos with radio sources according to the HOD in Sehgal et al. 2009.

The optional rng parameter provides an array of random number generators, one for each thread.

source
XGPaint.load_example_halosMethod

Reads a collection of example halos out of the WebSky halo catalogs, and returns RA (rad), DEC (rad), redshift, and halo mass (M200c).

source
XGPaint.m2rMethod
m2r(m::T, cosmo::Cosmology.FlatLCDM{T}) where T

Convert virial mass to virial radius.

source
XGPaint.mz2cMethod
mz2c(m::T, z::T, cosmo::Cosmology.FlatLCDM{T}) where T

Compute concentration factor from Duffy et al. 2008.

source
XGPaint.paint!Method

Paint a source catalog onto a map.

This function creates the arrays for you.

source
XGPaint.paint!Method
paint!(result_map, nu_obs, model, sources, fluxes_cen, fluxes_sat)

Paint a source catalog onto a map, recording the fluxes in fluxes_cen and fluxes_sat.

Arguments:

  • result_map::HealpixMap{T_map, RingOrder}: Healpix map to paint
  • nu_obs: frequency in Hz
  • model::AbstractCIBModel{T}: source model parameters
  • sources: NamedTuple containing source information from generate_sources
  • fluxes_cen::AbstractArray: buffer for writing fluxes of centrals
  • fluxes_sat::AbstractArray: buffer for writing fluxes of satellites
source
XGPaint.paint!Method
paint!(result_map, model, sources, min_redshift, max_redshift)

'Paint' the LRG catalog onto a map.

Arguments:

  • result_map::HealpixMap{T_map, RingOrder}: Healpix map to paint
  • model::AbstractCIBModel{T}: source model parameters
  • sources: NamedTuple containing source information from generate_sources
  • fluxes_cen::AbstractArray: buffer for writing fluxes of centrals
  • fluxes_sat::AbstractArray: buffer for writing fluxes of satellites
source
XGPaint.queryDiscRing!Method
queryDiscRing!(result, ringinfo, resol::Resolution, theta, phi, radius; fact=0)

In-place calculation of a list of the indices of those pixels whose centers are closer than radius to direction (theta, phi). The three angles radius, theta, and phi must be expressed in radians.

If fact is nonzero, it must be a positive integer; it requires to carry the computation at a resolution fact * nside.

source
XGPaint.rSZ_perturbativeMethod
rSZ_perturbative(model, r, M_200, z; T_scale="virial", sim_type="combination", showT=true)

Calculates the integrated relativistic compton-y signal along the line of sight. Mass requires units.

source
XGPaint.vectorhealpixmapMethod
vecmap([T=Float64], nside::Int)

Generate a map of 3-tuples, showing the (x,y,z) values of the points on the unit 2-sphere for a Healpix map.

source