Chromatic effective PSFs (wcc_sim.chromatic)

Spectrum-weighted effective PSFs and band-averaged extinction factors.

Convolution is linear, so the band-integrated image of a source with photon spectrum S(lambda) equals its surface-brightness model convolved with ONE effective PSF: sum_i w_i PSF(lambda_i), with w_i proportional to the integral of S(lambda) T(lambda) over node sub-bands (T = total throughput, sim.sensor.bandpass). Per-wavelength image convolution is never needed for a component with a single spectrum.

Only the in-focus Airy PSF has a wavelength model; wcc_etc.DefocusPSF is a fixed measured Huygens image and the defocused PSF is geometry-dominated, so focus=1,2 return the monochromatic stamp (documented passthrough).

Reddening enters twice, consistently: attenuation_factor() gives the band-averaged rate multiplier for a Fitzpatrick (1999) R_V=3.1 curve, and band_nodes(ebv=…) reddens the weights so a dusty source also gets a redder effective PSF. wcc_etc itself is never modified.

wcc_sim.chromatic.band_support(sim, frac=0.005)[source]

(lo, hi) wavelength bounds in Angstrom where throughput > frac*peak.

wcc_sim.chromatic.effective_wavelength_m(sim, spectrum, ebv=0.0, rv=3.1)[source]

Photon-weighted effective wavelength [m] of spectrum x throughput.

The wavelength wcc_etc renders a monochromatic PSF at (its Simulation.effective_wavelength), as opposed to the filter pivot that sim.sensor.wavelength holds: the Airy scale is linear in wavelength, and an M5V star through the broad band sits ~130 nm redward of the pivot (issue #20).

wcc_sim.chromatic.band_nodes(sim, spectrum, n_nodes=7, ebv=0.0, rv=3.1)[source]

Node wavelengths [m] and unit-sum weights for the effective PSF.

Weights are S(lambda)*T(lambda) integrals over n_nodes equal sub-bands; each node sits at its sub-band’s flux-weighted mean wavelength.

wcc_sim.chromatic.effective_psf(sim, focus, spectrum=None, oversample=11, stamp_npix=None, jitter_sigma_mas=None, n_nodes=7, ebv=0.0)[source]

Spectrum-weighted oversampled PSF.

Monochromatic passthrough at the pivot wavelength when focus != 0 (no wavelength model) or spectrum is None. With n_nodes == 1 the PSF is monochromatic at the spectrum’s effective wavelength – the ETC’s own choice, and the default for point sources in simulate_field.

wcc_sim.chromatic.effective_psf_for_spt(sim, sensorfilter, spt, ebv, focus, oversample, stamp_npix=None, jitter_sigma_mas=None, n_nodes=7)[source]

Cached effective PSF for one spectral template (+ optional reddening).

spt is coerced to str for the wcc_etc type-is-str dispatch. The cache key resolves jitter/stamp defaults first so equivalent calls share.

wcc_sim.chromatic.effective_wavelength_nm_for_spt(sensorfilter, spt, ebv=0.0)[source]

Effective wavelength [nm] of one spectral template in a sensorfilter.

wcc_sim.chromatic.attenuation_factor(template, ebv, sensorfilter, rv=3.1)[source]

Band-averaged flux attenuation of template for a given E(B-V).

a = int S T 10^(-0.4 A(lambda)) dlambda / int S T dlambda with a Fitzpatrick (1999) curve; the exact broadband dimming factor to apply to the unreddened wcc_etc count rate.