#include <NeutronGenerator_FLUKA.h>
Definition at line 10 of file NeutronGenerator_FLUKA.h.
◆ NeutronGenerator_FLUKA()
NeutronGenerator_FLUKA::NeutronGenerator_FLUKA |
( |
| ) |
|
◆ ~NeutronGenerator_FLUKA()
NeutronGenerator_FLUKA::~NeutronGenerator_FLUKA |
( |
| ) |
|
|
virtual |
◆ ClassDef()
◆ Init() [1/2]
Bool_t NeutronGenerator_FLUKA::Init |
( |
const char * |
| ) |
|
|
inline |
◆ Init() [2/2]
Bool_t NeutronGenerator_FLUKA::Init |
( |
const char * |
, |
|
|
int |
|
|
) |
| |
|
inline |
◆ ReadEvent()
Bool_t NeutronGenerator_FLUKA::ReadEvent |
( |
FairPrimaryGenerator * |
cpg | ) |
|
public method ReadEvent
Definition at line 25 of file NeutronGenerator_FLUKA.cxx.
26{
27
29 if (
fn %100000==0) {LOG(INFO)<<
"heartbeat event "<<
fn;}
30 Double_t
Ekin = TMath::Power(10,gRandom->Uniform(-13.,-1.));
32 Double_t
phi = gRandom->Uniform(0,2*TMath::Pi());
33 Double_t
theta = TMath::ACos(gRandom->Uniform(-1,1));
34 Double_t
px =
P*TMath::Sin(theta)*TMath::Cos(phi);
35 Double_t
py =
P*TMath::Sin(theta)*TMath::Sin(phi);
36 Double_t
pz =
P*TMath::Cos(theta);
37 LOG(DEBUG) <<
"NeutronGenerator_FLUKA: " <<
Ekin <<
" " <<
P <<
" " <<
px<<
" "<<
py<<
" "<<
pz;
38
40 phi = gRandom->Uniform(0,2*TMath::Pi());
41 theta = TMath::ACos(gRandom->Uniform(-1,1));
42 Double_t
x =
R*TMath::Sin(theta)*TMath::Cos(phi);
43 Double_t
y =
R*TMath::Sin(theta)*TMath::Sin(phi);
44 Double_t
z =
R*TMath::Cos(theta);
45
46 cpg->AddTrack(2112,px,py,pz,x,y,z,-1,
true,Ekin+
neutronMass,0.,1.,(TMCProcess)0);
47
48 return kTRUE;
49}
◆ SetZ()
void NeutronGenerator_FLUKA::SetZ |
( |
Double_t |
X | ) |
|
|
inline |
◆ fn
int NeutronGenerator_FLUKA::fn |
|
protected |
◆ fNevents
int NeutronGenerator_FLUKA::fNevents |
|
protected |
◆ SND_Z
Double_t NeutronGenerator_FLUKA::SND_Z |
|
protected |
The documentation for this class was generated from the following files: