1
$\begingroup$

I am working on the GAIA XP sampled spectral data and want to implement XP spectrum correction for extinction. I would like to check if my approach is correct as I am not an astronomer. I followed the gaia documentation here

assuming that the XP spectra $f(\lambda)$ is the observed flux, the corrected $F(\lambda)$ can be computed by $$ F(\lambda)=f(\lambda)⋅10^{0.4A_0 A(\lambda)/3.1} $$

Where $A_0$ is azero_gspphot from here. $A(\lambda)$ is the extinction curve for $\lambda$ in the same range as the sampled XP spectra, but converted to $Å$.

This is my code in python

# wavelengths for xp spectra range in nm
wavelengths  = np.arange(336, 1021, 2)

# extinction curve using fitzpatrick99
# convert nm to angstrom
ext_curve = extinction.fitzpatrick99(wavelengths * 10, 1., 3.1)

# get star info. eg source id 2080220238201704832
star = {
flux: np.array([...]), # array of size 343 representing the sampled xp spectra from
azero: 0.1336,
}

# extinction factor
extinguish = 10** (0.4 * star.azero * ext_curve / 3.1)
corrected_flux = star.flux * extinguish 

# plot
plt.plot(wavelengths, star.flux, label="observed")
plt.plot(wavelengths, corrected_flux)

my questions:

  • According to the documentation here the XP spectra flux is given in $W m^{−2} nm^{−1}$ and $A_0$ is a magnitude quantity. Is there any units conversion I should be doing?

  • Is my assumption that $f(\lambda)$ is the XP spectra? therefore using $0.4$ instead of $-0.4$ in the extinction factor exponent?

  • Is the extinction factor exponent correct? particularly the division by 3.1? I saw a few other tutorials that do not include it. I am not sure if that means it is implicitly there in the library they used or if they're using a different approach.

  • Should convoluting with a filtering kernel (e.g., hydrogen alpha emission) be applied to the XP spectra after the extinction correction?

Thank you

$\endgroup$

1 Answer 1

1
$\begingroup$
  • This is just a unitless number by which the flux is multiplied. The conversion from magnitudes to a factor is handled by the $10^{-0.4}$ bit. Note you should be using $A'(\lambda)$ in the exponent.
  • Yes, I think that is the right way around. The corrected flux should be higher than the observed flux.
  • The factor of 3.1 is a good average for interstellar dust. It was likely assumed when modelling the spectra to derive $A_0$. It is there because of the way $A'(\Lambda)$ is scaled to be 3.1 at 541 nm.
  • Why would you want to convolve with a kernel? (And what do you mean by "e.g. hydrogen alpha emission"? A filtering kernel is some function of wavelength, like a Gaussian.)
$\endgroup$
1
  • $\begingroup$ Thank you so much! For the filtering, it's just because I'm still researching how to apply an H-alpha filter for a spectra. I assumed (perhaps incorrectly) that I would model the delta peak as a gaussian kernel, then convolve over the xp spectra. If this approach is incorrect, what is the proper way to make a filter or a pass band? I probably need to ask in a separate post $\endgroup$
    – RRR
    Commented Oct 25 at 16:57

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .