cepgen is hosted by Hepforge, IPPP Durham
CepGen 1.2.5
Central exclusive processes event generator
Loading...
Searching...
No Matches
pythia6_decay.cc
Go to the documentation of this file.
2#include "CepGen/Generator.h"
5#include "CepGen/Utils/Test.h"
6
7using namespace std;
8
9int main() {
11
12 auto pythia = cepgen::EventModifierFactory::get().build("pythia6");
13
14 cepgen::Event evt;
16 tau.setMomentum(cepgen::Momentum(0., 0., 1000.), false);
17 evt.addParticle(tau);
18 const auto evt_size_bef = evt.size();
19
20 double weight;
21 pythia->run(evt, weight, false);
22
23 CG_LOG << evt;
24 CG_TEST_EQUAL(evt[0].status(), cepgen::Particle::Status::Resonance, "tau 'decayed' status");
25 CG_TEST(evt_size_bef != evt.size(), "decay");
26
28}
#define CG_LOG
Definition Message.h:212
#define CG_TEST_SUMMARY
Definition Test.h:127
#define CG_TEST_EQUAL(var1, var2, name)
Definition Test.h:45
#define CG_TEST(test_cond, name)
Definition Test.h:30
Container for the information on the in- and outgoing particles' kinematics.
Definition Event.h:28
size_t size() const
Number of particles in the event.
Definition Event.cpp:345
ParticleRef addParticle(Particle &part, bool replace=false)
Set the information on one particle in the process.
Definition Event.cpp:323
Container for a particle's 4-momentum, along with useful methods to ease the development of any matri...
Definition Momentum.h:33
Kinematic information for one particle.
Definition Particle.h:33
@ Undecayed
Particle to be decayed externally.
@ Resonance
Already decayed intermediate resonance.
@ CentralSystem
Central particles system.
Definition Particle.h:56
void initialise(bool safe_mode)
int main()