-
Notifications
You must be signed in to change notification settings - Fork 5
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
Integrating optical photons into restG4 #124
base: master
Are you sure you want to change the base?
Conversation
Looks good to me! This is a good first step towards full-stack optical simulations. Regarding storing additional step information instead of just I would like a more general solution to this problem. For example for hadronic processes such as By the way the link to the Also currently as it stands (I think) this PR is linked to the "big issue" #123 which has a larger scope, if this is merged, that issue will be closed and we don't want that, not until more features are added, examples and documentation included, etc. |
Yes, it's enough to mention it. Linking the issue will close it when this PR is done and we don't want that. |
This PR is related to the Issue #123.
I added G4OpticalPhysics list to PhysicsList and included the optical surfaces headers to the DetectorConstruction class as first stage to include optical photon simulations in
restG4
.Also, I needed to update
TRestPhysicsList::PhysicsListExists
, which I have done in PR rest-for-physics/geant4lib#119.So, to include optical physics in a
restG4
simulation, just add<physicsList name="G4OpticalPhysics"></physicsList>
I have checked the simulation of Optical Boundary processes in
restG4
(ie, reflection, refraction, absorption) with two basic geometries:An example of an absorbed photon:
And a reflected photon:
This geometry is based on the one that can be found in https://github.com/iaxo/iaxo-geometry/blob/master/gdml/IAXO-D1/Veto.gdml
Just an example of an event.
In this case, the red volume doesn't have refractive index so the optical photons are killed when they reach it.
The optical photon generator is configured via rml just using
<source particle="opticalphoton">
. Also,G4OpticalPhoton
have polarization. This has not been implemented so, while running therestG4
simulation with debug verbose level, you will see this message:As Optical Boundary processes are classified as 'Transportation' in
GEANT4
, all of the hits have processName 'Transportation'. Maybe it will be interesting to save more specific information of the hit (if it is refraction, reflection or absorption in dielectric_metal surfaces). As I undestood and did inGEANT4
, for Optical Boundary processes this needs to be done differently, checkingG4Step::GetPostStepPoint()::GetStepStatus()
. Maybe @lobis,@jgalan have some ideas about this?I haven't include the gdml and rml of these examples into this PR, just tell me in case you believe it's necessary.