usnistgov / MATS

Multi-spectrum Analysis Tool for Spectroscopy
https://pages.nist.gov/MATS/
Other
8 stars 7 forks source link

X-Shift and Simulation Spacing #7

Closed eadkins333 closed 3 years ago

eadkins333 commented 3 years ago

Currently we simulate onto a fine grid and then apply an x-shift and interpolate onto the experimental grid. This means that we need more data points then necessary and the interpolation is a step that could be cut-out (tried before unsuccessfully had weird effect everything past voigt parameters).

  1. If there is no x-shift do we need the interpolation?
  2. Can we add the x-shift on to the line center parameter as it goes into the HTP from database also getting rid of the interpolation?
eadkins333 commented 3 years ago

Wrote new definition of HTP from Dataframe/Model Function to test whether we can get away with simulating directly onto the experimental grid if we take out the interpolation. HTP from Dataframe changes to take the spectrum wavenumber axis as the grid instead of min, max, and spacing. The model function changed by passing the spectrum.wavenumber to the HTP dataframe and also by getting rid of the interpolation code. This seems to have worked! Now the x-shift term is getting applied to move every line center in the simulation by a shift. Because this is applied before the simulation functionality should be retained without having to simulate over such a fine interval. This might come in handy if there are gaps in the spectra.

Closed 12/27/2019