Geant4.10
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | Static Public Member Functions
G4INCL::DeltaDecayChannel Class Reference

#include <G4INCLDeltaDecayChannel.hh>

Inheritance diagram for G4INCL::DeltaDecayChannel:
G4INCL::IChannel

Public Member Functions

 DeltaDecayChannel (Particle *, ThreeVector const)
 
virtual ~DeltaDecayChannel ()
 
FinalStategetFinalState ()
 
- Public Member Functions inherited from G4INCL::IChannel
 IChannel ()
 
virtual ~IChannel ()
 

Static Public Member Functions

static G4double computeDecayTime (Particle *p)
 

Detailed Description

Definition at line 47 of file G4INCLDeltaDecayChannel.hh.

Constructor & Destructor Documentation

G4INCL::DeltaDecayChannel::DeltaDecayChannel ( Particle p,
ThreeVector const  dir 
)

Definition at line 45 of file G4INCLDeltaDecayChannel.cc.

46  :theParticle(p), incidentDirection(dir)
47  { }
const char * p
Definition: xmltok.h:285
G4INCL::DeltaDecayChannel::~DeltaDecayChannel ( )
virtual

Definition at line 49 of file G4INCLDeltaDecayChannel.cc.

49 {}

Member Function Documentation

G4double G4INCL::DeltaDecayChannel::computeDecayTime ( Particle p)
static

Definition at line 51 of file G4INCLDeltaDecayChannel.cc.

References G4INCL::ParticleTable::effectiveNucleonMass, G4INCL::ParticleTable::effectivePionMass, G4INCL::Particle::getEnergy(), G4INCL::Particle::getMass(), G4INCL::PhysicalConstants::hc, python.hepunit::m, G4INCL::KinematicsUtils::momentumInCM(), and G4INCL::Random::shoot().

Referenced by G4INCL::StandardPropagationModel::generateDecays().

51  {
52  const G4double m = p->getMass();
53  const G4double g0 = 115.0;
54  G4double gg = g0;
55  if(m > 1500.0) gg = 200.0;
56  const G4double geff = p->getEnergy()/m;
58  const G4double psf = std::pow(qqq, 3)/(std::pow(qqq, 3) + 5832000.0);
59  const G4double tdel = -G4INCL::PhysicalConstants::hc/(gg*psf)*std::log(Random::shoot())*geff;
60  return tdel;
61  }
const char * p
Definition: xmltok.h:285
const G4double hc
[MeV*fm]
G4double momentumInCM(Particle const *const p1, Particle const *const p2)
gives the momentum in the CM frame of two particles.
const G4double effectivePionMass
G4double shoot()
Definition: G4INCLRandom.cc:74
double G4double
Definition: G4Types.hh:76
const G4double effectiveNucleonMass
FinalState * G4INCL::DeltaDecayChannel::getFinalState ( )
virtual

Implements G4INCL::IChannel.

Definition at line 74 of file G4INCLDeltaDecayChannel.cc.

References G4INCL::FinalState::addCreatedParticle(), G4INCL::FinalState::addModifiedParticle(), G4INCL::Particle::adjustEnergyFromMomentum(), G4INCL::DeltaMinus, G4INCL::DeltaPlus, G4INCL::DeltaPlusPlus, G4INCL::DeltaZero, G4INCL::ParticleTable::getINCLMass(), G4INCL::Particle::getMass(), G4INCL::Particle::getPosition(), G4INCL::Particle::getType(), G4INCL::ThreeVector::getX(), G4INCL::ThreeVector::getY(), G4INCL::ThreeVector::getZ(), INCL_FATAL, G4INCL::ThreeVector::mag(), G4INCL::KinematicsUtils::momentumInCM(), G4INCL::Neutron, G4INCL::ThreeVector::perp(), G4INCL::PiMinus, G4InuclParticleNames::pion(), G4INCL::PiPlus, G4INCL::PiZero, G4INCL::Proton, G4INCL::Particle::setHelicity(), G4INCL::Particle::setMomentum(), G4INCL::Particle::setType(), G4INCL::Random::shoot(), plottest35::t1, and G4INCL::UnknownParticle.

74  {
75  // SUBROUTINE DECAY2(P1,P2,P3,WP,ij,
76  // s X1,X2,hel,B1,B2,B3)
77 
78  // This routine describes the anisotropic decay of a particle of mass
79  // xi into 2 particles of masses x1,x2.
80  // The anisotropy is supposed to follow a 1+3*hel*(cos(theta))**2
81  // law with respect to the direction of the incoming particle.
82  // In the input, p1,p2,p3 is the momentum of particle xi.
83  // In the output, p1,p2,p3 is the momentum of particle x1 , while
84  // q1,q2,q3 is the momentum of particle x2.
85 
86  // COMMON/bl12/QQ1(200),QQ2(200),QQ3(200),QQ4(200),
87  // s YY1(200),YY2(200),YY3(200),YM(200),IPI(200)
88  // common/hazard/ial,IY1,IY2,IY3,IY4,IY5,IY6,IY7,IY8,IY9,IY10,
89  // s IY11,IY12,IY13,IY14,IY15,IY16,IY17,IY18,IY19
90 
91  // DATA IY8,IY9,IY10/82345,92345,45681/
92  // PCM(E,A,C)=0.5*SQRT((E**2-(A+C)**2)*(E**2-(A-C)**2))/E P-N20800
93  // XI=YM(ij)
94 
95  // XE=WP P-N20810
96  // B1=P1/XE P-N20820
97  // B2=P2/XE P-N20830
98  // B3=P3/XE
99  // XQ=PCM(XI,X1,X2)
100 
101  const G4double deltaMass = theParticle->getMass();
102 
103  G4double fi, ctet, stet;
104  sampleAngles(&ctet, &stet, &fi);
105 
106  G4double cfi = std::cos(fi);
107  G4double sfi = std::sin(fi);
108  G4double beta = incidentDirection.mag();
109 
110  G4double q1, q2, q3;
111  G4double sal=0.0;
112  if (beta >= 1.0e-10)
113  sal = incidentDirection.perp()/beta;
114  if (sal >= 1.0e-6) {
115  G4double b1 = incidentDirection.getX();
116  G4double b2 = incidentDirection.getY();
117  G4double b3 = incidentDirection.getZ();
118  G4double cal = b3/beta;
119  G4double t1 = ctet+cal*stet*sfi/sal;
120  G4double t2 = stet/sal;
121  q1=(b1*t1+b2*t2*cfi)/beta;
122  q2=(b2*t1-b1*t2*cfi)/beta;
123  q3=(b3*t1/beta-t2*sfi);
124  } else {
125  q1 = stet*cfi;
126  q2 = stet*sfi;
127  q3 = ctet;
128  }
129  theParticle->setHelicity(0.0);
130 
131  ParticleType pionType;
132  switch(theParticle->getType()) {
133  case DeltaPlusPlus:
134  theParticle->setType(Proton);
135  pionType = PiPlus;
136  break;
137  case DeltaPlus:
138  if(Random::shoot() < 1.0/3.0) {
139  theParticle->setType(Neutron);
140  pionType = PiPlus;
141  } else {
142  theParticle->setType(Proton);
143  pionType = PiZero;
144  }
145  break;
146  case DeltaZero:
147  if(Random::shoot() < 1.0/3.0) {
148  theParticle->setType(Proton);
149  pionType = PiMinus;
150  } else {
151  theParticle->setType(Neutron);
152  pionType = PiZero;
153  }
154  break;
155  case DeltaMinus:
156  theParticle->setType(Neutron);
157  pionType = PiMinus;
158  break;
159  default:
160  INCL_FATAL("Unrecognized delta type; type=" << theParticle->getType() << std::endl);
161  pionType = UnknownParticle;
162  break;
163  }
164 
166  theParticle->getMass(),
167  ParticleTable::getINCLMass(pionType));
168 
169  q1 *= xq;
170  q2 *= xq;
171  q3 *= xq;
172 
173  ThreeVector pionMomentum(q1, q2, q3);
174  ThreeVector pionPosition(theParticle->getPosition());
175  Particle *pion = new Particle(pionType, pionMomentum, pionPosition);
176  theParticle->setMomentum(-pionMomentum);
177  theParticle->adjustEnergyFromMomentum();
178 
179  FinalState *fs = new FinalState;
180  fs->addModifiedParticle(theParticle);
181  fs->addCreatedParticle(pion);
182  // call loren(q1,q2,q3,b1,b2,b3,wq)
183  // call loren(p1,p2,p3,b1,b2,b3,wp)
184  // qq1(ij)=q1
185  // qq2(ij)=q2
186  // qq3(ij)=q3
187  // qq4(ij)=wq
188  // ym(ij)=xi
189  // RETURN P-N21120
190  // END P-N21130
191  return fs;
192  }
#define INCL_FATAL(x)
G4double getMass() const
Get the cached particle mass.
G4bool pion(G4int ityp)
G4double adjustEnergyFromMomentum()
Recompute the energy to match the momentum.
G4double momentumInCM(Particle const *const p1, Particle const *const p2)
gives the momentum in the CM frame of two particles.
G4double getINCLMass(const G4int A, const G4int Z)
Get INCL nuclear mass (in MeV/c^2)
G4INCL::ParticleType getType() const
G4double perp() const
const G4INCL::ThreeVector & getPosition() const
tuple t1
Definition: plottest35.py:33
void setType(ParticleType t)
G4double getX() const
G4double shoot()
Definition: G4INCLRandom.cc:74
G4double mag() const
double G4double
Definition: G4Types.hh:76
G4double getZ() const
void setHelicity(G4double h)
virtual void setMomentum(const G4INCL::ThreeVector &momentum)
G4double getY() const

The documentation for this class was generated from the following files: