// // ******************************************************************** // * License and Disclaimer * // * * // * The Geant4 software is copyright of the Copyright Holders of * // * the Geant4 Collaboration. It is provided under the terms and * // * conditions of the Geant4 Software License, included in the file * // * LICENSE and available at http://cern.ch/geant4/license . These * // * include a list of copyright holders. * // * * // * Neither the authors of this software system, nor their employing * // * institutes,nor the agencies providing financial support for this * // * work make any representation or warranty, express or implied, * // * regarding this software system or assume any liability for its * // * use. Please see the license in the file LICENSE and URL above * // * for the full disclaimer and the limitation of liability. * // * * // * This code implementation is the result of the scientific and * // * technical work of the GEANT4 collaboration. * // * By using, copying, modifying or distributing the software (or * // * any work based on the software) you agree to acknowledge its * // * use in resulting scientific publications, and indicate your * // * acceptance of all terms of the Geant4 Software license. * // ******************************************************************** // // $Id: G4QCollision.cc,v 1.32 2009/04/17 15:22:31 mkossov Exp $ // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ // // ---------------- G4QCollision class ----------------- // by Mikhail Kossov, December 2003. // G4QCollision class of the CHIPS Simulation Branch in GEANT4 // --------------------------------------------------------------- // **************************************************************************************** // ********** This CLASS is temporary moved from the photolepton_hadron directory ********* // **************************************************************************************** // Short description: This is a universal class for the incoherent (inelastic) // nuclear interactions in the CHIPS model. // --------------------------------------------------------------------------- //#define debug //#define pdebug //#define ldebug //#define ppdebug //#define qedebug #include "G4QCollision.hh" // Initialization of static vectors std::vector G4QCollision::ElementZ; // Z of the element(i) in theLastCalc std::vector G4QCollision::ElProbInMat; // SumProbabilityElements in Material std::vector*> G4QCollision::ElIsoN; // N of isotope(j) of Element(i) std::vector*>G4QCollision::IsoProbInEl;//SumProbabIsotopes inElementI G4QCollision::G4QCollision(const G4String& processName): G4VDiscreteProcess(processName, fHadronic) { #ifdef debug G4cout<<"G4QCollision::Constructor is called"<0) G4cout << GetProcessName() << " process is created "<< G4endl; SetProcessSubType(fHadronInelastic); //G4QCHIPSWorld::Get()->GetParticles(nPartCWorld); // Create CHIPSWorld (234 part.max) G4QNucleus::SetParameters(freeNuc,freeDib,clustProb,mediRatio); // Clusterization param's G4Quasmon::SetParameters(Temperature,SSin2Gluons,EtaEtaprime); // Hadronic parameters G4QEnvironment::SetParameters(SolidAngle); // SolAngle of pbar-A secondary mesons capture //@@ Initialize here the G4QuasmonString parameters } G4bool G4QCollision::manualFlag=false; // If false then standard parameters are used G4double G4QCollision::Temperature=180.; // Critical Temperature (sensitive at High En) G4double G4QCollision::SSin2Gluons=0.3; // Supression of s-quarks (in respect to u&d) G4double G4QCollision::EtaEtaprime=0.3; // Supression of eta mesons (gg->qq/3g->qq) G4double G4QCollision::freeNuc=0.5; // Percentage of free nucleons on the surface G4double G4QCollision::freeDib=0.05; // Percentage of free diBaryons on the surface G4double G4QCollision::clustProb=5.; // Nuclear clusterization parameter G4double G4QCollision::mediRatio=10.; // medium/vacuum hadronization ratio G4int G4QCollision::nPartCWorld=152; // The#of particles initialized in CHIPS World G4double G4QCollision::SolidAngle=0.5; // Part of Solid Angle to capture (@@A-dep.) G4bool G4QCollision::EnergyFlux=false; // Flag for Energy Flux use (not MultyQuasmon) G4double G4QCollision::PiPrThresh=141.4; // Pion Production Threshold for gammas G4double G4QCollision::M2ShiftVir=20000.;// Shift for M2=-Q2=m_pi^2 of the virtualGamma G4double G4QCollision::DiNuclMass=1880.; // DoubleNucleon Mass for VirtualNormalization G4double G4QCollision::photNucBias=1.; // BiasingParameter for photo(e,mu,tau)Nuclear G4double G4QCollision::weakNucBias=1.; // BiasingParameter for ChargedCurrents(nu,mu) void G4QCollision::SetManual() {manualFlag=true;} void G4QCollision::SetStandard() {manualFlag=false;} // Fill the private parameters void G4QCollision::SetParameters(G4double temper, G4double ssin2g, G4double etaetap, G4double fN, G4double fD, G4double cP, G4double mR, G4int nParCW, G4double solAn, G4bool efFlag, G4double piThresh, G4double mpisq, G4double dinum) {// ============================================================================= Temperature=temper; SSin2Gluons=ssin2g; EtaEtaprime=etaetap; freeNuc=fN; freeDib=fD; clustProb=cP; mediRatio=mR; nPartCWorld = nParCW; EnergyFlux=efFlag; SolidAngle=solAn; PiPrThresh=piThresh; M2ShiftVir=mpisq; DiNuclMass=dinum; G4QCHIPSWorld::Get()->GetParticles(nPartCWorld); // Create CHIPS World with 234 particles G4QNucleus::SetParameters(freeNuc,freeDib,clustProb,mediRatio); // Clusterization param's G4Quasmon::SetParameters(Temperature,SSin2Gluons,EtaEtaprime); // Hadronic parameters G4QEnvironment::SetParameters(SolidAngle); // SolAngle of pbar-A secondary mesons capture } void G4QCollision::SetPhotNucBias(G4double phnB) {photNucBias=phnB;} void G4QCollision::SetWeakNucBias(G4double ccnB) {weakNucBias=ccnB;} // Destructor G4QCollision::~G4QCollision() {} G4LorentzVector G4QCollision::GetEnegryMomentumConservation() { return EnMomConservation; } G4int G4QCollision::GetNumberOfNeutronsInTarget() { return nOfNeutrons; } // output of the function must be in units of length! L=1/sig_V,sig_V=SUM(n(j,i)*sig(j,i)), // where n(i,j) is a number of nuclei of the isotop j of the element i in V=1(lengtUnit^3) // ********** All CHIPS cross sections are calculated in the surface units ************ G4double G4QCollision::GetMeanFreePath(const G4Track& aTrack,G4double,G4ForceCondition* Fc) { #ifdef debug G4cout<<"G4QCollision::GetMeanFreePath: Called Fc="<<*Fc<GetDefinition(); if( !IsApplicable(*incidentParticleDefinition)) G4cout<<"-W-G4QCollision::GetMeanFreePath called for not implemented particle"<GetTotalMomentum(); // 3-momentum of the Particle #ifdef debug G4cout<<"G4QCollis::GetMeanFreePath: BeforeGetMaterial"<GetVecNbOfAtomsPerVolume(); const G4ElementVector* theElementVector = material->GetElementVector(); G4int nE=material->GetNumberOfElements(); #ifdef debug G4cout<<"G4QCollision::GetMeanFreePath:"<* SPI=IsoProbInEl[ip]; // Pointer to the SPI vector SPI->clear(); delete SPI; std::vector* IsN=ElIsoN[ip]; // Pointer to the N vector IsN->clear(); delete IsN; } ElProbInMat.clear(); // Clean up the SumProb's of Elements (SPE) ElementZ.clear(); // Clear the body vector for Z of Elements IsoProbInEl.clear(); // Clear the body vector for SPI ElIsoN.clear(); // Clear the body vector for N of Isotopes for(G4int i=0; i(pElement->GetZ()); // Z of the Element ElementZ.push_back(Z); // Remember Z of the Element G4int isoSize=0; // The default for the isoVectorLength is 0 G4int indEl=0; // Index of non-trivial element or 0(default) G4IsotopeVector* isoVector=pElement->GetIsotopeVector(); // Get the predefined IsoVect if(isoVector) isoSize=isoVector->size();// Get size of the existing isotopeVector #ifdef debug G4cout<<"G4QCollision::GetMeanFreePath: isovectorLength="<GetIndex()+1; // Index of the non-trivial element if(!Isotopes->IsDefined(Z,indEl)) // This index is not defined for this Z: define { std::vector*>* newAbund = new std::vector*>; G4double* abuVector=pElement->GetRelativeAbundanceVector(); for(G4int j=0; jGetIsotope(j)->GetN()-Z; // N means A=N+Z ! if(pElement->GetIsotope(j)->GetZ()!=Z)G4cerr<<"G4QCollision::GetMeanFreePath" <<": Z="<GetIsotope(j)->GetZ()<<"#"<* pr= new std::pair(N,abund); #ifdef debug G4cout<<"G4QCollision::GetMeanFreePath: p#="<push_back(pr); } #ifdef debug G4cout<<"G4QCollision::GetMeanFreePath: pairVectLength="<size()<InitElement(Z,indEl,newAbund); // definition of the newInd for(G4int k=0; k*>* cs= Isotopes->GetCSVector(Z,indEl);//CSPointer std::vector* SPI = new std::vector; // Pointer to the SPI vector IsoProbInEl.push_back(SPI); std::vector* IsN = new std::vector; // Pointer to the N vector ElIsoN.push_back(IsN); G4int nIs=cs->size(); // A#Of Isotopes in the Element G4double susi=0.; // sum of CS over isotopes if(nIs) for(G4int j=0; j* curIs=(*cs)[j]; // A pointer, which is used twice G4int N=curIs->first; // #of Neuterons in the isotope j of El i IsN->push_back(N); // Remember Min N for the Element G4double CSI=CSmanager->GetCrossSection(true,Momentum,Z,N,pPDG);//CS(j,i) for isotope if(CSmanager2)CSI+=CSmanager2->GetCrossSection(true,Momentum,Z,N,pPDG);//CS(j,i)nu,nu #ifdef debug G4cout<<"GQC::GMF:X="<second = CSI; susi+=CSI; // Make a sum per isotopes SPI->push_back(susi); // Remember summed cross-section } // End of temporary initialization of the cross sections in the G4QIsotope singeltone sigma+=Isotopes->GetMeanCrossSection(Z,indEl)*NOfNucPerVolume[i];//SUM(MeanCS*NOfNperV) ElProbInMat.push_back(sigma); } // End of LOOP over Elements #ifdef debug G4cout<<"G4QCol::GetMeanFrPa: S="< 0.) return 1./sigma; // Mean path [distance] return DBL_MAX; } G4bool G4QCollision::IsApplicable(const G4ParticleDefinition& particle) { if (particle == *( G4MuonPlus::MuonPlus() )) return true; else if (particle == *( G4MuonMinus::MuonMinus() )) return true; else if (particle == *( G4TauPlus::TauPlus() )) return true; else if (particle == *( G4TauMinus::TauMinus() )) return true; else if (particle == *( G4Electron::Electron() )) return true; else if (particle == *( G4Positron::Positron() )) return true; else if (particle == *( G4Gamma::Gamma() )) return true; else if (particle == *( G4Proton::Proton() )) return true; else if (particle == *( G4AntiNeutrinoE::AntiNeutrinoE() )) return true; else if (particle == *( G4NeutrinoE::NeutrinoE() )) return true; else if (particle == *(G4AntiNeutrinoMu::AntiNeutrinoMu())) return true; else if (particle == *( G4NeutrinoMu::NeutrinoMu() )) return true; //else if (particle == *( G4Neutron::Neutron() )) return true; //else if (particle == *( G4PionMinus::PionMinus() )) return true; //else if (particle == *( G4PionPlus::PionPlus() )) return true; //else if (particle == *( G4KaonPlus::KaonPlus() )) return true; //else if (particle == *( G4KaonMinus::KaonMinus() )) return true; //else if (particle == *( G4KaonZeroLong::KaonZeroLong() )) return true; //else if (particle == *( G4KaonZeroShort::KaonZeroShort() )) return true; //else if (particle == *( G4Lambda::Lambda() )) return true; //else if (particle == *( G4SigmaPlus::SigmaPlus() )) return true; //else if (particle == *( G4SigmaMinus::SigmaMinus() )) return true; //else if (particle == *( G4SigmaZero::SigmaZero() )) return true; //else if (particle == *( G4XiMinus::XiMinus() )) return true; //else if (particle == *( G4XiZero::XiZero() )) return true; //else if (particle == *( G4OmegaMinus::OmegaMinus() )) return true; //else if (particle == *( G4AntiNeutron::AntiNeutron() )) return true; //else if (particle == *( G4AntiProton::AntiProton() )) return true; //else if (particle == *(G4AntiNeutrinoTau::AntiNeutrinoTau())) return true; //else if (particle == *( G4NeutrinoTau::NeutrinoTau() )) return true; #ifdef debug G4cout<<"***G4QCollision::IsApplicable: PDG="<GetPDGMass(); // electron mass static const G4double me2=me*me; // squared electron mass static const G4double mu=G4MuonMinus::MuonMinus()->GetPDGMass(); // muon mass static const G4double mu2=mu*mu; // squared muon mass static const G4double mt=G4TauMinus::TauMinus()->GetPDGMass(); // tau mass static const G4double mt2=mt*mt; // squared tau mass //static const G4double dpi=M_PI+M_PI; // 2*pi (for Phi distr.) ***changed to twopi*** static const G4double mNeut= G4QPDGCode(2112).GetMass(); static const G4double mNeut2= mNeut*mNeut; static const G4double mProt= G4QPDGCode(2212).GetMass(); static const G4double mProt2= mProt*mProt; static const G4double dM=mProt+mNeut; // doubled nucleon mass static const G4double hdM=dM/2.; // M of the "nucleon" static const G4double hdM2=hdM*hdM; // M2 of the "nucleon" static const G4double mPi0 = G4QPDGCode(111).GetMass(); static const G4double mPi0s= mPi0*mPi0; static const G4double mDeut= G4QPDGCode(2112).GetNuclMass(1,1,0);// Mass of deuteron //static const G4double mDeut2=mDeut*mDeut; // SquaredMassOfDeuteron static const G4double mTrit= G4QPDGCode(2112).GetNuclMass(1,2,0);// Mass of tritium static const G4double mHel3= G4QPDGCode(2112).GetNuclMass(2,1,0);// Mass of Helium3 static const G4double mAlph= G4QPDGCode(2112).GetNuclMass(2,2,0);// Mass of alpha static const G4double mPi = G4QPDGCode(211).GetMass(); static const G4double tmPi = mPi+mPi; // Doubled mass of the charged pion static const G4double stmPi= tmPi*tmPi; // Squared Doubled mass of the charged pion static const G4double mPPi = mPi+mProt; // Delta threshold static const G4double mPPi2= mPPi*mPPi; // Delta low threshold for W2 //static const G4double mDel2= 1400*1400; // Delta up threshold for W2 (in MeV^2) // Static definitions for electrons (nu,e) ----------------------------------------- static const G4double meN = mNeut+me; static const G4double meN2= meN*meN; static const G4double fmeN= 4*mNeut2*me2; static const G4double mesN= mNeut2+me2; static const G4double meP = mProt+me; static const G4double meP2= meP*meP; static const G4double fmeP= 4*mProt2*me2; static const G4double mesP= mProt2+me2; static const G4double medM= me2/dM; // for x limit static const G4double meD = mPPi+me; // Multiperipheral threshold static const G4double meD2= meD*meD; // Static definitions for muons (nu,mu) ----------------------------------------- static const G4double muN = mNeut+mu; static const G4double muN2= muN*muN; static const G4double fmuN= 4*mNeut2*mu2; static const G4double musN= mNeut2+mu2; static const G4double muP = mProt+mu; static const G4double muP2= muP*muP; // + static const G4double fmuP= 4*mProt2*mu2; // + static const G4double musP= mProt2+mu2; static const G4double mudM= mu2/dM; // for x limit static const G4double muD = mPPi+mu; // Multiperipheral threshold static const G4double muD2= muD*muD; // Static definitions for muons (nu,nu) ----------------------------------------- //static const G4double nuN = mNeut; //static const G4double nuN2= mNeut2; //static const G4double fnuN= 0.; //static const G4double nusN= mNeut2; //static const G4double nuP = mProt; //static const G4double nuP2= mProt2; //static const G4double fnuP= 0.; //static const G4double nusP= mProt2; //static const G4double nudM= 0.; // for x limit //static const G4double nuD = mPPi; // Multiperipheral threshold //static const G4double nuD2= mPPi2; //------------------------------------------------------------------------------------- static G4bool CWinit = true; // CHIPS Warld needs to be initted if(CWinit) { CWinit=false; G4QCHIPSWorld::Get()->GetParticles(nPartCWorld); // Create CHIPS World (234 part.max) } //------------------------------------------------------------------------------------- const G4DynamicParticle* projHadron = track.GetDynamicParticle(); const G4ParticleDefinition* particle=projHadron->GetDefinition(); #ifdef debug G4cout<<"G4QCollision::PostStepDoIt: Before the GetMeanFreePath is called"<Get4Momentum(); // 4-momentum of the projectile (IU?) G4LorentzVector scat4M=proj4M; // Must be filled if true G4double momentum = projHadron->GetTotalMomentum(); // 3-momentum of the Particle G4double Momentum=proj4M.rho(); if(std::fabs(Momentum-momentum)>.001) G4cerr<<"*G4QCollision::PostStepDoIt: P="<G4QCollis::PostStDoIt:called,P="<GetElementVector(); G4int nE=material->GetNumberOfElements(); #ifdef debug G4cout<<"G4QCollision::PostStepDoIt: "<GetPDGEncoding(); G4cout<<"G4QCollision::PostStepDoIt: projPDG="<size(); // #of isotopes in the element i #ifdef debug G4cout<<"G4QCollis::PosStDoIt:n="<1) { G4double rndI=(*SPI)[nofIsot-1]*G4UniformRand(); // Randomize the isotop of the Element for(j=0; jN="<GetExchangeEnergy(); // Energy of EqivExchangePart #ifdef debug G4cout<<"G4QCol::PStDoIt: kE="<leptE="<GetExchangeQ2(photonEnergy);// Q2(t) of EqivExchangePart G4double W=photonEnergy-photonQ2/dM;// HadronicEnergyFlow (W-energy) for virtual photon if(tM<999.) W-=mPi0+mPi0s/dM; // Pion production threshold for a nucleon target if(W<0.) { //Do Nothing Action insead of the reaction #ifdef debug G4cout<<"--G4QCollision::PostStepDoIt:(lN) negative equivalent energy W="<GetCrossSection(true,photonEnergy,Z,N,22);//Integrated XS G4double sigK =thePhotonData->GetCrossSection(true, W, Z, N, 22); // Real XS G4double rndFraction = CSmanager->GetVirtualFactor(photonEnergy, photonQ2); if(sigNu*G4UniformRand()>sigK*rndFraction) { //Do NothingToDo Action insead of the reaction #ifdef debug G4cout<<"-DoNoth-G4QCollision::PostStepDoIt: probab. correction - DoNothing"<G4QC::PoStDoIt: new sF="<? OT="<GetQEL_ExchangeQ2(); else Q2=CSmanager->GetQEL_ExchangeQ2(); #ifdef debug G4cout<<"G4QCollision::PostStDoIt:QuasiEl(nu="<GetNQE_ExchangeQ2(); else Q2=CSmanager2->GetNQE_ExchangeQ2(); #ifdef debug G4cout<<"G4QColl::PStDoIt: MultiPeriferal s="<GetExchangePDGCode();// PDG Code of the effective gamma else projPDG=CSmanager->GetExchangePDGCode(); // PDG Code of the effective pion //@@ Temporary made only for direct interaction and for N=3 (good for small Q2) //@@ inFuture use N=GetNPartons and directFraction=GetDirectPart, @@ W2... G4double r=G4UniformRand(); G4double r1=0.5; // (1-x) if(r<0.5) r1=std::sqrt(r+r)*(.5+.1579*(r-.5)); else if(r>0.5) r1=1.-std::sqrt(2.-r-r)*(.5+.1579*(.5-r)); G4double xn=1.-mldM/Momentum; // Normalization of (1-x) [x>mldM/Mom] G4double x1=xn*r1; // (1-x) G4double x=1.-x1; // x=2k/M //G4double W2=(hdM2+Q2/x)*x1; // W2 candidate G4double mx=hdM*x; // Part of the target to interact with G4double we=Q2/(mx+mx); // transfered energy if(we>=kinEnergy-ml-.001) we=kinEnergy-ml-.0001; // safety to avoid nan=sqrt(neg) G4double pot=kinEnergy-we; // energy of the secondary lepton G4double mlQ2=ml2+Q2; G4double cost=(pot-mlQ2/dKinE)/std::sqrt(pot*pot-ml2); // LS cos(theta) if(std::fabs(cost)>1) { #ifdef debug G4cout<<"*G4QCollision::PostStDoIt: cost="<G4QCol::PSD:QE[p("<QENuc+ResNuc"); } #ifdef qedebug G4cout<<"G4QCol::PStDoIt:QE-N,RA="<(N-1)) // He3 { nPDG=90002001; qM=mHel3; nZ=2; restPDG-=2001; } else // tritium { nPDG=90001002; qM=mTrit; nZ=1; restPDG-=1002; } // Recalculate dmom G4ThreeVector sumv=G4ThreeVector(0.,0.,dmom) + fmm*std::pow(-std::log(G4UniformRand()),third)*G4RandomDirection()+ fmm*std::pow(-std::log(G4UniformRand()),third)*G4RandomDirection(); dmom=sumv.mag(); } else { nPDG=90002002; // Alpha qM=mAlph; nA=4; nZ=2; restPDG-=2002; G4ThreeVector sumv=G4ThreeVector(0.,0.,dmom) + fmm*std::pow(-std::log(G4UniformRand()),third)*G4RandomDirection()+ fmm*std::pow(-std::log(G4UniformRand()),third)*G4RandomDirection()+ fmm*std::pow(-std::log(G4UniformRand()),third)*G4RandomDirection(); dmom=sumv.mag(); } rA=A-nA; rZ=Z-nZ; // This is a simple case of cluster at rest //G4double rM=G4QPDGCode(restPDG).GetMass();// Mass of the residual nucleus //r4M=G4LorentzVector(0.,0.,0.,rM); // 4mom of the residual nucleus //n4M=G4LorentzVector(0.,0.,0.,tM-rM); // 4mom of the quasi-free cluster // --- End of the "simple case of cluster at rest" // Make a fake quasi-Fermi distribution for clusters (clusters are not at rest) G4LorentzVector t4M(0.,0.,0.,tM); // 4m of the target nucleus to be decayed G4double rM=G4QPDGCode(restPDG).GetMass();// Mass of the residual nucleus r4M=G4LorentzVector(0.,0.,0.,rM); // 4mom of the residual nucleus G4double rM2=rM*rM; G4double nM=std::sqrt(rM2+tM*tM-(tM+tM)*std::sqrt(rM2+dmom*dmom));// M of q-cluster n4M=G4LorentzVector(0.,0.,0.,nM); // 4mom of the quasi-nucleon #ifdef qedebug G4cout<<"G4QCollis::PStDoIt:QEC,p="<QEClu+ResNuc"); } // --- End of the moving cluster implementation --- #ifdef qedebug G4cout<<"G4QCol::PStDoIt:QEC,RN="<minM*minM) { #ifdef qedebug G4cout<<"G4QCol::PStDoIt:***Enter***,cmM2="< minM2="<rZ || projPDG==2112&&rZ>1))// @@ Use proj chex if(2>3) { #ifdef qedebug G4cout<<"G4QCol::PStDoIt:-Enter,P="<ChExElCoef(efP*MeV, nZ, nA-nZ, projPDG); // ChEx/Elast(pPDG!) #ifdef qedebug G4cout<<"G4QCol::PStDoIt:chl="<0.&&cmM2>minM*minM&&G4UniformRand() sctout=qfMan->Scatter(nPDG, n4M, projPDG, proj4M); #ifdef qedebug G4cout<<"G4QCollis::PStDoIt:QElS,proj="<.001) G4cout<<"G4QCol::PSD:mDeut="<SetWeight(weight); // weighted scatQFN->SetTouchableHandle(trTouchable); // nuclear aParticleChange.AddSecondary(scatQFN); // cluster // ---------------------------------------------------- // Fill residual nucleus if (restPDG==90000001) theDefinition = G4Neutron::Neutron(); else if(restPDG==90001000) theDefinition = G4Proton::Proton(); else theDefinition = G4ParticleTable::GetParticleTable()->FindIon(rZ,rA,0,rZ);//ion G4DynamicParticle* theReN = new G4DynamicParticle(theDefinition,r4M); G4Track* scatReN = new G4Track(theReN, localtime, position ); // scattered scatReN->SetWeight(weight); // weighted scatReN->SetTouchableHandle(trTouchable); // residual aParticleChange.AddSecondary(scatReN); // nucleus return G4VDiscreteProcess::PostStepDoIt(track, step); } } } // end of decoupled processes for the proton projectile } // end lepto-nuclear, neutrino-nuclear, proton quasi-elastic EnMomConservation=proj4M+G4LorentzVector(0.,0.,0.,tM); // Total 4-mom of the reaction if(absMom) EnMomConservation+=lead4M; // Add E/M of leading System #ifdef debug G4cout<<"G4QCollision::PostStDoIt:before St="< DELETED --+ | // delete pH; // --------<-------+--+ #ifdef debug // G4double mp=G4QPDGCode(projPDG).GetMass(); // Mass of the projectile particle | // G4cout<<"G4QCollision::PostStepDoIt: pPDG="<>G4QCollision::PostStepDoIt: elF="<push_back(scatHadron); } G4int qNH=leadhs->size(); if(absMom) { if(qNH) for(G4int iq=0; iqpush_back(loh); } delete leadhs; } // ------------- From here the secondaries are filled ------------------------- G4int tNH = output->size(); // A#of hadrons in the output aParticleChange.SetNumberOfSecondaries(tNH); // Now add nuclear fragments #ifdef debug G4cout<<"G4QCollision::PostStepDoIt: "< work for Hisaya @@ // The decau process for hypernuclei must be developed in GEANT4 (change CHIPS body) G4QHadron* hadr=(*output)[i]; // Pointer to the output hadron G4int PDGCode = hadr->GetPDGCode(); G4int nFrag = hadr->GetNFragments(); #ifdef pdebug G4cout<<"G4QCollision::PostStepDoIt: H#"<