REST-for-Physics  v2.3
Rare Event Searches ToolKit for Physics
Public Member Functions | Protected Member Functions | Private Attributes
TRestAxionHelioscopeSignal Class Reference

Detailed Description

It allows to build a signal model using a given helioscope configuration and solar axion flux component.

This class describes an axion helioscope signal using different aproximations, calculating an expected rate as a function of energy (independent of position).

<TRestAxionHelioscopeSignal name="BabyIAXO" nature="signal"
conversionType="IAXO" bores="2"
magnetRadius="35cm" magnetLength="10m"
magnetStrength="2T" opticsEfficiency="0.3"
windowEfficiency="0.8">
<!-- TRestComponent common fields -->
<parameter name="parameterizationNodes" value="{0.0001,0.001,0.01,0.1,1}" />
<cVariable name="energy" range="(0,10)keV" bins="20" />
<!-- Solar flux -->
<TRestAxionSolarQCDFlux name="LennertHoofPrimakoff" verboseLevel="warning" >
<parameter name="couplingType" value="g_ag"/>
<parameter name="couplingStrength" value="1.e-10"/>
<parameter name="fluxDataFile"
value="Primakoff_LennertHoof_202203.dat"/>
<parameter name="seed" value="137" />
<!-- Buffer gas -->
<TRestAxionBufferGas name="helium" verboseLevel="warning">
<gas name="He" density="0.0025e-6g/cm^3"/>
<!-- Detector response -->
<TRestResponse name="XenonNeon" variable="energy">
<parameter name="filename" value="XenonNeon_50Pct_1.4bar.N150f" />
A metadata class to define the gas properties used in axion search calculations.
It allows to build a signal model using a given helioscope configuration and solar axion flux compone...
A metadata class to load tabulated solar axion fluxes. Mass independent.
It defines a background/signal model distribution in a given parameter space (tipically x,...
A response matrix that might be applied to a given component inside a TRestComponent.
Definition: TRestResponse.h:29

REST-for-Physics - Software for Rare Event Searches Toolkit

History of developments:

2023-December: First implementation of TRestAxionHelioscopeSignal Javier Galan

Author
: Javier Galan (javie.nosp@m.r.ga.nosp@m.lan.l.nosp@m.acar.nosp@m.ra@ce.nosp@m.rn.c.nosp@m.h)

Definition at line 33 of file TRestAxionHelioscopeSignal.h.

#include <TRestAxionHelioscopeSignal.h>

Inheritance diagram for TRestAxionHelioscopeSignal:
TRestComponent TRestMetadata

Public Member Functions

 ClassDefOverride (TRestAxionHelioscopeSignal, 1)
 
TRestAxionSolarFluxGetFlux ()
 
TRestAxionBufferGasGetGas ()
 
Double_t GetMagnetLength () const
 
Double_t GetMagnetRadius () const
 
Double_t GetMagnetStrength () const
 
Int_t GetNumberOfBores () const
 
Double_t GetSignalRate (Double_t mass, Double_t Eo, Double_t Ef)
 It returns the intensity/rate (in seconds) corresponding to the class defined helioscope configuration integrated in the energy range given by argument. More...
 
Double_t GetSignalRate (std::vector< Double_t > point, Double_t mass=0)
 It returns the intensity/rate (in seconds) corresponding to the class defined helioscope configuration evaluated at the position of the parameter space given by point, which by now is simply the energy. More...
 
std::string GetType () const
 
void Initialize () override
 It will initialize the data frame with the filelist and column names (or observables) that have been defined by the user. More...
 
void PrintMetadata () override
 Prints on screen the information about the metadata members of TRestAxionSolarFlux. More...
 
void SetMagnetLength (const Double_t &length)
 
void SetMagnetRadius (const Double_t &radius)
 
void SetMagnetStrength (const Double_t &strength)
 
void SetNumberOfBores (const Int_t &bores)
 
void SetType (const std::string &type)
 
 TRestAxionHelioscopeSignal ()
 Default constructor. More...
 
 TRestAxionHelioscopeSignal (const char *cfgFileName, const std::string &name)
 Constructor loading data from a config file. More...
 
 ~TRestAxionHelioscopeSignal ()
 Default destructor. More...
 
- Public Member Functions inherited from TRestComponent
 ClassDefOverride (TRestComponent, 6)
 
void DisableInterpolation ()
 
TCanvas * DrawComponent (std::vector< std::string > drawVariables, std::vector< std::string > scanVariables, Int_t binScanSize=1, TString drawOption="")
 A method allowing to draw a series of plots representing the density distributions. More...
 
void EnableInterpolation ()
 
Int_t FindActiveNode (Double_t node)
 It returns the position of the fParameterizationNodes element for the variable name given by argument. More...
 
Int_t GetActiveNode ()
 
Double_t GetActiveNodeValue ()
 
Double_t GetAllNodesIntegratedRate ()
 This method returns the integrated total rate for all the nodes The result will be returned in s-1. More...
 
Double_t GetBinCenter (Int_t nDim, const Int_t bin)
 It returns the bin center of the given component dimension. More...
 
THnD * GetDensity ()
 
THnD * GetDensityForActiveNode ()
 
THnD * GetDensityForNode (Double_t value)
 
size_t GetDimensions ()
 
TH1D * GetHistogram (Double_t node, std::string varName)
 It returns a 1-dimensional projected histogram for the variable names provided in the argument. More...
 
TH2D * GetHistogram (Double_t node, std::string varName1, std::string varName2)
 It returns the 2-dimensional projected histogram for the variable names provided in the argument. More...
 
TH3D * GetHistogram (Double_t node, std::string varName1, std::string varName2, std::string varName3)
 It returns the 3-dimensional projected histogram for the variable names provided in the argument. More...
 
TH1D * GetHistogram (std::string varName)
 It returns a 1-dimensional projected histogram for the variable names provided in the argument. It will recover the histogram corresponding to the active node. More...
 
TH2D * GetHistogram (std::string varName1, std::string varName2)
 It returns a 2-dimensional projected histogram for the variable names provided in the argument. It will recover the histogram corresponding to the active node. More...
 
TH3D * GetHistogram (std::string varName1, std::string varName2, std::string varName3)
 It returns a 3-dimensional projected histogram for the variable names provided in the argument. It will recover the histogram corresponding to the active node. More...
 
Double_t GetMaxRate ()
 This method returns the total rate for the node that has the highest contribution The result will be returned in s-1. More...
 
ROOT::RDF::RNode GetMonteCarloDataFrame (Int_t N=100)
 
std::string GetNature () const
 
std::vector< Int_t > GetNbins () const
 
Double_t GetNormalizedRate (std::vector< Double_t > point)
 It returns the intensity/rate (in seconds) corresponding to the generated distribution or formula evaluated at the position of the parameter space given by point. More...
 
std::vector< Double_t > GetParameterizationNodes ()
 
Float_t GetPrecision ()
 
ROOT::RVecD GetRandom ()
 
std::vector< TVector2 > GetRanges () const
 
Double_t GetRate (std::vector< Double_t > point)
 It returns the intensity/rate (in seconds) corresponding to the generated distribution or formula evaluated at the position of the parameter space given by point. More...
 
Double_t GetRawRate (std::vector< Double_t > point)
 It returns the intensity/rate (in seconds) corresponding to the generated distribution or formula evaluated at the position of the parameter space given by point. The returned rate is integrated to the granularity of the parameter space (cell size). To get a normalized rate use TRestComponent::GetNormalizedRate. More...
 
TRestResponseGetResponse () const
 
Int_t GetSamples ()
 
Double_t GetTotalRate ()
 This method integrates the rate to all the parameter space defined in the density function. The result will be returned in s-1. More...
 
std::vector< std::string > GetVariables () const
 
Bool_t HasNodes ()
 It returns true if any nodes have been defined. More...
 
void Initialize () override
 It initializes the random number. We avoid to define the section name here since we will never define a TRestComponent section in our RML file, since this class is pure virtual. It will be the inherited class the responsible to define the section name. More...
 
Bool_t Interpolation ()
 
void LoadResponse (const TRestResponse &resp)
 
void PrintMetadata () override
 Prints on screen the information about the metadata members of TRestAxionSolarFlux. More...
 
void PrintNodes ()
 It prints out on screen the values of the parametric node. More...
 
void PrintStatistics ()
 
virtual void RegenerateActiveNodeDensity ()
 
void RegenerateHistograms (UInt_t seed=0)
 It will produce a histogram with the distribution defined using the variables and the weights for each of the parameter nodes. More...
 
void RegenerateParametricNodes (Double_t from, Double_t to, Double_t step, Bool_t expIncrease=false)
 It allows to produce a parameter nodes list providing the initial value, the final value and the step. We might chose the step growing in linear increase steps or exponential. Linear is the default value. More...
 
Int_t SetActiveNode (Double_t node)
 It returns the position of the fParameterizationNodes element for the variable name given by argument. More...
 
Int_t SetActiveNode (Int_t n)
 
void SetPrecision (const Float_t &pr)
 
void SetSamples (Int_t samples)
 
 TRestComponent ()
 Default constructor. More...
 
 TRestComponent (const char *cfgFileName, const std::string &name="")
 Constructor loading data from a config file. More...
 
 ~TRestComponent ()
 Default destructor. More...
 

Protected Member Functions

void FillHistograms () override
 It will produce a histogram with the distribution using the formula contributions. More...
 
void InitFromConfigFile () override
 It customizes the retrieval of XML data values of this class. More...
 
- Protected Member Functions inherited from TRestComponent
virtual void FillHistograms ()=0
 
Int_t GetVariableIndex (std::string varName)
 It returns the position of the fVariable element for the variable name given by argument. More...
 
Bool_t HasDensity ()
 
void InitFromConfigFile () override
 It customizes the retrieval of XML data values of this class. More...
 
Bool_t ValidNode (Double_t node)
 It returns true if the node has been properly identified. More...
 

Private Attributes

Int_t fBores = 2
 It defines the number of bores or TPCs (number of magnetic volumes) More...
 
std::string fConversionType = "IAXO"
 It defines the helioscope type (IAXO/AMELIE) More...
 
TRestAxionFieldfField = nullptr
 It provides access to axion-photon conversion probabilites calculations. More...
 
TRestAxionSolarFluxfFlux = nullptr
 It defines the solar flux we use inside our magnetic field. Must be defined. More...
 
TRestAxionBufferGasfGas = nullptr
 It defines the gas mixture we use inside our magnetic field. Vacuum if it is nullptr. More...
 
Double_t fMagnetLength = 10000
 It defines the magnet length in standard REST units (mm) More...
 
Double_t fMagnetRadius = 350
 It defines the magnet aperture radius in standard REST units (mm) More...
 
Double_t fMagnetStrength = 2
 It defines the magnetic field strength in T. More...
 
Double_t fOpticsEfficiency = 1
 If optics is present we may add an efficiency for Ngamma calculation. More...
 
Double_t fWindowEfficiency = 1
 If an x-ray window is present we may add an efficiency for Ngamma calculation. More...
 

Additional Inherited Members

- Protected Attributes inherited from TRestComponent
Int_t fActiveNode = -1
 It is used to define the node that will be accessed for rate retrieval. More...
 
TCanvas * fCanvas = nullptr
 A canvas for drawing the active node component. More...
 
Bool_t fExponential = false
 It true the parametric values automatically generated will grow exponentially. More...
 
Double_t fFirstParameterValue = 0
 It defines the first parametric node value in case of automatic parameter generation. More...
 
Bool_t fInterpolation = true
 Enables or disables the interpolation at TRestComponentDataSet::GetRawRate. More...
 
Double_t fLastParameterValue = 0
 It defines the upper limit for the automatic parametric node values generation. More...
 
std::string fNature = "unknown"
 It defines the component type (unknown/signal/background) More...
 
std::vector< Int_t > fNbins
 The number of bins in which we should divide each variable. More...
 
std::vector< THnD * > fNodeDensity
 The generated N-dimensional variable space density for a given node. More...
 
std::string fParameter = ""
 It is used to parameterize a set of distribution densities (e.g. WIMP or axion mass) More...
 
std::vector< Double_t > fParameterizationNodes
 It defines the nodes of the parameterization (Initialized by the dataset) More...
 
Float_t fPrecision = 0.01
 A precision used to select the node value with a given range defined as a fraction of the value. More...
 
TRandom3 * fRandom = nullptr
 Internal process random generator. More...
 
std::vector< TVector2 > fRanges
 The range of each of the variables used to create the PDF distribution. More...
 
TRestResponsefResponse = nullptr
 A pointer to the detector response. More...
 
Int_t fSamples = 0
 It introduces a fixed number of samples (if 0 it will take all available samples) More...
 
UInt_t fSeed = 0
 Seed used in random generator. More...
 
Double_t fStepParameterValue = 0
 It defines the increasing step for automatic parameter list generation. More...
 
std::vector< std::string > fVariables
 A list with the branches that will be used to create the distribution space. More...
 

Constructor & Destructor Documentation

◆ TRestAxionHelioscopeSignal() [1/2]

TRestAxionHelioscopeSignal::TRestAxionHelioscopeSignal ( const char *  cfgFileName,
const std::string &  name 
)

Constructor loading data from a config file.

If no configuration path is defined using TRestMetadata::SetConfigFilePath the path to the config file must be specified using full path, absolute or relative.

The default behaviour is that the config file must be specified with full path, absolute or relative.

Parameters
cfgFileNameA const char* giving the path to an RML file.
nameThe name of the specific metadata. It will be used to find the corresponding TRestAxionMagneticField section inside the RML.

Definition at line 104 of file TRestAxionHelioscopeSignal.cxx.

◆ TRestAxionHelioscopeSignal() [2/2]

TRestAxionHelioscopeSignal::TRestAxionHelioscopeSignal ( )

Default constructor.

Definition at line 88 of file TRestAxionHelioscopeSignal.cxx.

◆ ~TRestAxionHelioscopeSignal()

TRestAxionHelioscopeSignal::~TRestAxionHelioscopeSignal ( )

Default destructor.

Definition at line 116 of file TRestAxionHelioscopeSignal.cxx.

Member Function Documentation

◆ FillHistograms()

void TRestAxionHelioscopeSignal::FillHistograms ( )
overrideprotectedvirtual

It will produce a histogram with the distribution using the formula contributions.

TODO: The histogram is filled just by evaluating the formula, but it would be more realistic that we fill the histograms with a number N of entries that mimic a MC generation scheme similar to TRestComponentDataSet.

Implements TRestComponent.

Definition at line 212 of file TRestAxionHelioscopeSignal.cxx.

◆ GetFlux()

TRestAxionSolarFlux * TRestAxionHelioscopeSignal::GetFlux ( )
inline

Definition at line 75 of file TRestAxionHelioscopeSignal.h.

◆ GetGas()

TRestAxionBufferGas * TRestAxionHelioscopeSignal::GetGas ( )
inline

Definition at line 74 of file TRestAxionHelioscopeSignal.h.

◆ GetMagnetLength()

Double_t TRestAxionHelioscopeSignal::GetMagnetLength ( ) const
inline

Definition at line 87 of file TRestAxionHelioscopeSignal.h.

◆ GetMagnetRadius()

Double_t TRestAxionHelioscopeSignal::GetMagnetRadius ( ) const
inline

Definition at line 86 of file TRestAxionHelioscopeSignal.h.

◆ GetMagnetStrength()

Double_t TRestAxionHelioscopeSignal::GetMagnetStrength ( ) const
inline

Definition at line 88 of file TRestAxionHelioscopeSignal.h.

◆ GetNumberOfBores()

Int_t TRestAxionHelioscopeSignal::GetNumberOfBores ( ) const
inline

Definition at line 85 of file TRestAxionHelioscopeSignal.h.

◆ GetSignalRate() [1/2]

Double_t TRestAxionHelioscopeSignal::GetSignalRate ( Double_t  mass,
Double_t  Eo,
Double_t  Ef 
)

It returns the intensity/rate (in seconds) corresponding to the class defined helioscope configuration integrated in the energy range given by argument.

This is copy/paste from previous method. Sorry for doing this.

Definition at line 181 of file TRestAxionHelioscopeSignal.cxx.

◆ GetSignalRate() [2/2]

Double_t TRestAxionHelioscopeSignal::GetSignalRate ( std::vector< Double_t >  point,
Double_t  mass = 0 
)

It returns the intensity/rate (in seconds) corresponding to the class defined helioscope configuration evaluated at the position of the parameter space given by point, which by now is simply the energy.

The size of the point vector must have the same dimension as the dimensions of the variables of the distribution. Right now is 1-dimension.

There should be only 1-dimension. Rate is integrated to the particular bin size.

Definition at line 141 of file TRestAxionHelioscopeSignal.cxx.

◆ GetType()

std::string TRestAxionHelioscopeSignal::GetType ( ) const
inline

Definition at line 89 of file TRestAxionHelioscopeSignal.h.

◆ InitFromConfigFile()

void TRestAxionHelioscopeSignal::InitFromConfigFile ( )
overrideprotectedvirtual

It customizes the retrieval of XML data values of this class.

Reimplemented from TRestComponent.

Definition at line 292 of file TRestAxionHelioscopeSignal.cxx.

◆ Initialize()

void TRestAxionHelioscopeSignal::Initialize ( )
overridevirtual

It will initialize the data frame with the filelist and column names (or observables) that have been defined by the user.

Reimplemented from TRestComponent.

Definition at line 124 of file TRestAxionHelioscopeSignal.cxx.

◆ PrintMetadata()

void TRestAxionHelioscopeSignal::PrintMetadata ( )
overridevirtual

Prints on screen the information about the metadata members of TRestAxionSolarFlux.

Reimplemented from TRestComponent.

Definition at line 274 of file TRestAxionHelioscopeSignal.cxx.

◆ SetMagnetLength()

void TRestAxionHelioscopeSignal::SetMagnetLength ( const Double_t &  length)
inline

Definition at line 81 of file TRestAxionHelioscopeSignal.h.

◆ SetMagnetRadius()

void TRestAxionHelioscopeSignal::SetMagnetRadius ( const Double_t &  radius)
inline

Definition at line 80 of file TRestAxionHelioscopeSignal.h.

◆ SetMagnetStrength()

void TRestAxionHelioscopeSignal::SetMagnetStrength ( const Double_t &  strength)
inline

Definition at line 82 of file TRestAxionHelioscopeSignal.h.

◆ SetNumberOfBores()

void TRestAxionHelioscopeSignal::SetNumberOfBores ( const Int_t &  bores)
inline

Definition at line 79 of file TRestAxionHelioscopeSignal.h.

◆ SetType()

void TRestAxionHelioscopeSignal::SetType ( const std::string &  type)
inline

Definition at line 83 of file TRestAxionHelioscopeSignal.h.

Field Documentation

◆ fBores

Int_t TRestAxionHelioscopeSignal::fBores = 2
private

It defines the number of bores or TPCs (number of magnetic volumes)

Definition at line 39 of file TRestAxionHelioscopeSignal.h.

◆ fConversionType

std::string TRestAxionHelioscopeSignal::fConversionType = "IAXO"
private

It defines the helioscope type (IAXO/AMELIE)

Definition at line 36 of file TRestAxionHelioscopeSignal.h.

◆ fField

TRestAxionField* TRestAxionHelioscopeSignal::fField = nullptr
private

It provides access to axion-photon conversion probabilites calculations.

Definition at line 63 of file TRestAxionHelioscopeSignal.h.

◆ fFlux

TRestAxionSolarFlux* TRestAxionHelioscopeSignal::fFlux = nullptr
private

It defines the solar flux we use inside our magnetic field. Must be defined.

Definition at line 60 of file TRestAxionHelioscopeSignal.h.

◆ fGas

TRestAxionBufferGas* TRestAxionHelioscopeSignal::fGas = nullptr
private

It defines the gas mixture we use inside our magnetic field. Vacuum if it is nullptr.

Definition at line 57 of file TRestAxionHelioscopeSignal.h.

◆ fMagnetLength

Double_t TRestAxionHelioscopeSignal::fMagnetLength = 10000
private

It defines the magnet length in standard REST units (mm)

Definition at line 45 of file TRestAxionHelioscopeSignal.h.

◆ fMagnetRadius

Double_t TRestAxionHelioscopeSignal::fMagnetRadius = 350
private

It defines the magnet aperture radius in standard REST units (mm)

Definition at line 42 of file TRestAxionHelioscopeSignal.h.

◆ fMagnetStrength

Double_t TRestAxionHelioscopeSignal::fMagnetStrength = 2
private

It defines the magnetic field strength in T.

Definition at line 48 of file TRestAxionHelioscopeSignal.h.

◆ fOpticsEfficiency

Double_t TRestAxionHelioscopeSignal::fOpticsEfficiency = 1
private

If optics is present we may add an efficiency for Ngamma calculation.

Definition at line 51 of file TRestAxionHelioscopeSignal.h.

◆ fWindowEfficiency

Double_t TRestAxionHelioscopeSignal::fWindowEfficiency = 1
private

If an x-ray window is present we may add an efficiency for Ngamma calculation.

Definition at line 54 of file TRestAxionHelioscopeSignal.h.


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