ATLAS Offline Software
Loading...
Searching...
No Matches
suep_shower.h
Go to the documentation of this file.
1/*
2 * This file is taken from the available public code at:
3 * https://gitlab.com/simonknapen/suep_generator
4 * by Simon Knapen.
5 */
6#ifndef SUEPSHOWER_h
7#define SUEPSHOWER_h
8
9#include <vector>
10#include <math.h>
11#include "Pythia8/PhaseSpace.h"
12#include "Pythia8/Basics.h"
13
14//** Auxiliary class for tolerance checks */
15class tolerance {
16 public:
17 tolerance(double eps) :
18 m_eps(eps) {
19 }
20 bool operator()(double a, double b) {
21 return (std::abs(b - a) <= m_eps);
22 }
23 private:
24 double m_eps;
25};
26
31{
32 public:
33
40 Suep_shower(double mass, double temperature, double energy, Pythia8::Rndm *rndm = 0);
41
43 std::vector< Pythia8::Vec4 > generate_shower();
44
45 protected:
46
48 Pythia8::Rndm *m_rndmEngine;
49
51 double m_m;
52
54 double m_Temp;
55
57 double m_Etot;
58
59 protected:
60
62 double f(double p);
63
65 double fp(double p);
66
68 double test_fun(double p);
69
71 Pythia8::Vec4 generateFourVector();
72
75 double reballance_func(double a, const std::vector< Pythia8::Vec4 > &event);
76
77 private:
79 double m_A;
81 double m_p_m;
88
89};
90
91#endif
static Double_t a
Suep_shower(double mass, double temperature, double energy, Pythia8::Rndm *rndm=0)
Constructor.
double test_fun(double p)
Test function to be solved for p_plus,p_minus.
double m_p_m
convenience function of mass/Temperature ratio
Definition suep_shower.h:81
double fp(double p)
Derivative of Maxwell-Boltzmann.
double m_q_plus
solutions for shower generation.
Definition suep_shower.h:87
double m_p_minus
Definition suep_shower.h:83
Pythia8::Vec4 generateFourVector()
generate one random 4 vector from the thermal distribution
double m_q_minus
Definition suep_shower.h:87
double m_m
Mass of the dark mesons to be generated in the shower.
Definition suep_shower.h:51
Pythia8::Rndm * m_rndmEngine
Random number generator, if not provided will use rand().
Definition suep_shower.h:48
double m_p_plus
solutions for shower generation.
Definition suep_shower.h:83
double f(double p)
Maxwell-Boltzman distribution, slightly massaged.
double m_lambda_minus
Definition suep_shower.h:85
double m_Etot
Total energy of the system.
Definition suep_shower.h:57
double m_Temp
Temperature parameter.
Definition suep_shower.h:54
double m_lambda_plus
solutions in Lambda for shower generation
Definition suep_shower.h:85
std::vector< Pythia8::Vec4 > generate_shower()
Generate a shower event, in the rest frame of the showe.
double m_q_m
Definition suep_shower.h:87
double reballance_func(double a, const std::vector< Pythia8::Vec4 > &event)
auxiliary function which computes the total energy difference as a function of the momentum vectors a...
double m_A
mass/Temperature ratio
Definition suep_shower.h:79
tolerance(double eps)
Definition suep_shower.h:17
double m_eps
Definition suep_shower.h:24
bool operator()(double a, double b)
Definition suep_shower.h:20