Checking the physics process causing an event

hello everyone
I am bombarding protons on Gadolinium target and recording the energy emitted by the target falling on the detector. I have two energy peaks in the spectrum and I want to know whether they are caused by neutron capture or particle induced X-ray.
I used -
const G4String& procname= step->GetPostStepPoint()->GetProcessDefinedStep()->GetProcessName();

But I am getting process names like - compt
Transportation
eIoni
compt
phot
eIoni
eIoni

Now, how can I get to know about whether the peak is due to the two process I mentioned above ?

Thank you

Hi @deepachoudhary

You can use if condition over the processes. store processes together with energy in ntuples and do post analysis;
if (procname == eIoni) and look the spectra or energy(ies).

Alternatively, you can use if condition in your script to generate multiple spectra from the processes.
VRS

Thank you so much for your reply @drvijayraj . But how can I look at the spectra and judge whether the peak is from neutron capture or x ray emission as they are closely spaced. Can you shed more light on this, I will be grateful.

G4Track has a method G4VProcess* GetCreatorProcess()

maybe this helps you to judge the process that resulted in each detection event?

1 Like

Hello !

So far what I understood from your question that you need to distinguish peaks from two processes. If this is the case, post analysis of the speactra is required. Meaning calculate cross-sectional area of the peak and compare your result with literature. Since calculating cross-sectional area is the robust way to claim the Physics process.

Further, You can implement @Weller 's suggestions togetherwith a suggestion below;

if (track->GetCreatorProcess()) {
  G4cout <<"Creator process is " <<  track->GetCreatorProcess() << G4endl;
 	if (track->GetCreatorProcess()->GetProcessName())
{ G4cout <<"Process Name is  is " <<  track->GetCreatorProcess()->GetProcessName() << G4endl; }

Hope it helps you.

:slight_smile:

VRS

1 Like

Thank you @weller and @drvijayraj . I will try this method and let you know. I highly appreciate your time and efforts.

Thank you so much

Regards
Deepa