Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Materials.cc when scaling scint pdf #142

Closed
wants to merge 1 commit into from

Conversation

gmwendel
Copy link
Collaborator

@gmwendel gmwendel commented Jul 3, 2024

Fixes #141. This only applies the Jacobian element to optical ratdb entries with the 'wavelength' key option specified (wavelength_opt == 1). The 'dy_dwavelength' keyword (wavelength_opt == 2) will need a closer look as I am unfamiliar with what y stands for in this context.
EOS_ratpac_jacobian.pdf

When transforming a ratdb entry describing the scintillation or wavelength shifting pdf as a function of wavelength to energy for sampling, the jacobian element hc/E^2 was omitted causing there to be an unphysical distortion in the output spectrum.  This transformation is now implemented
@JamesJieranShen
Copy link
Contributor

As discussed in Slack, the correct approach here is indeed to use the dy_dwavelength mode. We make distinctions since not all properties (as function of energy) requires re-weighting when converted to energy. Example being RINDEX, ABSLENGTH, etc. Close for now. Feel free to re-open if features beyond what is provided in the current options are required. Thanks!

@gmwendel
Copy link
Collaborator Author

gmwendel commented Sep 9, 2024

Yes, after closer inspection this is not the correct way to handle this. Fixing this quirk will take a bit more effort as I have now mentioned in the parent issue.

@gmwendel gmwendel deleted the scint-waveform-patch-1 branch September 9, 2024 22:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Spectrum of properties as a function of wavelength
2 participants