GhostInputs Class Reference

#include <GhostInputs.h>

List of all members.

Public Member Functions

 ~GhostInputs ()
void FitPureDecoherence (Bool_t fitdecohere=1)
void SetSurfacePair (Int_t surfpair=0)
void SetDecoherencePower (Int_t deco_pow=-1)
void FitPureDecay (Bool_t fitdecay=1)
void FitCCDetScale (Bool_t fitcc=1)
void FitCCRockScale (Bool_t fitcc=1)
void FitNCScale (Bool_t fitnc=1)
void FitNuMuBarScale (Bool_t fitws=1)
void SetCCDetScaleSigma (Double_t ccdetsigma)
void SetCCRockScaleSigma (Double_t ccrocksigma)
void SetNCScaleSigma (Double_t ncsigma)
void SetNuMuBarScaleSigma (Double_t wssigma)
void SetMCData (Bool_t mcdata=1, Bool_t realdata=0)
void SetNumSamples (Int_t numsamples)
void SetNumDistributions (Double_t *numdis)
void SetMockDataChallenge (Bool_t mockdata=1)
void SetNumberExpts (Int_t nexpt)
void FitScalingFactors (Int_t numscales)
void SetTotalNum2DSystematics (Int_t systs)
void Set2DSystematicName (TString name)
void SetTotalNum1DSystematics (Int_t systs)
void Set1DSystematicName (TString name)
void AddDataFile (Char_t *filename, Int_t sample_label, Int_t dis_label, Int_t res_label, Char_t *hist_spectrum)
void SetParameterLimits (Double_t sin2min, Double_t sin2max, Double_t dm2min, Double_t dm2max)
void SetOverallParameterLimits (Double_t sin2min, Double_t sin2max, Double_t dm2min, Double_t dm2max)
void SetOverallNumberGridBins (Int_t n_sin2bins, Int_t n_dm2bins)
void ConfigureParallelRunning (Bool_t run_parallel=1)
void TurnOffNuisanceParameters (Int_t nuisance=0)
void SetTextOutputFilename (TString filename_text)
void SetRootOutputFilename (TString filename_root)
void MinuitFindInitialNuisanceValues (Bool_t initialvalues=1)
void InitialiseFit ()

Static Public Member Functions

static GhostInputsInstance ()

Private Member Functions

 GhostInputs ()
void InterpolateOscillatedSpectra (Double_t sin2_par, Double_t dm2_par, TH1D *hSin2Min, TH2D *hSin2Max, ArrayTH1D *pred_hist)

Private Attributes

Bool_t fFitDecoherence
Int_t fSurfacePair
Int_t fDecoPower
Bool_t fFitDecay
Bool_t fMCData
Bool_t fRealData
Bool_t fMinuitInitialValues
Int_t fNumSamples
Bool_t fMockData
Int_t fNumMockDataExpts
Bool_t fRunParallel
Bool_t fNuisanceParameters
Int_t fNum2DSysts
Int_t fNum1DSysts
Double_t fMaxEnergy
Bool_t fArrayHistsFlag
Bool_t fFitScales
Int_t fNumScalingFactors
Double_t fCCDetSigma
Double_t fCCRockSigma
Double_t fNCSigma
Double_t fNuMuBarSigma
Double_t fCCDetScale
Double_t fCCRockScale
Double_t fNCScale
Double_t fNuMuBarScale
Bool_t fFitCCDet
Bool_t fFitCCRock
Bool_t fFitNC
Bool_t fFitNuMuBar
Double_t fSin2Min
Double_t fSin2MinOverall
Double_t fSin2Max
Double_t fSin2MaxOverall
Double_t fDm2Min
Double_t fDm2MinOverall
Double_t fDm2Max
Double_t fDm2MaxOverall
Int_t fNumSin2BinsOverall
Int_t fNumDm2BinsOverall
Int_t fNumSin2Bins
Int_t fNumDm2Bins
TString fBestFitTextFilename
TString fBestFitRootFilename
Double_t * fNDis
vector< TFile * > vFile
vector< TString > f2DSystematicName
vector< TString > f1DSystematicName
vector< TString > fGlobalSystematicName
vector< vector< vector< TH1D * > > > vInputData3D
vector< vector< TH1D * > > vInputData2D
vector< TH1D * > vInputData1D
vector< vector< vector
< ArrayTH1D * > > > 
vFinalData3D
vector< vector< ArrayTH1D * > > vFinalData2D
vector< ArrayTH1D * > vFinalData1D

Friends

class GhostMerge
class GhostSample
class GhostFramework
class GhostFakeData

Detailed Description

Definition at line 25 of file GhostInputs.h.


Constructor & Destructor Documentation

GhostInputs::~GhostInputs (  ) 

Definition at line 92 of file GhostInputs.cxx.

References Msg::kInfo, MSG, size, vFinalData3D, and vInputData3D.

00093 {
00094   MSG("GhostInputs",Msg::kInfo) << " *-* GhostInputs::~GhostInputs() *-* " << endl;
00095   for(UInt_t i=0;i<vFinalData3D.size();i++){
00096     for(UInt_t res=0;res<(vFinalData3D.at(i)).size();res++){
00097       for(UInt_t j=0;j<((vFinalData3D.at(i)).at(res)).size();j++){
00098         if(((vFinalData3D.at(i)).at(res))[j]) delete ((vFinalData3D.at(i)).at(res)).at(j);
00099       }
00100     }
00101   }
00102   for(UInt_t i=0;i<vInputData3D.size();i++){
00103     for(UInt_t res=0;res<(vInputData3D.at(i)).size();res++){
00104       for(UInt_t j=0;j<((vInputData3D.at(i)).at(res)).size();j++){
00105         if(((vInputData3D.at(i)).at(res))[j]) delete ((vInputData3D.at(i)).at(res)).at(j);
00106       }
00107     }
00108   }
00109 }

GhostInputs::GhostInputs (  )  [private]

Definition at line 45 of file GhostInputs.cxx.

References vFinalData3D, and vInputData3D.

00045                          :
00046   fFitDecoherence(false),
00047   fSurfacePair(0),
00048   fDecoPower(-1),
00049   fFitDecay(false),
00050   fMCData(false),
00051   fRealData(true),
00052   fMinuitInitialValues(0),
00053   fNumSamples(1),
00054   fMockData(false),
00055   fNumMockDataExpts(1),
00056   fRunParallel(0),
00057   fNuisanceParameters(1),
00058   fNum2DSysts(0),
00059   fNum1DSysts(0),
00060   fMaxEnergy(100),
00061   fArrayHistsFlag(1),
00062   fFitScales(0),
00063   fNumScalingFactors(0),
00064   fCCDetSigma(0.4),
00065   fCCRockSigma(0.4),
00066   fNCSigma(0.5),
00067   fNuMuBarSigma(-999.9),
00068   fCCDetScale(0),
00069   fCCRockScale(0),
00070   fNCScale(0),
00071   fNuMuBarScale(0),
00072   fFitCCDet(0),
00073   fFitCCRock(0), //Detector and rock scales seperately, set as false initially
00074   fFitNC(0),
00075   fFitNuMuBar(0),
00076   fSin2Min(-999.9),
00077   fSin2MinOverall(-999.9),
00078   fSin2Max(-999.9),
00079   fSin2MaxOverall(-999.9),
00080   fDm2Min(-999.9),
00081   fDm2MinOverall(-999.9),
00082   fDm2Max(-999.9),
00083   fDm2MaxOverall(-999.9),
00084   fNumSin2BinsOverall(-999),
00085   fNumDm2BinsOverall(-999)
00086 {
00087   vInputData3D.clear();
00088   vFinalData3D.clear();
00089 
00090 }


Member Function Documentation

void GhostInputs::AddDataFile ( Char_t *  filename,
Int_t  sample_label,
Int_t  dis_label,
Int_t  res_label,
Char_t *  hist_spectrum 
) [inline]

Definition at line 64 of file GhostInputs.h.

References fRealData, vFile, and vInputData3D.

00064                                                                                                              {
00065     if(fRealData==false){cout << "Error: Real Data flag not set, exiting" << endl;return;}
00066     vFile.push_back(new TFile(filename,"read"));
00067     ((vInputData3D.at(sample_label)).at(dis_label)).push_back((TH1D*)(vFile.back())->Get(hist_spectrum)); 
00068     cout << " *-* GhostInputs::AddDataFile() File Added for Sample #" << sample_label << ", Distribution #" << dis_label << ", Resolution Bin # " <<  res_label << "*-*" << endl;
00069   }

void GhostInputs::ConfigureParallelRunning ( Bool_t  run_parallel = 1  )  [inline]

Definition at line 91 of file GhostInputs.h.

References fRunParallel.

00091                                                         {
00092     fRunParallel = run_parallel;
00093   }

void GhostInputs::FitCCDetScale ( Bool_t  fitcc = 1  )  [inline]

Definition at line 42 of file GhostInputs.h.

References fFitCCDet.

00042 { fFitCCDet = fitcc; }

void GhostInputs::FitCCRockScale ( Bool_t  fitcc = 1  )  [inline]

Definition at line 43 of file GhostInputs.h.

References fFitCCRock.

00043 { fFitCCRock = fitcc; }

void GhostInputs::FitNCScale ( Bool_t  fitnc = 1  )  [inline]

Definition at line 44 of file GhostInputs.h.

References fFitNC.

00044 { fFitNC = fitnc; }

void GhostInputs::FitNuMuBarScale ( Bool_t  fitws = 1  )  [inline]

Definition at line 45 of file GhostInputs.h.

References fFitNuMuBar.

00045 { fFitNuMuBar = fitws; }

void GhostInputs::FitPureDecay ( Bool_t  fitdecay = 1  )  [inline]

Definition at line 40 of file GhostInputs.h.

References fFitDecay, and fFitDecoherence.

00040 { fFitDecay = fitdecay; fFitDecoherence = fitdecay||fFitDecoherence; }

void GhostInputs::FitPureDecoherence ( Bool_t  fitdecohere = 1  )  [inline]

Definition at line 37 of file GhostInputs.h.

References fFitDecoherence.

00037 { fFitDecoherence = fitdecohere; }

void GhostInputs::FitScalingFactors ( Int_t  numscales  )  [inline]

Definition at line 58 of file GhostInputs.h.

References fFitScales, and fNumScalingFactors.

00058 { fFitScales = true; fNumScalingFactors = numscales; }

void GhostInputs::InitialiseFit (  ) 

Definition at line 113 of file GhostInputs.cxx.

References MuELoss::e, fDm2Max, fDm2MaxOverall, fDm2Min, fDm2MinOverall, fNDis, fNumDm2Bins, fNumDm2BinsOverall, fNumSamples, fNumSin2Bins, fNumSin2BinsOverall, fSin2Max, fSin2MaxOverall, fSin2Min, fSin2MinOverall, Msg::kInfo, MSG, vFinalData1D, vFinalData2D, vFinalData3D, vInputData1D, vInputData2D, and vInputData3D.

00114 {
00115   MSG("GhostInputs",Msg::kInfo) << " *-* GhostInputs::InitialiseFit() *-*" << endl;
00116   gStyle->SetOptStat(0);
00117 
00118   for(Int_t i=0;i<fNumSamples;i++){
00119     for(Int_t j=0;j<fNDis[i];j++){
00120       vInputData2D.push_back(vInputData1D);
00121       vFinalData2D.push_back(vFinalData1D);
00122     }
00123     vInputData3D.push_back(vInputData2D);
00124     vFinalData3D.push_back(vFinalData2D);
00125   }
00126   
00127   //Have fitting binning - read in from macro
00128   //Set number of bins in a parallel run
00129   fNumDm2Bins = (Int_t)(1e-11 + ((fDm2Max - fDm2Min)/(fDm2MaxOverall - fDm2MinOverall))*fNumDm2BinsOverall);
00130   fNumSin2Bins = (Int_t)(1e-11 + ((fSin2Max - fSin2Min)/(fSin2MaxOverall - fSin2MinOverall))*fNumSin2BinsOverall);
00131   MSG("GhostInputs",Msg::kInfo) << " *-* GhostInputs::InitialiseFit() Fitting in " << fNumDm2Bins << " Dm2 Bins *-* " << endl;
00132   MSG("GhostInputs",Msg::kInfo) << " *-* GhostInputs::InitialiseFit() Fitting in " << fNumSin2Bins << " Sin2 Bins *-* " << endl;
00133 
00134 }

GhostInputs * GhostInputs::Instance (  )  [static]

Definition at line 37 of file GhostInputs.cxx.

00038 { 
00039   if(!fGhostInputs){
00040     fGhostInputs = new GhostInputs();
00041   }
00042   return fGhostInputs;
00043 }

void GhostInputs::InterpolateOscillatedSpectra ( Double_t  sin2_par,
Double_t  dm2_par,
TH1D *  hSin2Min,
TH2D *  hSin2Max,
ArrayTH1D pred_hist 
) [private]
void GhostInputs::MinuitFindInitialNuisanceValues ( Bool_t  initialvalues = 1  )  [inline]

Definition at line 106 of file GhostInputs.h.

References fMinuitInitialValues.

00106                                                                 {
00107     fMinuitInitialValues = initialvalues;
00108   }

void GhostInputs::Set1DSystematicName ( TString  name  )  [inline]

Definition at line 62 of file GhostInputs.h.

References f1DSystematicName, and fGlobalSystematicName.

00062 { f1DSystematicName.push_back(name); fGlobalSystematicName.push_back(name); }

void GhostInputs::Set2DSystematicName ( TString  name  )  [inline]

Definition at line 60 of file GhostInputs.h.

References f2DSystematicName, and fGlobalSystematicName.

00060 { f2DSystematicName.push_back(name); fGlobalSystematicName.push_back(name); }

void GhostInputs::SetCCDetScaleSigma ( Double_t  ccdetsigma  )  [inline]

Definition at line 47 of file GhostInputs.h.

References fCCDetSigma.

00047 { fCCDetSigma = ccdetsigma; }

void GhostInputs::SetCCRockScaleSigma ( Double_t  ccrocksigma  )  [inline]

Definition at line 48 of file GhostInputs.h.

References fCCRockSigma.

00048 { fCCRockSigma = ccrocksigma; }

void GhostInputs::SetDecoherencePower ( Int_t  deco_pow = -1  )  [inline]

Definition at line 39 of file GhostInputs.h.

References fDecoPower.

00039 { fDecoPower = deco_pow; }

void GhostInputs::SetMCData ( Bool_t  mcdata = 1,
Bool_t  realdata = 0 
) [inline]

Definition at line 52 of file GhostInputs.h.

References fMCData, and fRealData.

00052 { fMCData = mcdata; fRealData = realdata; cout << " *-* MC Data Flag Set *-*" << endl;}

void GhostInputs::SetMockDataChallenge ( Bool_t  mockdata = 1  )  [inline]

Definition at line 56 of file GhostInputs.h.

References fMockData.

00056 { fMockData = mockdata; cout << " *-* Mock Data Challenge Flag Set *-*" << endl; }

void GhostInputs::SetNCScaleSigma ( Double_t  ncsigma  )  [inline]

Definition at line 49 of file GhostInputs.h.

References fNCSigma.

00049 { fNCSigma = ncsigma; }

void GhostInputs::SetNumberExpts ( Int_t  nexpt  )  [inline]

Definition at line 57 of file GhostInputs.h.

References fNumMockDataExpts.

00057 { fNumMockDataExpts = nexpt; cout << "Running " << fNumMockDataExpts << " Mock Data Experiments" << endl; }

void GhostInputs::SetNumDistributions ( Double_t *  numdis  )  [inline]

Definition at line 55 of file GhostInputs.h.

References fNDis.

00055 { fNDis = numdis; }

void GhostInputs::SetNumSamples ( Int_t  numsamples  )  [inline]

Definition at line 54 of file GhostInputs.h.

References fNumSamples.

00054 { fNumSamples = numsamples; }

void GhostInputs::SetNuMuBarScaleSigma ( Double_t  wssigma  )  [inline]

Definition at line 50 of file GhostInputs.h.

References fNuMuBarSigma.

00050 { fNuMuBarSigma = wssigma; }

void GhostInputs::SetOverallNumberGridBins ( Int_t  n_sin2bins,
Int_t  n_dm2bins 
) [inline]

Definition at line 86 of file GhostInputs.h.

References fNumDm2BinsOverall, and fNumSin2BinsOverall.

00086                                                                  {
00087     fNumSin2BinsOverall = n_sin2bins;
00088     fNumDm2BinsOverall = n_dm2bins;
00089   }

void GhostInputs::SetOverallParameterLimits ( Double_t  sin2min,
Double_t  sin2max,
Double_t  dm2min,
Double_t  dm2max 
) [inline]

Definition at line 79 of file GhostInputs.h.

References fDm2MaxOverall, fDm2MinOverall, fSin2MaxOverall, and fSin2MinOverall.

00079                                                                                                    {
00080     fSin2MinOverall = sin2min;
00081     fSin2MaxOverall = sin2max;
00082     fDm2MinOverall = dm2min;
00083     fDm2MaxOverall = dm2max;  
00084   }

void GhostInputs::SetParameterLimits ( Double_t  sin2min,
Double_t  sin2max,
Double_t  dm2min,
Double_t  dm2max 
) [inline]

Definition at line 71 of file GhostInputs.h.

References fDm2Max, fDm2MaxOverall, fDm2Min, fDm2MinOverall, fSin2Max, fSin2MaxOverall, fSin2Min, and fSin2MinOverall.

00071                                                                                             {
00072     //Default "overall" values for gridsearch to these entries
00073     fSin2Min = sin2min; fSin2MinOverall = sin2min;
00074     fSin2Max = sin2max; fSin2MaxOverall = sin2max;
00075     fDm2Min = dm2min;   fDm2MinOverall = dm2min;
00076     fDm2Max = dm2max;   fDm2MaxOverall = dm2max;
00077   }    

void GhostInputs::SetRootOutputFilename ( TString  filename_root  )  [inline]

Definition at line 103 of file GhostInputs.h.

References fBestFitRootFilename.

00103                                                    {
00104     fBestFitRootFilename = filename_root;
00105   }

void GhostInputs::SetSurfacePair ( Int_t  surfpair = 0  )  [inline]

Definition at line 38 of file GhostInputs.h.

References fSurfacePair.

00038 { fSurfacePair = surfpair; }

void GhostInputs::SetTextOutputFilename ( TString  filename_text  )  [inline]

Definition at line 99 of file GhostInputs.h.

References fBestFitTextFilename.

00099                                                    {
00100     fBestFitTextFilename = filename_text;
00101   }

void GhostInputs::SetTotalNum1DSystematics ( Int_t  systs  )  [inline]

Definition at line 61 of file GhostInputs.h.

References fNum1DSysts.

00061 { fNum1DSysts = systs; }

void GhostInputs::SetTotalNum2DSystematics ( Int_t  systs  )  [inline]

Definition at line 59 of file GhostInputs.h.

References fNum2DSysts.

00059 { fNum2DSysts = systs; }

void GhostInputs::TurnOffNuisanceParameters ( Int_t  nuisance = 0  )  [inline]

Definition at line 95 of file GhostInputs.h.

References fNuisanceParameters.

00095                                                     {
00096     fNuisanceParameters = nuisance;
00097   }


Friends And Related Function Documentation

friend class GhostFakeData [friend]

Definition at line 30 of file GhostInputs.h.

friend class GhostFramework [friend]

Definition at line 29 of file GhostInputs.h.

friend class GhostMerge [friend]

Definition at line 27 of file GhostInputs.h.

friend class GhostSample [friend]

Definition at line 28 of file GhostInputs.h.


Member Data Documentation

Bool_t GhostInputs::fArrayHistsFlag [private]

Definition at line 134 of file GhostInputs.h.

Referenced by GhostSample::GhostSample().

Double_t GhostInputs::fCCDetScale [private]

Definition at line 144 of file GhostInputs.h.

Referenced by GhostFramework::GhostFramework().

Double_t GhostInputs::fCCDetSigma [private]
Double_t GhostInputs::fCCRockScale [private]

Definition at line 145 of file GhostInputs.h.

Referenced by GhostFramework::GhostFramework().

Double_t GhostInputs::fCCRockSigma [private]
Int_t GhostInputs::fDecoPower [private]
Double_t GhostInputs::fDm2Max [private]
Double_t GhostInputs::fDm2MaxOverall [private]
Double_t GhostInputs::fDm2Min [private]
Double_t GhostInputs::fDm2MinOverall [private]
Bool_t GhostInputs::fFitCCDet [private]
Bool_t GhostInputs::fFitCCRock [private]
Bool_t GhostInputs::fFitDecay [private]
Bool_t GhostInputs::fFitDecoherence [private]
Bool_t GhostInputs::fFitNC [private]

Definition at line 151 of file GhostInputs.h.

Referenced by FitNCScale(), GhostFramework::GhostFramework(), and GhostMerge::RunMerge().

Bool_t GhostInputs::fFitNuMuBar [private]
Bool_t GhostInputs::fFitScales [private]

Definition at line 135 of file GhostInputs.h.

Referenced by FitScalingFactors(), and GhostFramework::GhostFramework().

Double_t GhostInputs::fMaxEnergy [private]

Definition at line 133 of file GhostInputs.h.

Bool_t GhostInputs::fMCData [private]

Definition at line 123 of file GhostInputs.h.

Referenced by GhostFramework::RunFit(), and SetMCData().

Bool_t GhostInputs::fMockData [private]

Definition at line 127 of file GhostInputs.h.

Referenced by SetMockDataChallenge().

Double_t GhostInputs::fNCScale [private]

Definition at line 146 of file GhostInputs.h.

Referenced by GhostFramework::GhostFramework().

Double_t GhostInputs::fNCSigma [private]
Double_t* GhostInputs::fNDis [private]

Definition at line 172 of file GhostInputs.h.

Referenced by InitialiseFit(), and SetNumDistributions().

Definition at line 130 of file GhostInputs.h.

Referenced by GhostFramework::GhostFramework(), and TurnOffNuisanceParameters().

Int_t GhostInputs::fNum1DSysts [private]
Int_t GhostInputs::fNum2DSysts [private]
Int_t GhostInputs::fNumDm2Bins [private]

Definition at line 167 of file GhostInputs.h.

Referenced by GhostFramework::GhostFramework(), and InitialiseFit().

Int_t GhostInputs::fNumSamples [private]

Definition at line 136 of file GhostInputs.h.

Referenced by FitScalingFactors(), and GhostFramework::GhostFramework().

Int_t GhostInputs::fNumSin2Bins [private]

Definition at line 166 of file GhostInputs.h.

Referenced by GhostFramework::GhostFramework(), and InitialiseFit().

Double_t GhostInputs::fNuMuBarScale [private]

Definition at line 147 of file GhostInputs.h.

Referenced by GhostFramework::GhostFramework().

Double_t GhostInputs::fNuMuBarSigma [private]

Definition at line 142 of file GhostInputs.h.

Referenced by GhostMerge::RunMerge(), and SetNuMuBarScaleSigma().

Bool_t GhostInputs::fRealData [private]
Bool_t GhostInputs::fRunParallel [private]

Definition at line 129 of file GhostInputs.h.

Referenced by ConfigureParallelRunning(), and GhostFramework::GhostFramework().

Double_t GhostInputs::fSin2Max [private]
Double_t GhostInputs::fSin2MaxOverall [private]
Double_t GhostInputs::fSin2Min [private]
Double_t GhostInputs::fSin2MinOverall [private]
Int_t GhostInputs::fSurfacePair [private]

Definition at line 120 of file GhostInputs.h.

Referenced by GhostFramework::GhostFramework(), and SetSurfacePair().

vector<TFile*> GhostInputs::vFile [private]

Definition at line 174 of file GhostInputs.h.

Referenced by AddDataFile().

Definition at line 185 of file GhostInputs.h.

Referenced by InitialiseFit().

Definition at line 184 of file GhostInputs.h.

Referenced by InitialiseFit().

Definition at line 182 of file GhostInputs.h.

Referenced by InitialiseFit().

Definition at line 181 of file GhostInputs.h.

Referenced by InitialiseFit().


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

Generated on 2 Nov 2017 for loon by  doxygen 1.6.1