ldmx-sw icon indicating copy to clipboard operation
ldmx-sw copied to clipboard

Introduce a G4 based generator interface with LHE

Open tvami opened this issue 5 months ago • 2 comments

Is your feature request related to a problem? Please describe.

If I read in an LHE, let's say an SM brem, or even specifically a WAB, then both the electron and the WAB is considered a primary. That's not the full realism as the photon is the daughter of the electron.

Describe the solution you'd like

According to Tom there is a way to have this interfaced with G4 using G4DarkBreM

Describe alternatives you've considered

Keep the LHEPrimaryGenerator

Additional context

https://github.com/LDMX-Software/ldmx-sw/pull/1779#discussion_r2219300942

tvami avatar Jul 21 '25 15:07 tvami

@tomeichlersmith maybe you can add more about the "Describe the solution you'd like"?

tvami avatar Jul 21 '25 15:07 tvami

The G4DarkBreM method is really simple. We basically load events into a library and then sample them when Geant4 asks us to (scaling the sampled outgoing kinematics to the G4 energy relative to the library energy). The problem with making this general across all LHE files is that a Geant4 process needs more than just the outgoing kinematics. It also needs a method for calculating the total cross section across materials and energies.

My comment linked above is mainly for future folks. If the folks working on WAB want it to be more realistic, they could write a G4 process that does what G4DarkBreM does, just geared towards the WAB events. The scaling may need to be different since the G4DarkBreM scaling was only developed for dark brem events. They would also need to determine how to calculate the cross section. The scaling question and the cross section question are two large hurdles that prevent an LO analysis using a primary generator from going into an NLO analysis that uses a G4 process. If the scaling used in G4DarkBreM happens to be good enough for WAB, then maybe they could use a lot of the code already present in G4DarkBreM, but I have no reason to expect this to be the case.

I don't think we should attempt to convert the existing LHE generator into a G4 process for the same reason we don't throw away the simulation information in favor of the reconstruction. Analyses need to start on the easiest/ground level and progress towards more realism.

tomeichlersmith avatar Jul 21 '25 15:07 tomeichlersmith