Message: Re: Determining target nucleus in interactions Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

None Re: Determining target nucleus in interactions 

Keywords: target nucleus hadronic process
Forum: Hadronic Processes
Re: Question Determining target nucleus in interactions (Matthew)
Date: 09 Oct, 2007
From: Victor Bom <V.R.Bom@tudelft.nl>

Hi,

I also need to determine the target nucleus.
I try to do in SteppingAction:

const G4HadronicProcess *HPproces = static_cast<const G4HadronicProcess *>
                   (aStep->GetPostStepPoint()->GetProcessDefinedStep());
G4IsoParticleChange *PC =
           new G4IsoParticleChange(HPproces->GetIsotopeProductionInfo());
G4cout << PC->GetIsotope() << G4endl;

So, cast the Process pointer into a pointer to the G4HadronicProcess.
This is very dirty programming.
It only works one time; upon exit of SteppingAction I get a 
segmentation fault.

What is the error I am making here?

Victor Bom
V.R.Bom@tudelft.nl

Inline Depth:
 1 1
 All All
Outline Depth:
 1 1
 2 2
 All All
Add message: (add)

 Add Message Add Message
to: "Re: Determining target nucleus in interactions"

 Subscribe Subscribe

This site runs SLAC HyperNews version 1.11-slac-98, derived from the original HyperNews


[ Geant 4 Home | Geant 4 HyperNews | Search | Request New Forum | Feedback ]