158 for (
int iPDL = 0; iPDL < nPDL; iPDL++ ) {
163 const long unsigned int particleCode = std::abs( PDGCode );
168 ATOOLS::KFCode_ParticleInfo_Map::const_iterator kf_it(
169 ATOOLS::s_kftable.find( particleCode ) );
170 if ( kf_it != ATOOLS::s_kftable.end() ) {
181 const int charge = PDGCode < 0 ?
EvtPDL::chg3( particleIdConj )
187 const std::string idName = PDGCode < 0 ? particleIdConj.
getName()
193 ATOOLS::s_kftable[particleCode] =
new ATOOLS::Particle_Info(
194 particleCode, mass, width, charge, spin, 0, 1, idName, idName );
200 if ( !theParticle ) {
207 const int nDaughters( theParticle->
getNDaug() );
208 if ( nDaughters == 0 || nDaughters >= 10 ) {
213 std::unique_ptr<ATOOLS::Blob> blob = std::make_unique<ATOOLS::Blob>();
216 blob->SetStatus( ATOOLS::blob_status::needs_extraQED );
220 mother_flav.SetStable(
false );
221 const double motherM0 = theParticle->
mass();
222 const ATOOLS::Vec4D mother_mom( motherM0, 0., 0., 0. );
225 ATOOLS::Particle* mother_part =
new ATOOLS::Particle( -1, mother_flav,
227 mother_part->SetFinalMass( motherM0 );
228 mother_part->SetStatus( ATOOLS::part_status::decayed );
230 mother_part->SetInfo(
'I' );
232 blob->AddToInParticles( mother_part );
235 for (
int iDaug = 0; iDaug < nDaughters; iDaug++ ) {
238 daughter_flav.SetStable(
true );
240 const double daugE = theDaughter->
getP4().
get( 0 );
241 const double daugPx = theDaughter->
getP4().
get( 1 );
242 const double daugPy = theDaughter->
getP4().
get( 2 );
243 const double daugPz = theDaughter->
getP4().
get( 3 );
244 const double daugM0 = theDaughter->
mass();
246 const ATOOLS::Vec4D daughter_mom( daugE, daugPx, daugPy, daugPz );
248 ATOOLS::Particle* daughter_part =
249 new ATOOLS::Particle( iDaug, daughter_flav, daughter_mom );
250 daughter_part->SetFinalMass( daugM0 );
252 daughter_part->SetStatus( ATOOLS::part_status::active );
253 daughter_part->SetInfo(
'F' );
255 blob->AddToOutParticles( daughter_part );
262 const SHERPA::Initialization_Handler* inithandler =
264 SHERPA::Soft_Photon_Handler* softphotonhandler =
265 inithandler->GetSoftPhotonHandler();
268 softphotonhandler->AddRadiation( blob.get() );
272 const int nFinal( blob->NOutP() );
275 if ( nFinal > nDaughters ) {
276 for (
int iLoop = 0; iLoop < nFinal; iLoop++ ) {
277 const ATOOLS::Particle* outParticle = blob->OutParticle( iLoop );
278 const ATOOLS::Vec4D daughter_mom = outParticle->Momentum();
279 const long int pdgId = outParticle->Flav();
280 const EvtVector4R newP4( daughter_mom[0], daughter_mom[1],
281 daughter_mom[2], daughter_mom[3] );
282 const char daugInfo = outParticle->Info();
284 if ( iLoop < nDaughters ) {
287 if ( daugParticle ) {
290 }
else if ( pdgId ==
m_gammaPDG && daugInfo ==
'S' ) {
void setAttribute(std::string attName, int attValue)
const EvtVector4R & getP4() const
EvtParticle * getDaug(const int i)
void setP4WithFSR(const EvtVector4R &p4)
void addDaug(EvtParticle *node)
void init(EvtId part_n, double e, double px, double py, double pz)