![]() |
GRSISort "v4.0.0.5"
An extension of the ROOT analysis Framework
|
![]() |
This class provides the number of angles, their values, and the index a specific angle is at, as well as how many combinations contribute to this angle. It is meant to be used for the angular correlation analysis.
Definition at line 26 of file TGriffinAngles.h.
Public Member Functions | |
TGriffinAngles (const TGriffinAngles &)=default | |
TGriffinAngles (double distance=145., bool folding=false, bool grouping=false, bool addback=true) | |
TGriffinAngles (TGriffinAngles &&) noexcept=default | |
~TGriffinAngles ()=default | |
bool | Addback () const |
double | Angle (int index) const |
double | AverageAngle (int index) const |
std::set< double >::iterator | begin () const |
int | Count (double angle) |
double | Distance () const |
std::set< double >::iterator | end () const |
bool | ExcludeCrystal (int detector, int crystal) const |
bool | ExcludeDetector (int detector) const |
bool | Folding () const |
void | FoldOrGroup (TGraphErrors *z0, TGraphErrors *z2, TGraphErrors *z4, bool verbose=false) const |
bool | Grouping () const |
int | Index (double angle) |
int | NumberOfAngles () const |
TGriffinAngles & | operator= (const TGriffinAngles &)=default |
TGriffinAngles & | operator= (TGriffinAngles &&) noexcept=default |
void | Print (Option_t *="") const override |
Static Public Member Functions | |
static double | Rounding () |
static void | Rounding (const double &val) |
Private Attributes | |
bool | fAddback {true} |
std::map< int, int > | fAngleCount |
std::map< double, int > | fAngleMap |
std::set< double > | fAngles |
std::vector< int > | fCustomGrouping |
double | fDistance {145.} |
std::vector< int > | fExcludedCrystals |
std::vector< int > | fExcludedDetectors |
bool | fFolding {false} |
bool | fGrouping {false} |
Static Private Attributes | |
static double | fRounding = 0.001 |
|
explicit |
Definition at line 7 of file TGriffinAngles.cxx.
References DRED, end(), ExcludeCrystal(), ExcludeDetector(), fAddback, fAngleCount, fAngleMap, fAngles, fCustomGrouping, fDistance, fExcludedCrystals, fExcludedDetectors, fFolding, fGrouping, fRounding, TGRSIOptions::Get(), TGriffin::GetPosition(), RESET_COLOR, and TGRSIOptions::UserSettings().
|
default |
|
defaultnoexcept |
|
default |
|
inline |
Definition at line 38 of file TGriffinAngles.h.
References fAddback.
|
inline |
Definition at line 42 of file TGriffinAngles.h.
References fAngles.
double TGriffinAngles::AverageAngle | ( | int | index | ) | const |
|
inline |
Definition at line 57 of file TGriffinAngles.h.
References fAngles.
Referenced by AngularCorrelationHelper::CreateHistograms().
|
inline |
If the angle is in our map, report how often it exists, otherwise return zero.
Definition at line 49 of file TGriffinAngles.h.
References fAngleCount, and fRounding.
|
inline |
Definition at line 35 of file TGriffinAngles.h.
References fDistance.
|
inline |
Definition at line 58 of file TGriffinAngles.h.
References fAngles.
Referenced by TGriffinAngles(), and AngularCorrelationHelper::CreateHistograms().
bool TGriffinAngles::ExcludeCrystal | ( | int | detector, |
int | crystal ) const |
Returns true if any of the crystals in fExcludedCrystals matches the given detector and crystal (using 4*(detector-1)+crystal+1).
Definition at line 380 of file TGriffinAngles.cxx.
References fExcludedCrystals.
Referenced by TGriffinAngles().
bool TGriffinAngles::ExcludeDetector | ( | int | detector | ) | const |
Returns true if any of the detectors in fExcludedDetectors matches the given detector.
Definition at line 374 of file TGriffinAngles.cxx.
References fExcludedDetectors.
Referenced by TGriffinAngles().
|
inline |
Definition at line 36 of file TGriffinAngles.h.
References fFolding.
void TGriffinAngles::FoldOrGroup | ( | TGraphErrors * | z0, |
TGraphErrors * | z2, | ||
TGraphErrors * | z4, | ||
bool | verbose = false ) const |
Apply folding and/or grouping to the theory graphs. This assumes that the theory graphs all have the exact same length of 49 or 51 for singles or addback, respectively.
Definition at line 169 of file TGriffinAngles.cxx.
|
inline |
Definition at line 37 of file TGriffinAngles.h.
References fGrouping.
int TGriffinAngles::Index | ( | double | angle | ) |
Definition at line 140 of file TGriffinAngles.cxx.
References fAngleMap, fAngles, and fRounding.
Referenced by AngularCorrelationHelper::Exec().
|
inline |
Definition at line 41 of file TGriffinAngles.h.
References fAngles.
|
default |
|
defaultnoexcept |
|
override |
Definition at line 386 of file TGriffinAngles.cxx.
References AverageAngle(), fAngleCount, fAngleMap, fAngles, and fRounding.
Referenced by AngularCorrelationHelper::AngularCorrelationHelper().
|
inlinestatic |
Definition at line 65 of file TGriffinAngles.h.
References fRounding.
|
inlinestatic |
Definition at line 66 of file TGriffinAngles.h.
References fRounding.
|
private |
flag indicating whether we use addback
Definition at line 72 of file TGriffinAngles.h.
Referenced by TGriffinAngles(), and Addback().
|
private |
Maps angles (divided by rounding and cast to integers) to number of combinations contributing to it.
Definition at line 79 of file TGriffinAngles.h.
Referenced by TGriffinAngles(), Count(), and Print().
|
private |
Maps angles to indices. This is fairly straight forward without grouping, but if grouping is used multiple angles can be mapped to the same index.
Definition at line 78 of file TGriffinAngles.h.
Referenced by TGriffinAngles(), AverageAngle(), Index(), and Print().
|
private |
set of unique angles, when grouping is used, the largest angle of the group is used!
Definition at line 77 of file TGriffinAngles.h.
Referenced by TGriffinAngles(), Angle(), begin(), end(), Index(), NumberOfAngles(), and Print().
|
private |
list of custom groups
Definition at line 76 of file TGriffinAngles.h.
Referenced by TGriffinAngles().
|
private |
distance of detector from center of array in mmm
Definition at line 69 of file TGriffinAngles.h.
Referenced by TGriffinAngles(), and Distance().
|
private |
list of crystals that are excluded in calculating the angles, the crystals are numbered as 4*(det-1)+cry, so start at 0 and go up to 63
Definition at line 75 of file TGriffinAngles.h.
Referenced by TGriffinAngles(), and ExcludeCrystal().
|
private |
list of detectors that are excluded in calculating the angles
Definition at line 74 of file TGriffinAngles.h.
Referenced by TGriffinAngles(), and ExcludeDetector().
|
private |
flag indicating whether we fold our distribution around 90 degree
Definition at line 70 of file TGriffinAngles.h.
Referenced by TGriffinAngles(), Folding(), and FoldOrGroup().
|
private |
flag indicating whether we group close angles together
Definition at line 71 of file TGriffinAngles.h.
Referenced by TGriffinAngles(), FoldOrGroup(), and Grouping().
|
staticprivate |
we consider any angles whose difference is less than this to be equal
Definition at line 73 of file TGriffinAngles.h.
Referenced by TGriffinAngles(), Count(), FoldOrGroup(), Index(), Print(), Rounding(), and Rounding().