Geant4-11
Public Member Functions | Private Member Functions | Private Attributes | Static Private Attributes
G4INCL::PiNToMultiPionsChannel Class Reference

#include <G4INCLPiNToMultiPionsChannel.hh>

Inheritance diagram for G4INCL::PiNToMultiPionsChannel:
G4INCL::IChannel

Public Member Functions

void fillFinalState (FinalState *fs)
 
FinalStategetFinalState ()
 
 PiNToMultiPionsChannel (const G4int, Particle *, Particle *)
 
virtual ~PiNToMultiPionsChannel ()
 

Private Member Functions

void isospinRepartition (G4int ipi)
 

Private Attributes

G4int ind2
 
G4int isosp [4]
 
G4int npion
 
Particleparticle1
 
Particleparticle2
 

Static Private Attributes

static const G4double angularSlope = 15.
 

Detailed Description

Definition at line 47 of file G4INCLPiNToMultiPionsChannel.hh.

Constructor & Destructor Documentation

◆ PiNToMultiPionsChannel()

G4INCL::PiNToMultiPionsChannel::PiNToMultiPionsChannel ( const G4int  npi,
Particle p1,
Particle p2 
)

◆ ~PiNToMultiPionsChannel()

G4INCL::PiNToMultiPionsChannel::~PiNToMultiPionsChannel ( )
virtual

Definition at line 60 of file G4INCLPiNToMultiPionsChannel.cc.

60 {
61
62 }

Member Function Documentation

◆ fillFinalState()

void G4INCL::PiNToMultiPionsChannel::fillFinalState ( FinalState fs)
virtual

Implements G4INCL::IChannel.

Definition at line 64 of file G4INCLPiNToMultiPionsChannel.cc.

64 {
65
66// assert(npion > 1 && npion < 5);
67
68 Particle * nucleon;
69 Particle * pion;
70 if(particle1->isNucleon()) {
73 } else {
76 }
77 G4int ipi=ParticleTable::getIsospin(pion->getType());
79
80 ParticleList list;
81 list.push_back(nucleon);
82 list.push_back(pion);
83 fs->addModifiedParticle(nucleon);
84 fs->addModifiedParticle(pion);
85
87
89 nucleon->setType(tn);
91 pion->setType(pionType);
92 const ThreeVector &rcolpion = pion->getPosition();
93 const ThreeVector zero;
94 for(G4int i=1; i<npion; ++i) {
96 Particle *newPion = new Particle(pionType,zero,rcolpion);
97 newPion->setType(pionType);
98 list.push_back(newPion);
99 fs->addCreatedParticle(newPion);
100 }
101
104
105 }
double G4double
Definition: G4Types.hh:83
int G4int
Definition: G4Types.hh:85
G4bool isNucleon() const
G4double totalEnergyInCM(Particle const *const p1, Particle const *const p2)
G4int getIsospin(const ParticleType t)
Get the isospin of a particle.
ParticleType getNucleonType(const G4int isosp)
Get the type of nucleon.
ParticleType getPionType(const G4int isosp)
Get the type of pion.
void generateBiased(const G4double sqrtS, ParticleList &particles, const size_t index, const G4double slope)
Generate a biased event in the CM system.
G4bool pion(G4int ityp)
G4bool nucleon(G4int ityp)
static const G4LorentzVector zero(0., 0., 0., 0.)

References G4INCL::FinalState::addCreatedParticle(), G4INCL::FinalState::addModifiedParticle(), angularSlope, G4INCL::PhaseSpaceGenerator::generateBiased(), G4INCL::ParticleTable::getIsospin(), G4INCL::ParticleTable::getNucleonType(), G4INCL::ParticleTable::getPionType(), ind2, G4INCL::Particle::isNucleon(), isosp, isospinRepartition(), npion, G4InuclParticleNames::nucleon(), particle1, particle2, G4InuclParticleNames::pion(), G4INCL::Particle::setType(), G4INCL::KinematicsUtils::totalEnergyInCM(), and anonymous_namespace{G4CascadeDeexciteBase.cc}::zero.

◆ getFinalState()

FinalState * G4INCL::IChannel::getFinalState ( )
inherited

Definition at line 50 of file G4INCLIChannel.cc.

50 {
51 FinalState *fs = new FinalState;
53 return fs;
54 }
virtual void fillFinalState(FinalState *fs)=0

References G4INCL::IChannel::fillFinalState().

◆ isospinRepartition()

void G4INCL::PiNToMultiPionsChannel::isospinRepartition ( G4int  ipi)
private

Definition at line 107 of file G4INCLPiNToMultiPionsChannel.cc.

107 {
108 G4double rjcd=Random::shoot();
109 const G4int itot=ipi*ind2;
110
111 isosp[1]=ipi;
112 if (npion != 3) {
113 if (npion == 4){
114 const G4double r2 = Random::shoot();
115 if (r2*3. > 2.) {
116 isosp[2]= 0;
117 isosp[3]= 0;
118 }
119 else {
120 isosp[2]= 2;
121 isosp[3]= -2;
122 }
123 }
124
125 if (itot == 2) {
126 // CAS PI+ P ET PI- n
127 rjcd *= 5.;
128 if (rjcd > 3.) {
129 // PI+ PI+ N ET PI- PI- P
130 isosp[0]=2*ind2;
131 isosp[1]=ipi;
132 ind2=-ind2;
133 }
134 else {
135 // PI+ PI0 P ET PI- PI0 N
136 isosp[0]=0;
137 isosp[1]=ipi;
138 }
139 }
140 else if (itot == 0) {
141 // CAS PI0 P ET PI0 N
142 rjcd *= 90.;
143 if (rjcd > 13.) {
144 if (rjcd > 52.) {
145 // PI+ PI0 N ET PI- PI0 P
146 isosp[0]=2*ind2;
147 isosp[1]=0;
148 ind2=-ind2;
149 }
150 else {
151 // PI+ PI- P ET PI+ PI- N
152 isosp[1]=-2;
153 isosp[0]=2;
154 }
155 }
156 else {
157 // PI0 PI0 P ET PI0 PI0 N
158 isosp[0]=0;
159 isosp[1]=0;
160 }
161 }
162 else if (itot == -2) {
163 // CAS PI- P ET PI+ N
164 rjcd *= 45.;
165 if (rjcd > 17.) {
166 if (rjcd > 24.) {
167 // PI+ PI- N ET PI+ PI- P
168 isosp[0]=2*ind2;
169 ind2=-ind2;
170 }
171 else {
172 // PI0 PI0 N ET PI0 PI0 P
173 isosp[0]=0;
174 isosp[1]=0;
175 ind2=-ind2;
176 }
177 }
178 else
179 // PI- PI0 P ET PI+ PI0 N
180 isosp[0]=0;
181 }
182 } // if (npion != 3)
183 else {
184 // PI N -> PI PI PI N
185 // IF (IPI*IND2) 20,21,22
186 if (itot == -2) {
187 // CAS PI- P ET PI+ N
188 rjcd *= 135.;
189 if (rjcd <= 28.) {
190 // PI0 PI0 PI0 N ET PI0 PI0 PI0 P
191 isosp[0]=0;
192 isosp[1]=0;
193 isosp[2]=0;
194 ind2=-ind2;
195 }
196 else {
197 if (rjcd <= 84.) {
198 // PI+ PI- PI0 N ET PI- PI+ PI0 P
199 isosp[0]=2*ind2;
200 isosp[2]=0;
201 ind2=-ind2;
202 }
203 else {
204 if (rjcd <= 118.) {
205 // PI- PI- PI+ P ET PI- PI+ PI+ N
206 isosp[0]=ipi;
207 isosp[2]=-ipi;
208 }
209 else {
210 // PI- PI0 PI0 P ET PI0 PI0 PI+ N
211 isosp[0]=0;
212 isosp[2]=0;
213 }
214 }
215 }
216 }
217 else if (itot == 0) {
218 // CAS PI0 P ET PI0 N
219 rjcd *= 270.;
220 if (rjcd <= 39.) {
221 // PI0 PI0 PI0 P ET PI0 PI0 PI0 N
222 isosp[0]=0;
223 isosp[2]=0;
224 }
225 else {
226 if (rjcd <= 156.) {
227 // PI+ PI- PI0 P ET PI- PI+ PI0 N
228 isosp[0]=2;
229 isosp[2]=-2;
230 }
231 else {
232 if (rjcd <= 194.) {
233 // PI+ PI0 PI0 N ET PI0 PI0 PI- P
234 isosp[0]=0;
235 isosp[2]=2*ind2;
236 ind2=-ind2;
237 }
238 else {
239 // PI- PI+ PI+ N ET PI- PI- PI+ P
240 isosp[0]=2*ind2;
241 isosp[1]=2*ind2;
242 isosp[2]=-2*ind2;
243 ind2=-ind2;
244 }
245 }
246 }
247 }
248 else if (itot == 2) {
249 // CAS PI+ P ET PI- N
250 rjcd *= 5.;
251 if (rjcd <= 2.) {
252 // PI+ P PI0 PI0 ET PI- N PI0 PI0
253 isosp[0]=0;
254 isosp[2]=0;
255 }
256 else {
257 if (rjcd <= 3.) {
258 // PI+ P PI+ PI- ET PI- N PI+ PI-
259 isosp[0]=-2;
260 isosp[2]=2;
261 }
262 else {
263 // PI+ N PI+ PI0 ET PI- P PI0 PI-
264 isosp[0]=2*ind2;
265 isosp[2]=0;
266 ind2=-ind2;
267 }
268 }
269 }
270 }
271
272 std::shuffle(isosp,isosp+npion,Random::getAdapter()); // isospin randomly distributed
273 }
Adapter const & getAdapter()
G4double shoot()
Definition: G4INCLRandom.cc:93

References G4INCL::Random::getAdapter(), ind2, isosp, npion, and G4INCL::Random::shoot().

Referenced by fillFinalState().

Field Documentation

◆ angularSlope

const G4double G4INCL::PiNToMultiPionsChannel::angularSlope = 15.
staticprivate

Definition at line 60 of file G4INCLPiNToMultiPionsChannel.hh.

Referenced by fillFinalState().

◆ ind2

G4int G4INCL::PiNToMultiPionsChannel::ind2
private

Definition at line 56 of file G4INCLPiNToMultiPionsChannel.hh.

Referenced by fillFinalState(), and isospinRepartition().

◆ isosp

G4int G4INCL::PiNToMultiPionsChannel::isosp[4]
private

◆ npion

G4int G4INCL::PiNToMultiPionsChannel::npion
private

Definition at line 55 of file G4INCLPiNToMultiPionsChannel.hh.

Referenced by fillFinalState(), and isospinRepartition().

◆ particle1

Particle* G4INCL::PiNToMultiPionsChannel::particle1
private

Definition at line 58 of file G4INCLPiNToMultiPionsChannel.hh.

Referenced by fillFinalState().

◆ particle2

Particle * G4INCL::PiNToMultiPionsChannel::particle2
private

Definition at line 58 of file G4INCLPiNToMultiPionsChannel.hh.

Referenced by fillFinalState().


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