Belle II Software  release-08-01-10
BHWide Class Reference

C++ Interface for the Fortran Bhabha scattering generator BHWide. More...

#include <BHWide.h>

Public Types

enum  Channel {
  CH_BOTH = 0 ,
  CH_S_ONLY = 1 ,
  CH_T_ONLY = 2
}
 Call needed channels. More...
 
enum  RandomGenerator {
  RG_RANMAR = 1 ,
  RG_RANECU = 2
}
 Call random generator. More...
 
enum  EWCorrectionLib {
  EC_BABAMC = 1 ,
  EC_ALIBABA = 2
}
 Call electroweak correction. More...
 
enum  HardBremsModel {
  HM_HELICITY_AMP = 1 ,
  HM_CALKUL = 2
}
 Call Brem Model. More...
 
enum  PhotonVacPolarization {
  PP_OFF = 0 ,
  PP_BHLUMI = 1 ,
  PP_EIDELMAN = 2 ,
  PP_BURKHARDT = 3
}
 Call photon polarization. More...
 

Public Member Functions

 BHWide ()
 Constructor. More...
 
 ~BHWide ()
 Destrucotr.
 
void setDefaultSettings ()
 Sets the default settings for the BhWide Fortran generator.
 
void enableZContribution (bool zContribution=true)
 Enabled the Z contribution. More...
 
void setChannel (Channel channel)
 Set the type of channel which should be used. More...
 
void enableWeights (bool weighted=true)
 Enable the use of weighted events. More...
 
void setRandomGenerator (RandomGenerator randomGenerator)
 Set the type of the randomN nmber generator. More...
 
void enableWeakCorrections (bool weakCorrections=true)
 Enable the use of weak corrections. More...
 
void setElectroWeakCorrectionsLib (EWCorrectionLib ewCorrectionLib)
 Set the type of the electro weak correction library. More...
 
void setHardBremsModel (HardBremsModel hardBremsModel)
 Set the type of the hard bremsstrahlung model. More...
 
void setPhotonVacPolarization (PhotonVacPolarization photonVacPol)
 Set the model for the photon vacuum polarization. More...
 
void setCMSEnergy (double cmsEnergy)
 Sets the CMS energy. More...
 
void setScatAnglePositron (std::pair< double, double > angleRange)
 Sets the theta scattering angle range for the scattered positron. More...
 
void setScatAngleElectron (std::pair< double, double > angleRange)
 Sets the theta scattering angle range for the scattered electron. More...
 
void setMinEnergyFinalStatePos (double minEnergyFinalStatePos)
 Sets the minimal energy for the scattered positron. More...
 
void setMinEnergyFinalStateElc (double minEnergyFinalStateElc)
 Sets the minimal energy for the scattered electron. More...
 
void setMaxAcollinearity (double maxAcollinearity)
 Sets the max acollinearity angle. More...
 
void setInfCutCMSEnergy (double infCutCMSEnergy)
 Sets the CMS energy on which an infrared cut is performed. More...
 
void setMaxRejectionWeight (double maxRejectionWeight)
 Sets the max weight at which events are rejected. More...
 
void setMassZ (double massZ)
 Sets the mass of the Z Boson. More...
 
void setWidthZ (double widthZ)
 Sets the width of the Z Boson. More...
 
void setSinW2 (double sinW2)
 Sets the value for the sinW2. More...
 
void setMassTop (double massTop)
 Sets the mass for the top quark. More...
 
void setMassHiggs (double massHiggs)
 Sets the mass for the Higgs Boson. More...
 
void init ()
 Initializes the generator. More...
 
void generateEvent (MCParticleGraph &mcGraph, ROOT::Math::XYZVector vertex, ROOT::Math::LorentzRotation boost)
 Generates one single event. More...
 
void term ()
 Terminates the generator. More...
 
double getCrossSection ()
 Returns the total cross section of the generated process. More...
 
double getCrossSectionError ()
 Returns the error on the total cross section of the generated process. More...
 

Protected Member Functions

void applySettings ()
 Apply the settings to the internal Fortran generator.
 
void storeParticle (MCParticleGraph &mcGraph, const double *mom, int pdg, ROOT::Math::XYZVector vertex, ROOT::Math::LorentzRotation boost, bool isVirtual=false, bool isInitial=false)
 Store a single generated particle into the MonteCarlo graph. More...
 

Protected Attributes

bool m_zContribution
 Z-contribution ON/OFF.
 
Channel m_channel
 Channel choice.
 
bool m_weighted
 Switch for constant, variable weight. More...
 
RandomGenerator m_randomGenerator
 Type of random number generator.
 
bool m_weakCorrections
 Switching ON/OFF weak corrections. More...
 
EWCorrectionLib m_ewCorrectionLib
 Option for ElectroWeak Corrections Library.
 
HardBremsModel m_hardBremsModel
 type of MODEL subprogram and QED matrix element for hard bremsstrahlung.
 
PhotonVacPolarization m_photonVacPol
 Photon vacuum polarization switch.
 
double m_cmsEnergy
 CMS Energy = 2*Ebeam [GeV].
 
std::pair< double, double > m_ScatteringAngleRangePositron
 Min and Max value for the scattering angle [deg] of the positron.
 
std::pair< double, double > m_ScatteringAngleRangeElectron
 Min and Max value for the scattering angle [deg] of the electron.
 
double m_minEnergyFinalStatePos
 Minimum energy [GeV] for final state positron.
 
double m_minEnergyFinalStateElc
 Minimum energy [GeV] for final state electron.
 
double m_maxAcollinearity
 Maximum acollinearity [deg] of final state e+e-.
 
double m_infCutCMSEnergy
 Dimensionless infrared cut on CMS energy of soft photons, ( E_phot > CMSENE*EPSCMS/2 ).
 
double m_maxRejectionWeight
 Maximum Weight for rejection (if <= 0, it is reset inside the program).
 
double m_massZ
 Z mass [GeV].
 
double m_widthZ
 Z width [GeV] (may be recalculated by EW library).
 
double m_sinW2
 sin^2(theta_W) (may be recalculated by EW library).
 
double m_massTop
 top quark mass [GeV].
 
double m_massHiggs
 Higgs mass [GeV].
 
double m_crossSection
 The cross section of the generated bhabha scattering events.
 
double m_crossSectionError
 The error on the cross section of the generated bhabha scattering events.
 

Private Attributes

int m_npar [100]
 Integer parameters for BHWide.
 
double m_xpar [100]
 Double parameters for BHWide.
 

Detailed Description

C++ Interface for the Fortran Bhabha scattering generator BHWide.

IMPOTRANT NOTE: In the case of generating UNWEIGHTED events, the user should check in the OUTPUT if the number of OVERWEIGHTED events and/or the fraction of the corresponding cross section is ACCEPTABLE for his/her desired PRECISION. If not, the value of WTMAX has to be adjusted (increased) accordingly (making a histogram of the weight might be helpful).

Definition at line 32 of file BHWide.h.

Member Enumeration Documentation

◆ Channel

enum Channel

Call needed channels.

Enumerator
CH_BOTH 

both s and t-channels + interferences.

CH_S_ONLY 

only s-channel (for tests!), with model == HM_CALKUL.

CH_T_ONLY 

only t-channel (for tests!), with model == HM_CALKUL.

Definition at line 36 of file BHWide.h.

36  {
37  CH_BOTH = 0,
38  CH_S_ONLY = 1,
39  CH_T_ONLY = 2
40  };
@ CH_T_ONLY
only t-channel (for tests!), with model == HM_CALKUL.
Definition: BHWide.h:39
@ CH_S_ONLY
only s-channel (for tests!), with model == HM_CALKUL.
Definition: BHWide.h:38
@ CH_BOTH
both s and t-channels + interferences.
Definition: BHWide.h:37

◆ EWCorrectionLib

Call electroweak correction.

Enumerator
EC_BABAMC 

ElectroWeak Corr.

from BABAMC (obsolete).

EC_ALIBABA 

ElectroWeak Corr.

from ALIBABA, RECOMMENDED.

Definition at line 49 of file BHWide.h.

◆ HardBremsModel

Call Brem Model.

Enumerator
HM_HELICITY_AMP 

obtained by the BHWide authors (helicity amplitudes).

HM_CALKUL 

from CALKUL, Nucl.

Phys. B206 (1982) 61.

Definition at line 55 of file BHWide.h.

◆ PhotonVacPolarization

Call photon polarization.

Enumerator
PP_OFF 

Photon vacuum polarization is off.

PP_BHLUMI 

Burkhardt et.al.

1989, as in BHLUMI 2.0x.

PP_EIDELMAN 

S.

Eidelman, F. Jegerlehner, Z.Phys.C(1995)

PP_BURKHARDT 

Burkhardt and Pietrzyk 1995 (Moriond).

Definition at line 61 of file BHWide.h.

◆ RandomGenerator

Call random generator.

Enumerator
RG_RANMAR 

Ranmar generator.

RG_RANECU 

Ranecu generator.

Definition at line 43 of file BHWide.h.

Constructor & Destructor Documentation

◆ BHWide()

BHWide ( )

Constructor.

Sets the default settings.

Definition at line 60 of file BHWide.cc.

61 {
62  for (int i = 0; i < 100; ++i) {
63  m_npar[i] = 0;
64  m_xpar[i] = 0.0;
65  }
66 
67  m_crossSection = 0.;
69 
71 }
int m_npar[100]
Integer parameters for BHWide.
Definition: BHWide.h:261
void setDefaultSettings()
Sets the default settings for the BhWide Fortran generator.
Definition: BHWide.cc:80
double m_crossSection
The cross section of the generated bhabha scattering events.
Definition: BHWide.h:240
double m_xpar[100]
Double parameters for BHWide.
Definition: BHWide.h:262
double m_crossSectionError
The error on the cross section of the generated bhabha scattering events.
Definition: BHWide.h:241

Member Function Documentation

◆ enableWeakCorrections()

void enableWeakCorrections ( bool  weakCorrections = true)
inline

Enable the use of weak corrections.

Parameters
weakCorrectionsSet to true to use weak corrections.

Definition at line 102 of file BHWide.h.

◆ enableWeights()

void enableWeights ( bool  weighted = true)
inline

Enable the use of weighted events.

Parameters
weightedSet to false to generate events for an unweighted MonteCarlo detector simulation.

Definition at line 92 of file BHWide.h.

◆ enableZContribution()

void enableZContribution ( bool  zContribution = true)
inline

Enabled the Z contribution.

Parameters
zContributionSet to true to enabled the Z contribution.

Definition at line 82 of file BHWide.h.

◆ generateEvent()

void generateEvent ( MCParticleGraph mcGraph,
ROOT::Math::XYZVector  vertex,
ROOT::Math::LorentzRotation  boost 
)

Generates one single event.

Parameters
mcGraphReference to the MonteCarlo graph into which the generated particles will be stored.
vertexgenerated vertex.
boostgenerated boost.

Definition at line 116 of file BHWide.cc.

◆ getCrossSection()

double getCrossSection ( )
inline

Returns the total cross section of the generated process.

Returns
The total cross section.

Definition at line 205 of file BHWide.h.

◆ getCrossSectionError()

double getCrossSectionError ( )
inline

Returns the error on the total cross section of the generated process.

Returns
The error on the total cross section.

Definition at line 210 of file BHWide.h.

◆ init()

void init ( )

Initializes the generator.

Sets the default values for the internal Fortran generator.

Definition at line 108 of file BHWide.cc.

◆ setChannel()

void setChannel ( Channel  channel)
inline

Set the type of channel which should be used.

Parameters
channelThe type of channel: s, t or both.

Definition at line 87 of file BHWide.h.

◆ setCMSEnergy()

void setCMSEnergy ( double  cmsEnergy)
inline

Sets the CMS energy.

Parameters
cmsEnergyThe CMS energy in [GeV].

Definition at line 122 of file BHWide.h.

◆ setElectroWeakCorrectionsLib()

void setElectroWeakCorrectionsLib ( EWCorrectionLib  ewCorrectionLib)
inline

Set the type of the electro weak correction library.

Parameters
ewCorrectionLibThe electro weak correction library which is used: BABAMC or ALIBABA.

Definition at line 107 of file BHWide.h.

◆ setHardBremsModel()

void setHardBremsModel ( HardBremsModel  hardBremsModel)
inline

Set the type of the hard bremsstrahlung model.

Parameters
hardBremsModelThe model which is used for the hard bremsstrahlung: helicity amplitudes or CALKUL.

Definition at line 112 of file BHWide.h.

◆ setInfCutCMSEnergy()

void setInfCutCMSEnergy ( double  infCutCMSEnergy)
inline

Sets the CMS energy on which an infrared cut is performed.

Parameters
infCutCMSEnergyThe CMS energy in [Gev] at which an infrared cut is performed.

Definition at line 152 of file BHWide.h.

◆ setMassHiggs()

void setMassHiggs ( double  massHiggs)
inline

Sets the mass for the Higgs Boson.

Parameters
massHiggsThe mass for the Higgs Boson in [GeV].

Definition at line 182 of file BHWide.h.

◆ setMassTop()

void setMassTop ( double  massTop)
inline

Sets the mass for the top quark.

Parameters
massTopThe mass for the top quark in [GeV].

Definition at line 177 of file BHWide.h.

◆ setMassZ()

void setMassZ ( double  massZ)
inline

Sets the mass of the Z Boson.

Parameters
massZThe mass of the Z Boson in [Gev].

Definition at line 162 of file BHWide.h.

◆ setMaxAcollinearity()

void setMaxAcollinearity ( double  maxAcollinearity)
inline

Sets the max acollinearity angle.

Parameters
maxAcollinearityThe max acollinearity angle in [deg].

Definition at line 147 of file BHWide.h.

◆ setMaxRejectionWeight()

void setMaxRejectionWeight ( double  maxRejectionWeight)
inline

Sets the max weight at which events are rejected.

Parameters
maxRejectionWeightThe weight at which events are rejected.

Definition at line 157 of file BHWide.h.

◆ setMinEnergyFinalStateElc()

void setMinEnergyFinalStateElc ( double  minEnergyFinalStateElc)
inline

Sets the minimal energy for the scattered electron.

Parameters
minEnergyFinalStateElcThe minimal energy for the scattered electron in [GeV].

Definition at line 142 of file BHWide.h.

◆ setMinEnergyFinalStatePos()

void setMinEnergyFinalStatePos ( double  minEnergyFinalStatePos)
inline

Sets the minimal energy for the scattered positron.

Parameters
minEnergyFinalStatePosThe minimal energy for the scattered positron in [GeV].

Definition at line 137 of file BHWide.h.

◆ setPhotonVacPolarization()

void setPhotonVacPolarization ( PhotonVacPolarization  photonVacPol)
inline

Set the model for the photon vacuum polarization.

Parameters
photonVacPolThe model for the photon vacuum polarization: Off, BHLUMI, Eidelman or Burkhardt. photonVacPol.

Definition at line 117 of file BHWide.h.

◆ setRandomGenerator()

void setRandomGenerator ( RandomGenerator  randomGenerator)
inline

Set the type of the randomN nmber generator.

Parameters
randomGeneratorThe type of the random number generator: Ranmar or Ranecu.

Definition at line 97 of file BHWide.h.

◆ setScatAngleElectron()

void setScatAngleElectron ( std::pair< double, double >  angleRange)
inline

Sets the theta scattering angle range for the scattered electron.

Parameters
angleRangeA pair of values, representing the min and max theta angle of the scattered electron in [deg].

Definition at line 132 of file BHWide.h.

◆ setScatAnglePositron()

void setScatAnglePositron ( std::pair< double, double >  angleRange)
inline

Sets the theta scattering angle range for the scattered positron.

Parameters
angleRangeA pair of values, representing the min and max theta angle of the scattered positron in [deg].

Definition at line 127 of file BHWide.h.

◆ setSinW2()

void setSinW2 ( double  sinW2)
inline

Sets the value for the sinW2.

Parameters
sinW2The value for the sinW2.

Definition at line 172 of file BHWide.h.

◆ setWidthZ()

void setWidthZ ( double  widthZ)
inline

Sets the width of the Z Boson.

Parameters
widthZThe width of the Z Boson in [GeV].

Definition at line 167 of file BHWide.h.

◆ storeParticle()

void storeParticle ( MCParticleGraph mcGraph,
const double *  mom,
int  pdg,
ROOT::Math::XYZVector  vertex,
ROOT::Math::LorentzRotation  boost,
bool  isVirtual = false,
bool  isInitial = false 
)
protected

Store a single generated particle into the MonteCarlo graph.

Parameters
mcGraphReference to the MonteCarlo graph into which the particle should be stored.
momThe 3-momentum of the particle in [GeV].
pdgThe PDG code of the particle.
vertexProduction vertex.
boostLorentz boost vector.
isVirtualIf the particle is a virtual particle, such as the incoming particles, set this to true.
isInitialIf the particle is a initial particle for ISR, set this to true.

Definition at line 187 of file BHWide.cc.

◆ term()

void term ( )

Terminates the generator.

Closes the internal Fortran generator and retrieves the total cross section.

Definition at line 138 of file BHWide.cc.

Member Data Documentation

◆ m_weakCorrections

bool m_weakCorrections
protected

Switching ON/OFF weak corrections.

true = all ElectroWeak Corrections included, false = only QED corrections included.

Definition at line 219 of file BHWide.h.

◆ m_weighted

bool m_weighted
protected

Switch for constant, variable weight.

Unweighted events for detector simulation, or weighted events.

Definition at line 217 of file BHWide.h.


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