JHUGen MELA  JHUGen v7.5.6, MELA v2.4.2
Matrix element calculations as used in JHUGen.
SpinPdfFactory Class Referenceabstract

#include <SpinPdfFactory.h>

Inheritance diagram for SpinPdfFactory:
Collaboration diagram for SpinPdfFactory:

Public Member Functions

 SpinPdfFactory (RooSpin::modelMeasurables const &measurables_, RooSpin::VdecayType V1decay_=RooSpin::kVdecayType_Zll, RooSpin::VdecayType V2decay_=RooSpin::kVdecayType_Zll, Bool_t OnshellH_=true)
 
virtual ~SpinPdfFactory ()
 
virtual void getMVGamV (Double_t *mV=0, Double_t *gamV=0) const
 
virtual void getMVprimeGamVprime (Double_t *mV=0, Double_t *gamV=0) const
 
virtual void makeParamsConst (bool yesNo)
 
virtual void makeCouplingsConst (bool yesNo)=0
 
virtual void resetHypotheses ()=0
 
virtual void resetVdecay (RooSpin::VdecayType V1decay_, RooSpin::VdecayType V2decay_)
 
virtual void resetVdecayParams (Double_t mWval, Double_t gamWval, Double_t mZval, Double_t gamZval, Double_t Sin2ThetaWval, Double_t vevval)
 
virtual void resetVprimeffCouplings (Double_t gVprimeff_decay1[2], Double_t gVprimeff_decay2[2])
 
virtual void resetVprimeMasses (Double_t mWval, Double_t gamWval, Double_t mZval, Double_t gamZval)
 
virtual void resetHiggsMassWidth (Double_t mXval, Double_t gamXval=0.)
 
virtual void defaultIntegration ()
 
virtual void alwaysIntegrate (Int_t code=1)
 
void setVerbosity (TVar::VerbosityLevel verbosity)
 

Static Public Member Functions

static void setVariableValue (RooRealVar *var, Double_t val)
 

Public Attributes

RooSpin::modelMeasurables measurables
 
RooSpin::modelParameters parameters
 

Protected Member Functions

virtual void initMeasurables (RooSpin::modelMeasurables const &measurables_)
 
virtual void initMassPole ()
 
virtual void initVdecayParams ()
 
virtual void destroyMassPole ()
 
virtual void destroyVdecayParams ()
 
virtual void initGVals ()=0
 
virtual void destroyGVals ()=0
 
virtual void initPDF ()=0
 
virtual void destroyPDF ()=0
 

Protected Attributes

RooSpin::VdecayType V1decay
 
RooSpin::VdecayType V2decay
 
Bool_t OnshellH
 
RooSpinPDF_base
 

Detailed Description

Definition at line 9 of file SpinPdfFactory.h.

Constructor & Destructor Documentation

◆ SpinPdfFactory()

SpinPdfFactory::SpinPdfFactory ( RooSpin::modelMeasurables const &  measurables_,
RooSpin::VdecayType  V1decay_ = RooSpin::kVdecayType_Zll,
RooSpin::VdecayType  V2decay_ = RooSpin::kVdecayType_Zll,
Bool_t  OnshellH_ = true 
)

Definition at line 8 of file SpinPdfFactory.cc.

8  :
9 V1decay(V1decay_),
10 V2decay(V2decay_),
11 OnshellH(OnshellH_)
12 {
13  initMeasurables(measurables_);
14  initMassPole();
16 }

◆ ~SpinPdfFactory()

SpinPdfFactory::~SpinPdfFactory ( )
virtual

Definition at line 18 of file SpinPdfFactory.cc.

18  {
21 }

Member Function Documentation

◆ alwaysIntegrate()

virtual void SpinPdfFactory::alwaysIntegrate ( Int_t  code = 1)
inlinevirtual

Definition at line 30 of file SpinPdfFactory.h.

30 { PDF_base->alwaysIntegrate(code); }

◆ defaultIntegration()

virtual void SpinPdfFactory::defaultIntegration ( )
inlinevirtual

Definition at line 29 of file SpinPdfFactory.h.

◆ destroyGVals()

virtual void SpinPdfFactory::destroyGVals ( )
protectedpure virtual

Implemented in ScalarPdfFactory, and TensorPdfFactory.

◆ destroyMassPole()

void SpinPdfFactory::destroyMassPole ( )
protectedvirtual

Definition at line 122 of file SpinPdfFactory.cc.

122  {
123  delete parameters.gamX;
124  if (!OnshellH) delete parameters.mX;
125 }

◆ destroyPDF()

virtual void SpinPdfFactory::destroyPDF ( )
protectedpure virtual

◆ destroyVdecayParams()

void SpinPdfFactory::destroyVdecayParams ( )
protectedvirtual

Definition at line 126 of file SpinPdfFactory.cc.

126  {
131  delete parameters.vev;
132  delete parameters.Sin2ThetaW;
133  delete parameters.gamZ;
134  delete parameters.mZ;
135  delete parameters.gamW;
136  delete parameters.mW;
137  delete parameters.gamZprime;
138  delete parameters.mZprime;
139  delete parameters.gamWprime;
140  delete parameters.mWprime;
141 }

◆ getMVGamV()

void SpinPdfFactory::getMVGamV ( Double_t *  mV = 0,
Double_t *  gamV = 0 
) const
virtual

Definition at line 86 of file SpinPdfFactory.cc.

86  {
88  if (mV!=0) (*mV)=(parameters.mW)->getVal();
89  if (gamV!=0) (*gamV)=(parameters.gamW)->getVal();
90  }
92  if (mV!=0) (*mV)=(parameters.mZ)->getVal();
93  if (gamV!=0) (*gamV)=(parameters.gamZ)->getVal();
94  }
95  else{
96  if (mV!=0) (*mV)=0;
97  if (gamV!=0) (*gamV)=0;
98  }
99 }

◆ getMVprimeGamVprime()

void SpinPdfFactory::getMVprimeGamVprime ( Double_t *  mV = 0,
Double_t *  gamV = 0 
) const
virtual

Definition at line 100 of file SpinPdfFactory.cc.

100  {
102  if (mV!=0) (*mV)=(parameters.mWprime)->getVal();
103  if (gamV!=0) (*gamV)=(parameters.gamWprime)->getVal();
104  }
106  if (mV!=0) (*mV)=(parameters.mZprime)->getVal();
107  if (gamV!=0) (*gamV)=(parameters.gamZprime)->getVal();
108  }
109  else{
110  if (mV!=0) (*mV)=0;
111  if (gamV!=0) (*gamV)=0;
112  }
113 }

◆ initGVals()

virtual void SpinPdfFactory::initGVals ( )
protectedpure virtual

Implemented in ScalarPdfFactory, and TensorPdfFactory.

◆ initMassPole()

void SpinPdfFactory::initMassPole ( )
protectedvirtual

Definition at line 33 of file SpinPdfFactory.cc.

33  {
34  if (!OnshellH) parameters.mX = new RooRealVar("mX", "mX", (measurables.m12)->getVal());
36  parameters.gamX = new RooRealVar("gamX", "gamX", 0);
37 }

◆ initMeasurables()

void SpinPdfFactory::initMeasurables ( RooSpin::modelMeasurables const &  measurables_)
protectedvirtual

Definition at line 22 of file SpinPdfFactory.cc.

22  {
23  measurables.h1 = (RooAbsReal*)measurables_.h1;
24  measurables.h2 = (RooAbsReal*)measurables_.h2;
25  measurables.Phi = (RooAbsReal*)measurables_.Phi;
26  measurables.m1 = (RooAbsReal*)measurables_.m1;
27  measurables.m2 = (RooAbsReal*)measurables_.m2;
28  measurables.m12 = (RooAbsReal*)measurables_.m12;
29  measurables.hs = (RooAbsReal*)measurables_.hs;
30  measurables.Phi1 = (RooAbsReal*)measurables_.Phi1;
31  measurables.Y = (RooAbsReal*)measurables_.Y;
32 }

◆ initPDF()

virtual void SpinPdfFactory::initPDF ( )
protectedpure virtual

◆ initVdecayParams()

void SpinPdfFactory::initVdecayParams ( )
protectedvirtual

Definition at line 45 of file SpinPdfFactory.cc.

45  {
46  if ((((int)V1decay)>0 && ((int)V2decay)<0) || (((int)V1decay)<0 && ((int)V2decay)>0)) MELAerr << "SpinPdfFactory::initVdecayParams: V1 and V2 decays are inconsistent!" << endl;
47 
48  const Double_t GfVal = 1.16639e-5;
49  const Double_t vevVal = 1./sqrt(GfVal*sqrt(2.));
50 
51  parameters.mW = new RooRealVar("mW", "mW", 80.399);
52  parameters.gamW = new RooRealVar("gamW", "gamW", 2.085);
53  parameters.mZ = new RooRealVar("mZ", "mZ", 91.1876);
54  parameters.gamZ = new RooRealVar("gamZ", "gamZ", 2.4952);
55  parameters.mWprime = new RooRealVar("mWprime", "mWprime", 0);
56  parameters.gamWprime = new RooRealVar("gamWprime", "gamWprime", -1); // Turns off Wprime
57  parameters.mZprime = new RooRealVar("mZprime", "mZprime", 0);
58  parameters.gamZprime = new RooRealVar("gamZprime", "gamZprime", -1); // Turns off Zprime
59  parameters.Sin2ThetaW = new RooRealVar("Sin2ThetaW", "Sin2ThetaW", 0.23119);
60  parameters.vev = new RooRealVar("vev", "vev", vevVal);
61  parameters.gVprimeff_decay1_left = new RooRealVar("gVprimeff_decay1_left", "gVprimeff_decay1_left", 0);
62  parameters.gVprimeff_decay1_right = new RooRealVar("gVprimeff_decay1_right", "gVprimeff_decay1_right", 0);
63  parameters.gVprimeff_decay2_left = new RooRealVar("gVprimeff_decay2_left", "gVprimeff_decay2_left", 0);
64  parameters.gVprimeff_decay2_right = new RooRealVar("gVprimeff_decay2_right", "gVprimeff_decay2_right", 0);
65 }

◆ makeCouplingsConst()

virtual void SpinPdfFactory::makeCouplingsConst ( bool  yesNo)
pure virtual

Implemented in ScalarPdfFactory, and TensorPdfFactory.

◆ makeParamsConst()

void SpinPdfFactory::makeParamsConst ( bool  yesNo)
virtual

Reimplemented in ScalarPdfFactory_HVV.

Definition at line 154 of file SpinPdfFactory.cc.

154  {
155  ((RooRealVar*) parameters.mX)->setConstant(yesNo);
156  ((RooRealVar*) parameters.gamX)->setConstant(yesNo);
157  ((RooRealVar*) parameters.mW)->setConstant(yesNo);
158  ((RooRealVar*) parameters.gamW)->setConstant(yesNo);
159  ((RooRealVar*) parameters.mZ)->setConstant(yesNo);
160  ((RooRealVar*) parameters.gamZ)->setConstant(yesNo);
161  ((RooRealVar*) parameters.mWprime)->setConstant(yesNo);
162  ((RooRealVar*) parameters.gamWprime)->setConstant(yesNo);
163  ((RooRealVar*) parameters.mZprime)->setConstant(yesNo);
164  ((RooRealVar*) parameters.gamZprime)->setConstant(yesNo);
165  ((RooRealVar*) parameters.Sin2ThetaW)->setConstant(yesNo);
166  ((RooRealVar*) parameters.vev)->setConstant(yesNo);
167  ((RooRealVar*) parameters.gVprimeff_decay1_left)->setConstant(yesNo);
168  ((RooRealVar*) parameters.gVprimeff_decay1_right)->setConstant(yesNo);
169  ((RooRealVar*) parameters.gVprimeff_decay2_left)->setConstant(yesNo);
170  ((RooRealVar*) parameters.gVprimeff_decay2_right)->setConstant(yesNo);
171 }

◆ resetHiggsMassWidth()

void SpinPdfFactory::resetHiggsMassWidth ( Double_t  mXval,
Double_t  gamXval = 0. 
)
virtual

Definition at line 38 of file SpinPdfFactory.cc.

38  {
39  if (!OnshellH){
40  if (dynamic_cast<RooRealVar*>(parameters.mX)!=0){ ((RooRealVar*)parameters.mX)->removeMin(); ((RooRealVar*)parameters.mX)->removeMax(); ((RooRealVar*)parameters.mX)->setConstant(false); ((RooRealVar*)parameters.mX)->setVal(mXval); ((RooRealVar*)parameters.mX)->setRange(mXval, mXval); ((RooRealVar*)parameters.mX)->setConstant(true); }
41  if (dynamic_cast<RooRealVar*>(parameters.gamX)!=0){ ((RooRealVar*)parameters.gamX)->removeMin(); ((RooRealVar*)parameters.gamX)->removeMax(); ((RooRealVar*)parameters.gamX)->setConstant(false); ((RooRealVar*)parameters.gamX)->setVal(gamXval); ((RooRealVar*)parameters.gamX)->setRange(gamXval, gamXval); ((RooRealVar*)parameters.gamX)->setConstant(true); }
42  }
43  else MELAerr << "SpinPdfFactory::resetHiggsMassWidth: Higgs mass is already determined by the virtuality with zero width. Cannot set Higgs mass or width" << endl;
44 }

◆ resetHypotheses()

virtual void SpinPdfFactory::resetHypotheses ( )
pure virtual

Implemented in ScalarPdfFactory, and TensorPdfFactory.

◆ resetVdecay()

void SpinPdfFactory::resetVdecay ( RooSpin::VdecayType  V1decay_,
RooSpin::VdecayType  V2decay_ 
)
virtual

Definition at line 114 of file SpinPdfFactory.cc.

114  {
115  if ((((int)V1decay)>0 && ((int)V2decay)<0) || (((int)V1decay)<0 && ((int)V2decay)>0)) MELAerr << "SpinPdfFactory::resetVdecay: V1 and V2 decays are inconsistent!" << endl;
116 
117  V1decay=V1decay_;
118  V2decay=V2decay_;
120 }

◆ resetVdecayParams()

void SpinPdfFactory::resetVdecayParams ( Double_t  mWval,
Double_t  gamWval,
Double_t  mZval,
Double_t  gamZval,
Double_t  Sin2ThetaWval,
Double_t  vevval 
)
virtual

Definition at line 66 of file SpinPdfFactory.cc.

66  {
67  SpinPdfFactory::setVariableValue(dynamic_cast<RooRealVar*>(parameters.mW), mWval);
68  SpinPdfFactory::setVariableValue(dynamic_cast<RooRealVar*>(parameters.gamW), gamWval);
69  SpinPdfFactory::setVariableValue(dynamic_cast<RooRealVar*>(parameters.mZ), mZval);
70  SpinPdfFactory::setVariableValue(dynamic_cast<RooRealVar*>(parameters.gamZ), gamZval);
71  SpinPdfFactory::setVariableValue(dynamic_cast<RooRealVar*>(parameters.Sin2ThetaW), Sin2ThetaWval);
72  SpinPdfFactory::setVariableValue(dynamic_cast<RooRealVar*>(parameters.vev), vevval);
73 }

◆ resetVprimeffCouplings()

void SpinPdfFactory::resetVprimeffCouplings ( Double_t  gVprimeff_decay1[2],
Double_t  gVprimeff_decay2[2] 
)
virtual

Definition at line 74 of file SpinPdfFactory.cc.

74  {
75  SpinPdfFactory::setVariableValue(dynamic_cast<RooRealVar*>(parameters.gVprimeff_decay1_left), gVprimeff_decay1[0]);
76  SpinPdfFactory::setVariableValue(dynamic_cast<RooRealVar*>(parameters.gVprimeff_decay1_right), gVprimeff_decay1[1]);
77  SpinPdfFactory::setVariableValue(dynamic_cast<RooRealVar*>(parameters.gVprimeff_decay2_left), gVprimeff_decay2[0]);
78  SpinPdfFactory::setVariableValue(dynamic_cast<RooRealVar*>(parameters.gVprimeff_decay2_right), gVprimeff_decay2[1]);
79 }

◆ resetVprimeMasses()

void SpinPdfFactory::resetVprimeMasses ( Double_t  mWval,
Double_t  gamWval,
Double_t  mZval,
Double_t  gamZval 
)
virtual

Definition at line 80 of file SpinPdfFactory.cc.

80  {
81  SpinPdfFactory::setVariableValue(dynamic_cast<RooRealVar*>(parameters.mWprime), mWval);
82  SpinPdfFactory::setVariableValue(dynamic_cast<RooRealVar*>(parameters.gamWprime), gamWval);
83  SpinPdfFactory::setVariableValue(dynamic_cast<RooRealVar*>(parameters.mZprime), mZval);
84  SpinPdfFactory::setVariableValue(dynamic_cast<RooRealVar*>(parameters.gamZprime), gamZval);
85 }

◆ setVariableValue()

void SpinPdfFactory::setVariableValue ( RooRealVar *  var,
Double_t  val 
)
static

Definition at line 143 of file SpinPdfFactory.cc.

143  {
144  if (var){
145  var->removeMin();
146  var->removeMax();
147  var->setConstant(false);
148  var->setVal(val);
149  var->setRange(val, val);
150  var->setConstant(true);
151  }
152 }

◆ setVerbosity()

void SpinPdfFactory::setVerbosity ( TVar::VerbosityLevel  verbosity)

Definition at line 173 of file SpinPdfFactory.cc.

173 { PDF_base->setVerbosity(verbosity); }

Member Data Documentation

◆ measurables

RooSpin::modelMeasurables SpinPdfFactory::measurables

Definition at line 11 of file SpinPdfFactory.h.

◆ OnshellH

Bool_t SpinPdfFactory::OnshellH
protected

Definition at line 41 of file SpinPdfFactory.h.

◆ parameters

RooSpin::modelParameters SpinPdfFactory::parameters

Definition at line 12 of file SpinPdfFactory.h.

◆ PDF_base

RooSpin* SpinPdfFactory::PDF_base
protected

Definition at line 43 of file SpinPdfFactory.h.

◆ V1decay

RooSpin::VdecayType SpinPdfFactory::V1decay
protected

Definition at line 38 of file SpinPdfFactory.h.

◆ V2decay

RooSpin::VdecayType SpinPdfFactory::V2decay
protected

Definition at line 39 of file SpinPdfFactory.h.


The documentation for this class was generated from the following files:
RooSpin::modelMeasurables::h2
RooAbsReal * h2
Definition: RooSpin.h:52
RooSpin::modelParameters::gamW
RooAbsReal * gamW
Definition: RooSpin.h:65
RooSpin::setVerbosity
void setVerbosity(TVar::VerbosityLevel verbosity_)
Definition: RooSpin.cc:376
RooSpin::modelMeasurables::Y
RooAbsReal * Y
Definition: RooSpin.h:59
SpinPdfFactory::setVariableValue
static void setVariableValue(RooRealVar *var, Double_t val)
Definition: SpinPdfFactory.cc:143
RooSpin::modelParameters::gamZ
RooAbsReal * gamZ
Definition: RooSpin.h:67
SpinPdfFactory::PDF_base
RooSpin * PDF_base
Definition: SpinPdfFactory.h:43
RooSpin::modelMeasurables::Phi1
RooAbsReal * Phi1
Definition: RooSpin.h:55
SpinPdfFactory::V1decay
RooSpin::VdecayType V1decay
Definition: SpinPdfFactory.h:38
RooSpin::modelParameters::mZ
RooAbsReal * mZ
Definition: RooSpin.h:66
RooSpin::modelMeasurables::m12
RooAbsReal * m12
Definition: RooSpin.h:58
RooSpin::modelMeasurables::m1
RooAbsReal * m1
Definition: RooSpin.h:56
RooSpin::modelParameters::gamZprime
RooAbsReal * gamZprime
Definition: RooSpin.h:71
RooSpin::modelParameters::gamWprime
RooAbsReal * gamWprime
Definition: RooSpin.h:69
RooSpin::modelParameters::mW
RooAbsReal * mW
Definition: RooSpin.h:64
RooSpin::modelParameters::mWprime
RooAbsReal * mWprime
Definition: RooSpin.h:68
SpinPdfFactory::parameters
RooSpin::modelParameters parameters
Definition: SpinPdfFactory.h:12
SpinPdfFactory::V2decay
RooSpin::VdecayType V2decay
Definition: SpinPdfFactory.h:39
RooSpin::modelParameters::gVprimeff_decay1_right
RooAbsReal * gVprimeff_decay1_right
Definition: RooSpin.h:75
RooSpin::kVdecayType_GammaOnshell
@ kVdecayType_GammaOnshell
Definition: RooSpin.h:30
RooSpin::modelParameters::gVprimeff_decay2_right
RooAbsReal * gVprimeff_decay2_right
Definition: RooSpin.h:77
RooSpin::modelMeasurables::Phi
RooAbsReal * Phi
Definition: RooSpin.h:54
RooSpin::modelParameters::mX
RooAbsReal * mX
Definition: RooSpin.h:62
SpinPdfFactory::OnshellH
Bool_t OnshellH
Definition: SpinPdfFactory.h:41
RooSpin::modelMeasurables::m2
RooAbsReal * m2
Definition: RooSpin.h:57
RooSpin::modelMeasurables::h1
RooAbsReal * h1
Definition: RooSpin.h:51
RooSpin::modelParameters::mZprime
RooAbsReal * mZprime
Definition: RooSpin.h:70
RooSpin::modelParameters::vev
RooAbsReal * vev
Definition: RooSpin.h:73
RooSpin::modelParameters::gamX
RooAbsReal * gamX
Definition: RooSpin.h:63
MELAStreamHelpers::MELAerr
MELAOutputStreamer MELAerr
RooSpin::modelParameters::Sin2ThetaW
RooAbsReal * Sin2ThetaW
Definition: RooSpin.h:72
SpinPdfFactory::destroyMassPole
virtual void destroyMassPole()
Definition: SpinPdfFactory.cc:122
SpinPdfFactory::initMassPole
virtual void initMassPole()
Definition: SpinPdfFactory.cc:33
SpinPdfFactory::initVdecayParams
virtual void initVdecayParams()
Definition: SpinPdfFactory.cc:45
RooSpin::modelParameters::gVprimeff_decay2_left
RooAbsReal * gVprimeff_decay2_left
Definition: RooSpin.h:76
RooSpin::modelParameters::gVprimeff_decay1_left
RooAbsReal * gVprimeff_decay1_left
Definition: RooSpin.h:74
RooSpin::alwaysIntegrate
virtual void alwaysIntegrate(Int_t code=1)
Definition: RooSpin.cc:120
RooSpin::setDecayModes
virtual void setDecayModes(RooSpin::VdecayType Vdecay1_, RooSpin::VdecayType Vdecay2_)
Definition: RooSpin.h:98
SpinPdfFactory::destroyVdecayParams
virtual void destroyVdecayParams()
Definition: SpinPdfFactory.cc:126
RooSpin::kVdecayType_Wany
@ kVdecayType_Wany
Definition: RooSpin.h:29
SpinPdfFactory::measurables
RooSpin::modelMeasurables measurables
Definition: SpinPdfFactory.h:11
SpinPdfFactory::initMeasurables
virtual void initMeasurables(RooSpin::modelMeasurables const &measurables_)
Definition: SpinPdfFactory.cc:22
RooSpin::modelMeasurables::hs
RooAbsReal * hs
Definition: RooSpin.h:53
RooSpin::defaultIntegration
virtual void defaultIntegration()
Definition: RooSpin.h:102