Message: Re: Changing neutron energy Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

Feedback Re: Changing neutron energy 

Forum: Event and Track Management
Re: Question Changing neutron energy (C Mos)
Date: 31 Oct, 2012
From: Gumplinger Peter <Gumplinger Peter>

I am surprised that you can actually do this:


from your SteppingAction. But, yes, SetMomentumDirection is a public method and we even have an example that does just that(!):

I don't know if this, or


works as you expect. It may. However, this is not something you should be doing according to G4's design philosophy. The only object that is supposed to change the state of a track is a G4VProcess. You should be implementing some kind of biasing process that kicks in when your track enters a volume. You make modifications to the tracks parameters by the methods that processes use to affect this. It's all a bit complicated but a look at a simple process will show you how this must be coded.

 Add Message Add Message
to: "Re: Changing neutron energy"

 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 ]