Closed cmbergmann closed 2 years ago
I figured out what it is doing wrong with the relative intensities: instead of using the relative intensities for each line, the code uses the average of the relative intensities of the line itself and the next one (zero, in case of the last line). That is the i-th line ends up having (relint(i)+relint(i+1))/2 as its intensity - see screenshots below:
Note in the example above that some lines only appear to have different heights because of the sampling (ie from left to right, lines 1-7, 8-9, 10-14 actually have the same integrated counts). However, lines 8 & 9 as well as 14 are actually different from the others
When creating simulated spectra with the --linelist option (eg a ThAr spectrum), I am not sure if the counts in the spectrum are correct. That is, when providing a line list table in the format "wavelength; relative_intensity", the counts in the lines in the fits file do not seem to be correlated with the relative intensities.
For example, here is an extract of a ThAr linelist showing 6 lines with vastly different relative intensities: 0.93310500; 1 0.93359800; 0 0.93361619; 210 0.93364483; 38 0.93387676; 46 0.93407047; 2400
But the extracted spectrum looks like this:![thar_example](https://user-images.githubusercontent.com/30513033/33468655-07fd1172-d6b2-11e7-8d51-6645be5b6f5c.png)