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

#include <G4INCLNSToNSChannel.hh>

Inheritance diagram for G4INCL::NSToNSChannel:
G4INCL::IChannel

Public Member Functions

void fillFinalState (FinalState *fs)
 
FinalStategetFinalState ()
 
 NSToNSChannel (Particle *, Particle *)
 
virtual ~NSToNSChannel ()
 

Private Member Functions

 INCL_DECLARE_ALLOCATION_POOL (NSToNSChannel)
 

Private Attributes

Particleparticle1
 
Particleparticle2
 

Detailed Description

Definition at line 47 of file G4INCLNSToNSChannel.hh.

Constructor & Destructor Documentation

◆ NSToNSChannel()

G4INCL::NSToNSChannel::NSToNSChannel ( Particle p1,
Particle p2 
)

Definition at line 49 of file G4INCLNSToNSChannel.cc.

50 : particle1(p1), particle2(p2)
51 {}

◆ ~NSToNSChannel()

G4INCL::NSToNSChannel::~NSToNSChannel ( )
virtual

Definition at line 53 of file G4INCLNSToNSChannel.cc.

53{}

Member Function Documentation

◆ fillFinalState()

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

Implements G4INCL::IChannel.

Definition at line 55 of file G4INCLNSToNSChannel.cc.

55 {
56
57 Particle *nucleon;
58 Particle *sigma;
59
60 if(particle1->isNucleon()){
62 sigma = particle2;
63 }
64 else{
66 sigma = particle1;
67 }
68
70 const G4int iso = ParticleTable::getIsospin(nucleon->getType()) + ParticleTable::getIsospin(sigma->getType());
71// assert(iso == -1 || iso == 1);
72
73 if(sigma->getType() == SigmaZero){
75 sigma->setType(ParticleTable::getSigmaType(2*iso));
76 }
77 else{
79 sigma->setType(SigmaZero);
80 }
81
82 G4double mn=nucleon->getMass();
83 G4double my=sigma->getMass();
84
85 G4double ey=(sqrtS*sqrtS+my*my-mn*mn)/(2*sqrtS);
86 G4double en=std::sqrt(ey*ey-my*my+mn*mn);
87 nucleon->setEnergy(en);
88 sigma->setEnergy(ey);
89 G4double py=std::sqrt(ey*ey-my*my);
90
91 ThreeVector mom_hyperon = Random::normVector(py);
92
93 sigma->setMomentum(mom_hyperon);
94 nucleon->setMomentum(-mom_hyperon);
95
96 sigma->adjustEnergyFromMomentum();
97 nucleon->adjustEnergyFromMomentum();
98
99 fs->addModifiedParticle(nucleon);
100 fs->addModifiedParticle(sigma);
101
102 }
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)
ParticleType getSigmaType(const G4int isosp)
Get the type of sigma.
G4int getIsospin(const ParticleType t)
Get the isospin of a particle.
ParticleType getNucleonType(const G4int isosp)
Get the type of nucleon.
ThreeVector normVector(G4double norm=1.)
G4bool nucleon(G4int ityp)

References G4INCL::FinalState::addModifiedParticle(), G4INCL::Particle::adjustEnergyFromMomentum(), G4INCL::ParticleTable::getIsospin(), G4INCL::Particle::getMass(), G4INCL::ParticleTable::getNucleonType(), G4INCL::ParticleTable::getSigmaType(), G4INCL::Particle::getType(), G4INCL::Particle::isNucleon(), G4INCL::Random::normVector(), G4InuclParticleNames::nucleon(), particle1, particle2, G4INCL::Particle::setEnergy(), G4INCL::Particle::setMomentum(), G4INCL::Particle::setType(), G4INCL::SigmaZero, and G4INCL::KinematicsUtils::totalEnergyInCM().

◆ 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().

◆ INCL_DECLARE_ALLOCATION_POOL()

G4INCL::NSToNSChannel::INCL_DECLARE_ALLOCATION_POOL ( NSToNSChannel  )
private

Field Documentation

◆ particle1

Particle* G4INCL::NSToNSChannel::particle1
private

Definition at line 55 of file G4INCLNSToNSChannel.hh.

Referenced by fillFinalState().

◆ particle2

Particle * G4INCL::NSToNSChannel::particle2
private

Definition at line 55 of file G4INCLNSToNSChannel.hh.

Referenced by fillFinalState().


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