Geant4 Cross Reference |
1 // 1 2 // ******************************************* 3 // * License and Disclaimer 4 // * 5 // * The Geant4 software is copyright of th 6 // * the Geant4 Collaboration. It is provided 7 // * conditions of the Geant4 Software License 8 // * LICENSE and available at http://cern.ch/ 9 // * include a list of copyright holders. 10 // * 11 // * Neither the authors of this software syst 12 // * institutes,nor the agencies providing fin 13 // * work make any representation or warran 14 // * regarding this software system or assum 15 // * use. Please see the license in the file 16 // * for the full disclaimer and the limitatio 17 // * 18 // * This code implementation is the result 19 // * technical work of the GEANT4 collaboratio 20 // * By using, copying, modifying or distri 21 // * any work based on the software) you ag 22 // * use in resulting scientific publicati 23 // * acceptance of all terms of the Geant4 Sof 24 // ******************************************* 25 // 26 // INCL++ intra-nuclear cascade model 27 // Alain Boudard, CEA-Saclay, France 28 // Joseph Cugnon, University of Liege, Belgium 29 // Jean-Christophe David, CEA-Saclay, France 30 // Pekka Kaitaniemi, CEA-Saclay, France, and H 31 // Sylvie Leray, CEA-Saclay, France 32 // Davide Mancusi, CEA-Saclay, France 33 // 34 #define INCLXX_IN_GEANT4_MODE 1 35 36 #include "globals.hh" 37 38 #include "G4INCLNNbarToNNbarpiChannel.hh" 39 #include "G4INCLKinematicsUtils.hh" 40 #include "G4INCLBinaryCollisionAvatar.hh" 41 #include "G4INCLRandom.hh" 42 #include "G4INCLGlobals.hh" 43 #include "G4INCLLogger.hh" 44 #include <algorithm> 45 #include "G4INCLPhaseSpaceGenerator.hh" 46 47 namespace G4INCL { 48 49 NNbarToNNbarpiChannel::NNbarToNNbarpiChannel 50 : particle1(p1), particle2(p2) 51 {} 52 53 NNbarToNNbarpiChannel::~NNbarToNNbarpiChanne 54 55 void NNbarToNNbarpiChannel::fillFinalState(F 56 57 //brief ppbar 58 // p pbar -> p pbar pi0 (BFMM 185) 59 // p pbar -> p nbar pi- (BFMM 188) 60 // p pbar -> n pbar pi+ (BFMM 199) 61 // p pbar -> n nbar pi0 (no data) 62 // 63 //brief npbar 64 // n pbar -> p pbar pi- (BFMM 491) 65 // n pbar -> p nbar pion (impossible) 66 // n pbar -> n pbar pi0 (BFMM 495) 67 // n pbar -> n nbar pi- (same as BFMM 68 // 69 //brief nnbar 70 // n nbar -> n nbar pi0 (same as BFMM 71 // n nbar -> p nbar pi- (same as BFMM 72 // n nbar -> n pbar pi+ (same as BFMM 73 // n nbar -> p pbar pi0 (no data) 74 // 75 //brief pnbar 76 // p nbar -> p pbar pi+ (same as BFMM 77 // p nbar -> n pbar pion (impossible) 78 // p nbar -> p nbar pi0 (same as BFMM 79 // p nbar -> n nbar pi+ (same as BFMM 80 81 Particle *nucleon; 82 Particle *antinucleon; 83 84 if(particle1->isNucleon()){ 85 nucleon = particle1; 86 antinucleon = particle2; 87 } 88 else{ 89 nucleon = particle2; 90 antinucleon = particle1; 91 } 92 93 const G4double plab = 0.001*KinematicsUtil 94 const G4double sqrtS = KinematicsUtils::to 95 const G4double rdm = Random::shoot(); 96 97 const std::vector<G4double> BFMM185 = 98 //{22.781, -22.602, -0.752, -11.036, 1.548 99 //const G4double Eth_PPbar_PPbar_pi0 = 100 const std::vector<G4double> BFMM188 = 101 //const G4double Eth_PPbar_PNbar_pim = 102 const std::vector<G4double> BFMM199 = 103 //const G4double Eth_PPbar_NPbar_pip = 104 const std::vector<G4double> BFMM491 = 105 //const G4double Eth_NPbar_PPbar_pim = 106 const std::vector<G4double> BFMM495 = 107 //const G4double Eth_NPbar_NPbar_pi0 = 108 109 // pnbar total is same as for npbar 110 // ppbar total is same as for nnbar 111 const G4double totalppbar = KinematicsUtil 112 const G4double totalpnbar = KinematicsUtil 113 //totalnnbar == totalppbar; 114 //totalpnbar == totalnpbar; 115 ParticleType PionType; 116 117 //setting types of new particles 118 if(nucleon->getType()==Proton){ 119 if(antinucleon->getType()==antiProton){ 120 if(rdm*totalppbar < KinematicsUtils::c 121 PionType = PiZero; 122 if(rdm<0.5){ 123 nucleon->setType(Proton); 124 antinucleon->setType(antiProton); 125 } 126 else{ 127 nucleon->setType(antiProton); 128 antinucleon->setType(Proton); 129 } 130 } 131 else if(rdm*totalppbar < KinematicsUti 132 PionType = PiMinus; 133 if(rdm<0.5){ 134 nucleon->setType(Proton); 135 antinucleon->setType(antiNeutron); 136 } 137 else{ 138 nucleon->setType(antiNeutron); 139 antinucleon->setType(Proton); 140 } 141 } 142 else{ // npbarpi+ case 143 PionType = PiPlus; 144 if(rdm<0.5){ 145 nucleon->setType(Neutron); 146 antinucleon->setType(antiProton); 147 } 148 else{ 149 nucleon->setType(antiProton); 150 antinucleon->setType(Neutron); 151 } 152 } 153 } 154 else{ //antiNeutron (pnbar case) 155 if(rdm*totalpnbar < KinematicsUtils::c 156 PionType = PiPlus; 157 if(rdm<0.5){ 158 nucleon->setType(Proton); 159 antinucleon->setType(antiProton); 160 } 161 else{ 162 nucleon->setType(antiProton); 163 antinucleon->setType(Proton); 164 } 165 } 166 else if(rdm*totalppbar < KinematicsUti 167 PionType = PiZero; 168 if(rdm<0.5){ 169 nucleon->setType(Proton); 170 antinucleon->setType(antiNeutron); 171 } 172 else{ 173 nucleon->setType(antiNeutron); 174 antinucleon->setType(Proton); 175 } 176 } 177 else{ // nnbarpi+ case 178 PionType = PiPlus; 179 if(rdm<0.5){ 180 nucleon->setType(Neutron); 181 antinucleon->setType(antiNeutron); 182 } 183 else{ 184 nucleon->setType(antiNeutron); 185 antinucleon->setType(Neutron); 186 } 187 } 188 } 189 } 190 else{ // neutron 191 if(antinucleon->getType()==antiProton){ 192 if(rdm*totalpnbar < KinematicsUtils::c 193 PionType = PiMinus; 194 if(rdm<0.5){ 195 nucleon->setType(Proton); 196 antinucleon->setType(antiProton); 197 } 198 else{ 199 nucleon->setType(antiProton); 200 antinucleon->setType(Proton); 201 } 202 } 203 else if(rdm*totalppbar < KinematicsUti 204 PionType = PiZero; 205 if(rdm<0.5){ 206 nucleon->setType(Neutron); 207 antinucleon->setType(antiProton); 208 } 209 else{ 210 nucleon->setType(antiProton); 211 antinucleon->setType(Neutron); 212 } 213 } 214 else{ // nnbarpi- case 215 PionType = PiMinus; 216 if(rdm<0.5){ 217 nucleon->setType(Neutron); 218 antinucleon->setType(antiNeutron); 219 } 220 else{ 221 nucleon->setType(antiNeutron); 222 antinucleon->setType(Neutron); 223 } 224 } 225 } 226 else{ //antiNeutron (nnbar case) 227 if(rdm*totalpnbar < KinematicsUtils::c 228 PionType = PiZero; 229 if(rdm<0.5){ 230 nucleon->setType(Neutron); 231 antinucleon->setType(antiNeutron); 232 } 233 else{ 234 nucleon->setType(antiNeutron); 235 antinucleon->setType(Neutron); 236 } 237 } 238 else if(rdm*totalpnbar < KinematicsUti 239 PionType = PiMinus; 240 if(rdm<0.5){ 241 nucleon->setType(Proton); 242 antinucleon->setType(antiNeutron); 243 } 244 else{ 245 nucleon->setType(antiNeutron); 246 antinucleon->setType(Proton); 247 } 248 } 249 else{ // npbarpi+ case 250 PionType = PiPlus; 251 if(rdm<0.5){ 252 nucleon->setType(Neutron); 253 antinucleon->setType(antiProton); 254 } 255 else{ 256 nucleon->setType(antiProton); 257 antinucleon->setType(Neutron); 258 } 259 } 260 } 261 } 262 263 ParticleList list; 264 list.push_back(nucleon); 265 list.push_back(antinucleon); 266 const ThreeVector &rcol = nucleon->getPosi 267 const ThreeVector zero; 268 Particle *pion = new Particle(PionType,zer 269 list.push_back(pion); 270 271 PhaseSpaceGenerator::generate(sqrtS, list) 272 273 fs->addModifiedParticle(nucleon); 274 fs->addModifiedParticle(antinucleon); 275 fs->addCreatedParticle(pion); 276 277 } 278 } 279