blase icon indicating copy to clipboard operation
blase copied to clipboard

An attribute (not nn.Param) for Equivalent Width and FWHM

Open gully opened this issue 1 year ago • 0 comments

What we want

An attribute for Equivalent Width. It will have the same shape as lam_centers, amp, sigma, and gamma, but it will not be an nn.Parameter. Just a derived parameter.

How to compute it

Two options:

  1. Analytically This turns out to be impossible for Voigt profiles because the Lorenzian long tails integrate to infinity. However, we could simply provide a number of FWHMs out to which we integrate. This choice has the benefit of operating on a table of derived properties $\sigma$, $A$, $\gamma$.

  2. Numerically Simply torch.sum() the n_lines axis of flux2D, including the size of the pixels in angstroms. Probably np.trapz or equivalent would work better (or scipy quad).

gully avatar Sep 12 '23 15:09 gully