1#ifndef __MINIBALLANGLEFITTER_HH
2#define __MINIBALLANGLEFITTER_HH
16#include "TMultiGraph.h"
17#include "TGraphErrors.h"
22#include "Math/Functor.h"
23#include "Math/Factory.h"
24#include "Math/Minimizer.h"
25#include "Math/MinimizerOptions.h"
45 MiniballAngleFunction( std::shared_ptr<MiniballSettings> _myset, std::shared_ptr<MiniballReaction> _myreact );
51 bool FitPeak( TH1D *h,
double &en,
double &er );
62 inline bool IsPresent(
unsigned int clu,
unsigned int cry,
unsigned int seg ){
74 inline double GetExpEnergy(
unsigned int clu,
unsigned int cry,
unsigned int seg ){
75 return energy[clu][cry][seg];
77 inline double GetExpError(
unsigned int clu,
unsigned int cry,
unsigned int seg ){
78 return err[clu][cry][seg];
82 inline double GetExpPhi(
unsigned int clu,
unsigned int cry,
unsigned int seg ){
83 return phic[clu][cry][seg];
85 inline double GetExpPhiError(
unsigned int clu,
unsigned int cry,
unsigned int seg ){
86 return phie[clu][cry][seg];
95 std::vector<std::vector<std::vector<bool>>>
present;
96 std::vector<std::vector<std::vector<bool>>>
phiconst;
97 std::vector<std::vector<std::vector<double>>>
energy;
98 std::vector<std::vector<std::vector<double>>>
err;
99 std::vector<std::vector<std::vector<double>>>
phic;
100 std::vector<std::vector<std::vector<double>>>
phie;
104 std::shared_ptr<MiniballSettings>
myset;
120 MiniballAngleFitter( std::shared_ptr<MiniballSettings> _myset, std::shared_ptr<MiniballReaction> _myreact );
153 std::shared_ptr<MiniballSettings>
myset;
178 std::vector<double>
LL;
179 std::vector<double>
UL;
std::vector< int > mystyles
void SetOutputDirectory(std::string dir)
void SaveExpEnergies(std::string energy_file)
std::vector< double > pars
std::string input_data_filename
std::vector< std::string > names
std::vector< int > mycolors
std::shared_ptr< MiniballSettings > myset
bool SetInputEnergiesFile(std::string fname)
bool SetInputROOTFile(std::string fname)
std::shared_ptr< MiniballReaction > myreact
void SaveReactionFile(std::string fname)
void SaveExpEnergies(std::string energy_file)
void LoadExpEnergies(std::string energy_file)
std::vector< bool > cluster
bool IsPresent(unsigned int clu)
std::vector< std::vector< std::vector< double > > > energy
std::shared_ptr< MiniballSettings > myset
bool HasPhiConstraint(unsigned int clu, unsigned int cry, unsigned int seg)
void SetReferenceEnergy(double e)
bool IsPresent(unsigned int clu, unsigned int cry, unsigned int seg)
std::vector< std::vector< std::vector< double > > > phic
std::vector< std::vector< std::vector< bool > > > phiconst
double GetExpError(unsigned int clu, unsigned int cry, unsigned int seg)
std::vector< std::vector< std::vector< bool > > > present
bool FitPeak(TH1D *h, double &en, double &er)
void FitSegmentEnergies(TFile *infile)
double GetExpPhi(unsigned int clu, unsigned int cry, unsigned int seg)
double GetReferenceEnergy()
std::shared_ptr< MiniballReaction > myreact
std::vector< std::vector< std::vector< double > > > phie
double GetExpEnergy(unsigned int clu, unsigned int cry, unsigned int seg)
std::vector< std::vector< std::vector< double > > > err
double operator()(const double *p)
double GetExpPhiError(unsigned int clu, unsigned int cry, unsigned int seg)