FarOverNearFitPQ Class Reference

#include <FarOverNearFitPQ.h>

Inheritance diagram for FarOverNearFitPQ:
NuMMRun

List of all members.

Public Types

enum  whichPred { CC, NC }
enum  whichDet { ND, FD }

Public Member Functions

 FarOverNearFitPQ ()
virtual ~FarOverNearFitPQ ()
void SetNDMC (TFile *MC_file, TFile *Nue_file, TFile *NuTau_file)
void SetDataFromTFile (TFile *NDData_file, TFile *FDData_file)
void SetNDBaseline (double baseline)
void SetFDMC (TFile *MC_file, TFile *Nue_file, TFile *NuTau_file)
void SetFDBaseline (double baseline)
void SetMatrices (TFile *Data_file)
void SetPOT (double POT_)
void Initalise ()
virtual Double_t ComparePredWithData (const NuMMParameters &pars)
virtual std::vector< TH1D > WriteFDPredHistos (const NuMMParameters &pars) const
void LoadHelpers ()
void LoadMatrices ()
std::vector< Double_t > LogBins (int nbins, double xlo, double xhi)
Double_t NDNormPenaltyTerm (whichPred Pred)
Double_t GetTotalChi2_CC ()
Double_t GetTotalChi2_NC ()
void CalculateNDIntegrals ()
void MakeFlucuatedRatios (const NuMMParameters &parameters)
NuMMParameters CreateThreeFlavPars (NuMMParameters pars, bool upper, bool nh)
NuMMParameters CreatePars (NuMMParameters pars, bool upper, bool nh)
void CreateFakeHighStatsData (const NuMMParameters &parameters)
NuMMParameters DoFit (NuSystFitter *fitter, NuMMParameters pars)
void PerformInitialThreeFlavourFit (NuSystFitter *fitter, NuMMParameters pars)
void FitTheta34Only (NuSystFitter *fitter, NuMMParameters pars)
Double_t PenaltyTermDm232 (Double_t dm232)
Double_t ChiSqFunction (TH1D *rPred, TH1D *rData, TMatrixD *CoVarInvert)
void ProfileMassHierarchy ()
void UseDm241 (bool YesorNo)

Public Attributes

SterileSpecSpectrumClass
std::vector< NuMMParametersvfitPars_three
std::vector< NuMMParametersvfitPars_th34onlyfit
TMatrixD * CoVarCCinvert
TMatrixD * CoVarNCinvert
TMatrixD * CoVarCC
TMatrixD * CoVarNC
TH1F * ND_MC_POT
TH1F * ND_Nue_POT
TH1F * ND_NuTau_POT
TH1F * ND_data_POT
TH1F * FD_MC_POT
TH1F * FD_Nue_POT
TH1F * FD_NuTau_POT
TH2D * NDNC_TrueNC
TH2D * NDNC_NuMu
TH2D * NDNC_BeamNue
TH2D * NDNC_AppNue
TH2D * NDNC_AppNuTau
TH2D * NDCC_TrueNC
TH2D * NDCC_NuMu
TH2D * NDCC_BeamNue
TH2D * NDCC_AppNue
TH2D * NDCC_AppNuTau
TH2D * FDNC_TrueNC
TH2D * FDNC_NuMu
TH2D * FDNC_BeamNue
TH2D * FDNC_AppNue
TH2D * FDNC_AppNuTau
TH2D * FDCC_TrueNC
TH2D * FDCC_NuMu
TH2D * FDCC_BeamNue
TH2D * FDCC_AppNue
TH2D * FDCC_AppNuTau
TH1D * FD_dataNC
TH1D * FD_dataCC
TH1D * ND_dataNC
TH1D * ND_dataCC
TH1D * FDfakeNC
TH1D * FDfakeCC
TH1D * NDfakeNC
TH1D * NDfakeCC
TH1D * FDOscCC_MC
TH1D * NDOscCC_MC
TH1D * FDOscNC_MC
TH1D * NDOscNC_MC
TH1D * RdataCC
TH1D * RdataNC
TH1D * RpredCC
TH1D * RpredNC
TH1D * RflucCC
TH1D * RflucNC
TH1D * RfakeCC
TH1D * RfakeNC
Double_t ND_baseline
Double_t FD_baseline
Double_t totalChi2
Double_t totalChi2_NC
Double_t totalChi2_CC
bool use41
bool got_helpers
bool got_matrices

Private Member Functions

 ClassDef (FarOverNearFitPQ, 0)

Private Attributes

TFile * ND_MC
TFile * ND_Nue
TFile * ND_NuTau
TFile * ND_data
TFile * FD_MC
TFile * FD_Nue
TFile * FD_NuTau
TFile * FD_data
TFile * matrix
Double_t POT
Double_t TotalNDCC
Double_t TotalNDNC
bool init
bool DatafromTFile
bool got_NDint
bool ProfileMH
bool Do3FlavFit
bool Doth34onlyFit

Detailed Description

Definition at line 20 of file FarOverNearFitPQ.h.


Member Enumeration Documentation

Enumerator:
ND 
FD 

Definition at line 24 of file FarOverNearFitPQ.h.

00024 {ND, FD};

Enumerator:
CC 
NC 

Definition at line 23 of file FarOverNearFitPQ.h.

00023 {CC, NC};


Constructor & Destructor Documentation

FarOverNearFitPQ::FarOverNearFitPQ (  ) 

Definition at line 26 of file FarOverNearFitPQ.cxx.

References init(), and Munits::km.

00026                                   :ND_MC(0), ND_Nue(0), ND_NuTau(0), ND_data(0),
00027                                  FD_MC(0), FD_Nue(0), FD_NuTau(0), FD_data(0),
00028                                  POT(0.0)
00029 {
00030   ND_baseline = 0.00*Munits::km;
00031   FD_baseline = 0.00*Munits::km;
00032 
00033   got_helpers   = false;
00034   got_matrices  = false;
00035   init          = false;
00036   DatafromTFile = false;
00037   got_NDint     = false;
00038   ProfileMH     = false;
00039   use41         = false;
00040 
00041   Do3FlavFit = false;
00042   Doth34onlyFit = false;
00043 
00044   SpectrumClass = new SterileSpec();
00045 }

FarOverNearFitPQ::~FarOverNearFitPQ (  )  [virtual]

Definition at line 48 of file FarOverNearFitPQ.cxx.

00049 {
00050 
00051 }


Member Function Documentation

void FarOverNearFitPQ::CalculateNDIntegrals (  ) 

Definition at line 243 of file FarOverNearFitPQ.cxx.

References SterileSpec::CC, SterileSpec::CreateTotalSpectrum(), NuMMParameters::Dm2(), NuMMParameters::Dm221(), got_NDint, SterileSpec::NC, SterileSpec::ND, SpectrumClass, NuMMParameters::Theta12(), NuMMParameters::Theta13(), NuMMParameters::Theta23(), TotalNDCC, and TotalNDNC.

Referenced by NDNormPenaltyTerm().

00244 {
00245   if(got_NDint) return;
00246 
00247   // This function will save two numbers the CC and NC ND Integrals from 0 - 40 Gev    
00248   // Firt create a NuMMPars which is zero oscills for the ND
00249   NuMMParameters pars0;
00250   pars0.Dm2(0.0);     pars0.Dm221(0.0); 
00251   pars0.Theta23(0.0); pars0.Theta13(0.0); 
00252   pars0.Theta12(0.0); 
00253 
00254   TH1D* NDCCUnosc = SpectrumClass->CreateTotalSpectrum(pars0, SterileSpec::CC, SterileSpec::ND);
00255   TH1D* NDNCUnosc = SpectrumClass->CreateTotalSpectrum(pars0, SterileSpec::NC, SterileSpec::ND);
00256 
00257   // I need to find the bin index for 40 gev for intergal
00258   TotalNDCC = NDCCUnosc->Integral(1, NDCCUnosc->FindFixBin(40) );
00259   TotalNDNC = NDNCUnosc->Integral(1, NDNCUnosc->FindFixBin(40) );
00260 
00261   //std::cout << "NDCC UnOscillated Int = " << TotalNDCC << std::endl;
00262   //std::cout << "NDNC UnOscillated Int = " << TotalNDNC << std::endl;
00263 
00264   got_NDint = true;
00265 }

Double_t FarOverNearFitPQ::ChiSqFunction ( TH1D *  rPred,
TH1D *  rData,
TMatrixD *  CoVarInvert 
)

Definition at line 837 of file FarOverNearFitPQ.cxx.

Referenced by ComparePredWithData().

00838 {
00839   if(!(rPred->GetNbinsX() == rData->GetNbinsX())){ 
00840     std::cout << "Incorrect Binning agreement. Asserting" << std::endl;
00841     assert(false);
00842   }
00843 
00844   Int_t NumberOfBins = rPred->GetNbinsX() - 1; // miss out the last bin as its 40Gev+
00845 
00846   // This will be my diff between data and MC
00847   TVectorD Difference(NumberOfBins);
00848 
00849   // Fill the vector up
00850   for(Int_t i=1; i<=NumberOfBins; ++i){
00851     Difference(i-1) = (rData->GetBinContent(i) - rPred->GetBinContent(i));
00852   }
00853 
00854   TVectorD temp = Difference;
00855   temp *= (*CoVarInvert);
00856 
00857   Double_t TotalChiSq = temp*Difference;
00858 
00859   return TotalChiSq;
00860 
00861 }

FarOverNearFitPQ::ClassDef ( FarOverNearFitPQ  ,
 
) [private]
Double_t FarOverNearFitPQ::ComparePredWithData ( const NuMMParameters pars  )  [virtual]

Implements NuMMRun.

Definition at line 350 of file FarOverNearFitPQ.cxx.

References SterileSpec::CC, CC, ChiSqFunction(), CoVarCCinvert, CoVarNCinvert, SterileSpec::CreateTotalSpectrum(), NuMMParameters::Dm2(), SterileSpec::FD, FDOscCC_MC, FDOscNC_MC, Initalise(), NC, SterileSpec::NC, SterileSpec::ND, NDNormPenaltyTerm(), NDOscCC_MC, NDOscNC_MC, PenaltyTermDm232(), RdataCC, RdataNC, RpredCC, RpredNC, SpectrumClass, totalChi2, totalChi2_CC, and totalChi2_NC.

Referenced by DoFit(), FitTheta34Only(), and PerformInitialThreeFlavourFit().

00351 {
00352   Initalise();
00353   
00354   //pars.PrintStatus();
00355 
00356   // I need to oscillate my MC
00357   FDOscCC_MC = SpectrumClass->CreateTotalSpectrum(pars, SterileSpec::CC, SterileSpec::FD);
00358   FDOscNC_MC = SpectrumClass->CreateTotalSpectrum(pars, SterileSpec::NC, SterileSpec::FD);
00359   NDOscCC_MC = SpectrumClass->CreateTotalSpectrum(pars, SterileSpec::CC, SterileSpec::ND);
00360   NDOscNC_MC = SpectrumClass->CreateTotalSpectrum(pars, SterileSpec::NC, SterileSpec::ND);
00361 
00362   // Now i create the Ratios
00363   RpredCC = (TH1D*)FDOscCC_MC->Clone();
00364   RpredCC->Divide(NDOscCC_MC);
00365 
00366   RpredNC = (TH1D*)FDOscNC_MC->Clone();
00367   RpredNC->Divide(NDOscNC_MC);
00368 
00369   Double_t NormCCpen = 0.0;
00370   Double_t NormNCpen = 0.0;
00371 
00372   Double_t chisqCC = 0.0;
00373   Double_t chisqNC = 0.0;
00374   Double_t Penalty = 0.0;
00375 
00376   chisqCC = ChiSqFunction(RpredCC, RdataCC, CoVarCCinvert);
00377   chisqNC = ChiSqFunction(RpredNC, RdataNC, CoVarNCinvert);
00378 
00379   // Penalty Terms
00380   NormNCpen = NDNormPenaltyTerm(NC);
00381   NormCCpen = NDNormPenaltyTerm(CC);
00382   Penalty   = PenaltyTermDm232(pars.Dm2());
00383 
00384   // CC and NC parts
00385   totalChi2_CC = chisqCC + NormCCpen;
00386   totalChi2_NC = chisqNC + NormNCpen;
00387 
00388   totalChi2 = totalChi2_CC + Penalty;//+ totalChi2_NC;
00389 
00390   /*std::cout << " " << std::endl;
00391   std::cout << "NC chi sq    = " << chisqNC << std::endl;
00392   std::cout << "NC pen term  = " << NormNCpen << std::endl;
00393   std::cout << "CC chi sq    = " << chisqCC << std::endl;
00394   std::cout << "CC pen term  = " << NormCCpen << std::endl;
00395   std::cout << "Penalty Term = " << Penalty << std::endl;
00396   std::cout << "Total CC     = " << chisqCC + NormCCpen << std::endl;
00397   std::cout << "Total NC     = " << chisqNC + NormNCpen << std::endl;
00398   std::cout << "Total Chi2   = " << chisqCC + NormCCpen + chisqNC + NormNCpen + Penalty << std::endl;
00399   */
00400 
00401   return totalChi2;
00402 }

void FarOverNearFitPQ::CreateFakeHighStatsData ( const NuMMParameters parameters  ) 
NuMMParameters FarOverNearFitPQ::CreatePars ( NuMMParameters  pars,
bool  upper,
bool  nh 
)

Definition at line 433 of file FarOverNearFitPQ.cxx.

References NuMMParameters::Dm2(), and NuMMParameters::Theta23().

Referenced by CreateThreeFlavPars(), DoFit(), and FitTheta34Only().

00434 {
00435   // This will change the MH and octatns but keep evrything else the same.
00436   // Good for looping thurgh the 4 options.
00437   NuMMParameters parsnew = pars;
00438 
00439   // Make sure we are in the right hierarchy
00440   if ( nh == true ){
00441     if ( pars.Dm2() >= 0 )  parsnew.Dm2( pars.Dm2() );
00442     else parsnew.Dm2( pars.Dm2() * (-1) );
00443   }
00444   if ( nh == false ){
00445     if ( pars.Dm2() >= 0 )  parsnew.Dm2( pars.Dm2() * (-1) );
00446     else parsnew.Dm2( pars.Dm2() );
00447   }
00448 
00449   // Ensure theta23 is in the right octant, if not.. change it
00450   if (upper == true) {
00451     if ( pars.Theta23() <= TMath::Pi()/4 ){
00452       parsnew.Theta23( 0.89816 );
00453     }
00454   }
00455   else if (upper == false){
00456     if ( pars.Theta23() > TMath::Pi()/4 ){
00457       parsnew.Theta23(0.681);
00458     }
00459   }
00460 
00461   return parsnew;
00462 }

NuMMParameters FarOverNearFitPQ::CreateThreeFlavPars ( NuMMParameters  pars,
bool  upper,
bool  nh 
)

Definition at line 414 of file FarOverNearFitPQ.cxx.

References CreatePars(), NuMMParameters::FixAllParameters(), NuMMParameters::FixCCSystematics(), NuMMParameters::FixNCSystematics(), NuMMParameters::ReleaseDm2(), and NuMMParameters::ReleaseTheta23().

Referenced by PerformInitialThreeFlavourFit().

00415 {
00416   // This function just takes the users pars but fixes everything except Dm232 and th23                                                      
00417   // By making another pars i dont have to know what is already fixed/free  
00418 
00419   NuMMParameters pars3 = CreatePars(pars, upper, nh);
00420   
00421   // Fix everything
00422   pars3.FixAllParameters();
00423   pars3.FixCCSystematics();
00424   pars3.FixNCSystematics();
00425 
00426   // Now release what i want
00427   pars3.ReleaseDm2();
00428   pars3.ReleaseTheta23();
00429   
00430   return pars3;
00431 }

NuMMParameters FarOverNearFitPQ::DoFit ( NuSystFitter fitter,
NuMMParameters  pars 
)

Definition at line 722 of file FarOverNearFitPQ.cxx.

References ComparePredWithData(), NuMMParameters::ConstrainDelta1(), NuMMParameters::ConstrainDelta2(), NuMMParameters::ConstrainDelta3(), NuMMParameters::ConstrainTheta23(), NuMMParameters::ConstrainTheta24(), NuMMParameters::ConstrainTheta34(), CreatePars(), NuMMParameters::Dm2(), Do3FlavFit, Doth34onlyFit, MuELoss::e, Initalise(), NuSystFitter::Minimise(), ProfileMH, OscFit::Theta23(), NuMMParameters::Theta23(), NuMMParameters::Theta34(), vfitPars_th34onlyfit, and vfitPars_three.

00723 {
00724   Initalise();
00725 
00726   std::cout << " " << std::endl;
00727   std::cout << "Doing Sterile Fit" << std::endl;
00728 
00729   std::vector<NuMMParameters> vpars;
00730   std::vector<NuMMParameters> vfitPars;
00731   std::vector<Double_t> vchi2;
00732 
00733   Int_t index(0);
00734 
00735   if( ProfileMH == true ){
00736 
00737     std::cout << "Profiling over both mass hierarchies" << std::endl;
00738 
00739     for (int i = 0; i < 2; ++i) {
00740       for (int j = 0; j < 2; ++j) {
00741         
00742         cout << "i = " << i << ", j = " << j << endl;
00743         
00744         if (Do3FlavFit == true ){
00745           // If there was a three flavour fit i want this intial starting points                                                             
00746           // choose starting Dm2  
00747           pars.Dm2( vfitPars_three[index].Dm2() );
00748           pars.Theta23( vfitPars_three[index].Theta23() );
00749 
00750           cout << "Dm2 from 3 flav = " << vfitPars_three[index].Dm2() << endl;
00751           cout << "th23 from 3 flav = " << vfitPars_three[index].Theta23() << endl;
00752         }
00753 
00754         //if i fit for Theta34 only then set this as a good starting point
00755         if ( Doth34onlyFit == true ) pars.Theta34( vfitPars_th34onlyfit[index].Theta34() );
00756 
00757         NuMMParameters currPars = CreatePars( pars, i, j);
00758         
00759         //currPars.ConstrainDm2( -1e-1, 1e-1 );
00760         currPars.ConstrainTheta23( 0, TMath::Pi()/2 + 1e-2);
00761         currPars.ConstrainTheta34( 0, TMath::Pi()/2 + 1e-2);
00762         currPars.ConstrainTheta24( 0, TMath::Pi()/2 + 1e-2);
00763         currPars.ConstrainDelta1(  0, 2*TMath::Pi() + 1e-2);
00764         currPars.ConstrainDelta2(  0, 2*TMath::Pi() + 1e-2);
00765         currPars.ConstrainDelta3(  0, 2*TMath::Pi() + 1e-2);
00766         
00767         NuMMParameters currBest = fitter->Minimise( currPars );
00768         double currChi2 = ComparePredWithData( currBest );
00769         
00770         vpars.push_back( currPars );
00771         vfitPars.push_back( currBest );
00772         vchi2.push_back( currChi2 );
00773 
00774         index++;
00775       }
00776     }
00777   }
00778   else{ // Do a single mass heirachy
00779 
00780     Int_t MH(0);
00781 
00782     // Figure out which one the user has specified
00783     if( pars.Dm2() > 0 ){
00784       std::cout << "Only doing NH" << std::endl;
00785       MH = 1;
00786     }
00787     else{
00788       std::cout << "Only doing IH" << std::endl;
00789       MH = 0;
00790     }
00791 
00792     for (int i = 0; i < 2; ++i) {
00793 
00794       cout << "i = " << i << endl;
00795 
00796       if ( Doth34onlyFit == true ) pars.Theta34( vfitPars_th34onlyfit[i].Theta34() );
00797       
00798       NuMMParameters currPars = CreatePars( pars, i, MH);
00799 
00800       //if ( MH == 1 ) currPars.ConstrainDm2( 0     , 1e-2 );
00801       //if ( MH == 0 ) currPars.ConstrainDm2( -1e-2 , 0    );
00802 
00803       currPars.ConstrainTheta23( 0, TMath::Pi()/2 );
00804       currPars.ConstrainTheta34( 0, TMath::Pi()/2 );
00805       currPars.ConstrainTheta24( 0, TMath::Pi()/2 );
00806       currPars.ConstrainDelta1(  0, 2*TMath::Pi() );
00807       currPars.ConstrainDelta2(  0, 2*TMath::Pi() );
00808       currPars.ConstrainDelta3(  0, 2*TMath::Pi() );
00809 
00810       NuMMParameters currBest = fitter->Minimise( currPars );
00811       double currChi2 = ComparePredWithData( currBest );
00812 
00813       vpars.push_back( currPars );
00814       vfitPars.push_back( currBest );
00815       vchi2.push_back( currChi2 );
00816       
00817       index++;
00818     }
00819   }
00820   
00821   NuMMParameters bestPars;
00822   Double_t bestChi2 = vchi2[0];
00823 
00824   for ( Int_t i = 0; i < (Int_t)vchi2.size(); ++i) {
00825     if ( vchi2[i] <= bestChi2 ) {
00826       bestChi2 = vchi2[i];
00827       bestPars = vfitPars[i];
00828     }
00829   }
00830 
00831   std::cout << " " << std::endl;
00832   std::cout << "Sterile Fit complete pars fit Complete:" << std::endl;
00833 
00834   return bestPars;
00835 }

void FarOverNearFitPQ::FitTheta34Only ( NuSystFitter fitter,
NuMMParameters  pars 
)

Definition at line 464 of file FarOverNearFitPQ.cxx.

References ComparePredWithData(), NuMMParameters::ConstrainTheta23(), NuMMParameters::ConstrainTheta34(), CreatePars(), NuMMParameters::Dm2(), Do3FlavFit, Doth34onlyFit, NuMMParameters::FixAllParameters(), Initalise(), NuSystFitter::Minimise(), ProfileMH, NuMMParameters::ReleaseTheta34(), OscFit::Theta23(), NuMMParameters::Theta23(), NuMMParameters::Theta34(), vfitPars_th34onlyfit, and vfitPars_three.

00465 {
00466   Initalise();
00467   
00468   std::cout << " " << std::endl;
00469   std::cout << "Fitting Theta34 only" << std::endl;
00470 
00471   std::vector<NuMMParameters> vpars;
00472   std::vector<Double_t> vchi2;
00473 
00474   Int_t index(0);
00475 
00476   if( ProfileMH == true ){
00477 
00478     std::cout << "Profiling over both mass hierarchies" << std::endl;
00479 
00480     for (int i = 0; i < 2; ++i) {
00481       for (int j = 0; j < 2; ++j) {
00482 
00483         if (Do3FlavFit == true ){
00484           pars.Dm2( vfitPars_three[index].Dm2() );
00485           pars.Theta23( vfitPars_three[index].Theta23() );
00486         }
00487         
00488         NuMMParameters currPars = CreatePars( pars, i, j);
00489         
00490         //currPars.ConstrainDm2( -1e-2, 1e-2 );
00491         
00492         currPars.ConstrainTheta23( 0, TMath::Pi()/2 );
00493         currPars.ConstrainTheta34( 0, TMath::Pi()/2 );
00494         
00495         // Only want Theta34 free though                                                                                                     
00496         currPars.FixAllParameters();
00497         currPars.ReleaseTheta34();
00498         
00499         NuMMParameters currBest = fitter->Minimise( currPars );
00500         double currChi2 = ComparePredWithData( currBest );
00501         
00502         vpars.push_back( currPars );
00503         vfitPars_th34onlyfit.push_back( currBest );
00504         vchi2.push_back( currChi2 );
00505         
00506         index++;
00507       }
00508     }
00509   }
00510   else{
00511     Int_t MH(0);
00512     
00513     if( pars.Dm2() > 0 ){
00514       std::cout << "Only doing NH" << std::endl;
00515       MH = 1;
00516     }
00517     else{
00518       std::cout << "Only doing IH" << std::endl;
00519       MH = 0;
00520     }
00521  
00522     for (int i = 0; i < 2; ++i) {
00523       
00524       if (Do3FlavFit == true ){
00525             pars.Dm2( vfitPars_three[i].Dm2() );
00526             pars.Theta23( vfitPars_three[i].Theta23() );
00527       }
00528  
00529       NuMMParameters currPars = CreatePars( pars, i, MH);
00530       
00531       //if ( MH == 1 ) currPars.ConstrainDm2( 0      , 1e-2 );
00532       //if ( MH == 0 ) currPars.ConstrainDm2( -1e-2  , 0     );
00533       
00534       currPars.ConstrainTheta34( 0, TMath::Pi()/2 );
00535       
00536       currPars.FixAllParameters();
00537       currPars.ReleaseTheta34();
00538       
00539       NuMMParameters currBest = fitter->Minimise( currPars );
00540       double currChi2 = ComparePredWithData( currBest );
00541       
00542       vpars.push_back( currPars );
00543       vfitPars_th34onlyfit.push_back( currBest );
00544       vchi2.push_back( currChi2 );
00545 
00546       index++;
00547     }
00548   }
00549 
00550   NuMMParameters bestPars;
00551   Double_t bestChi2 = vchi2[0];
00552   
00553   for ( Int_t i = 0; i < (Int_t)vchi2.size(); ++i) {
00554     if ( vchi2[i] <= bestChi2 ) {
00555       bestChi2 = vchi2[i];
00556       bestPars = vfitPars_th34onlyfit[i];
00557     }
00558   }
00559   
00560   std::cout << " " << std::endl;
00561   std::cout << "Theta34 Only Fit Complete:" << std::endl;
00562   
00563   if( ProfileMH == true ){
00564     
00565     std::cout << "Dm243 best       = " << vfitPars_th34onlyfit[0].Dm243() << " eV^2" << std::endl;
00566     std::cout << "Theta24 best     = " << vfitPars_th34onlyfit[0].Theta24() << " eV^2" << std::endl;
00567     std::cout << "Dm232 best LO IH = " << vfitPars_th34onlyfit[0].Dm2() << " eV^2" << std::endl;
00568     std::cout << "Dm232 best LO NH = " << vfitPars_th34onlyfit[1].Dm2() << " eV^2" << std::endl;
00569     std::cout << "Dm232 best UO IH = " << vfitPars_th34onlyfit[2].Dm2() << " eV^2" << std::endl;
00570     std::cout << "Dm232 best UO NH = " << vfitPars_th34onlyfit[3].Dm2() << " eV^2" << std::endl;
00571     std::cout << "th23 best LO IH  = " << vfitPars_th34onlyfit[0].Theta23() << " radians" << std::endl;
00572     std::cout << "th23 best LO NH  = " << vfitPars_th34onlyfit[1].Theta23() << " radians " << std::endl;
00573     std::cout << "th23 best UO IH  = " << vfitPars_th34onlyfit[2].Theta23() << " radians" << std::endl;
00574     std::cout << "th23 best UO NH  = " << vfitPars_th34onlyfit[3].Theta23() << " radians " << std::endl;
00575     std::cout << "th34 best LO IH  = " << vfitPars_th34onlyfit[0].Theta34() << " radians" << std::endl;
00576     std::cout << "th34 best LO NH  = " << vfitPars_th34onlyfit[1].Theta34() << " radians " << std::endl;
00577     std::cout << "th34 best UO IH  = " << vfitPars_th34onlyfit[2].Theta34() << " radians" << std::endl;
00578     std::cout << "th34 best UO NH  = " << vfitPars_th34onlyfit[3].Theta34() << " radians " << std::endl;
00579     std::cout << "chi2 LO IH       = " << vchi2[0] << " units." << std::endl;
00580     std::cout << "chi2 LO NH       = " << vchi2[1] << " units." << std::endl;
00581     std::cout << "chi2 UO IH       = " << vchi2[2] << " units." << std::endl;
00582     std::cout << "chi2 UO NH       = " << vchi2[3] << " units." << std::endl;
00583   }
00584   else{
00585     std::cout << "Dm232 best LO  = " << vfitPars_th34onlyfit[0].Dm2() << " eV^2" << std::endl;
00586     std::cout << "Dm232 best UO  = " << vfitPars_th34onlyfit[1].Dm2() << " eV^2" << std::endl;
00587     std::cout << "th23 best LO   = " << vfitPars_th34onlyfit[0].Theta23() << " radians" << std::endl;
00588     std::cout << "th23 best UO   = " << vfitPars_th34onlyfit[1].Theta23() << " radians" << std::endl;
00589     std::cout << "th34 best LO   = " << vfitPars_th34onlyfit[0].Theta34() << " radians" << std::endl;
00590     std::cout << "th34 best UO   = " << vfitPars_th34onlyfit[1].Theta34() << " radians" << std::endl;
00591     std::cout << "chi2 LO        = " << vchi2[0] << " units." << std::endl;
00592     std::cout << "chi2 UO        = " << vchi2[1] << " units." << std::endl;
00593   }
00594   
00595   std::cout << " " << std::endl;
00596   std::cout << "Theta23 best     = " << bestPars.Theta23() << " radians" << std::endl;
00597   std::cout << "Theta34 best     = " << bestPars.Theta34() << " radians" << std::endl;
00598   std::cout << "Dm232 best       = " << bestPars.Dm2() << " eV^2" << std::endl;
00599   std::cout << "chi2 best value  = " << bestChi2 << std::endl;
00600   std::cout << " " << std::endl;
00601       
00602   Doth34onlyFit = true;
00603 }

Double_t FarOverNearFitPQ::GetTotalChi2_CC (  ) 

Definition at line 238 of file FarOverNearFitPQ.cxx.

References totalChi2_CC.

00239 {
00240   return totalChi2_CC;
00241 }

Double_t FarOverNearFitPQ::GetTotalChi2_NC (  ) 

Definition at line 233 of file FarOverNearFitPQ.cxx.

References totalChi2_NC.

00234 {
00235   return totalChi2_NC;
00236 }

void FarOverNearFitPQ::Initalise (  ) 
void FarOverNearFitPQ::LoadHelpers (  ) 

Definition at line 124 of file FarOverNearFitPQ.cxx.

References SterileSpec::CC, DatafromTFile, FD_data, FD_dataCC, FD_dataNC, FD_MC, FD_MC_POT, FD_Nue, FD_Nue_POT, FD_NuTau, FD_NuTau_POT, FDCC_AppNue, FDCC_AppNuTau, FDCC_BeamNue, FDCC_NuMu, FDCC_TrueNC, FDNC_AppNue, FDNC_AppNuTau, FDNC_BeamNue, FDNC_NuMu, FDNC_TrueNC, got_helpers, SterileSpec::NC, ND_data, ND_data_POT, ND_dataCC, ND_dataNC, ND_MC, ND_MC_POT, ND_Nue, ND_Nue_POT, ND_NuTau, ND_NuTau_POT, NDCC_AppNue, NDCC_AppNuTau, NDCC_BeamNue, NDCC_NuMu, NDCC_TrueNC, NDNC_AppNue, NDNC_AppNuTau, NDNC_BeamNue, NDNC_NuMu, NDNC_TrueNC, RdataCC, RdataNC, and SpectrumClass.

Referenced by Initalise().

00125 {
00126   if(got_helpers) return;
00127 
00128   // Do we have the TFiles? If not.. assert.
00129   assert(ND_MC); assert(ND_Nue); assert(ND_NuTau);
00130   assert(FD_MC); assert(FD_Nue); assert(FD_NuTau);
00131 
00132   ND_MC->GetObject("hRecoToTrueNCSelectedTrueNC",      NDNC_TrueNC);   assert(NDNC_TrueNC);
00133   ND_MC->GetObject("hRecoToTrueNCSelectedTrueCCNuMu",  NDNC_NuMu);     assert(NDNC_NuMu);
00134   ND_MC->GetObject("hRecoToTrueNCSelectedBeamNue",     NDNC_BeamNue);  assert(NDNC_BeamNue);
00135   ND_Nue->GetObject("hRecoToTrueNCSelectedAppearNue",   NDNC_AppNue);   assert(NDNC_AppNue);
00136   ND_NuTau->GetObject("hRecoToTrueNCSelectedAppearNuTau", NDNC_AppNuTau); assert(NDNC_AppNuTau);
00137 
00138   ND_MC->GetObject("hRecoToTrueCCSelectedTrueNC",      NDCC_TrueNC);   assert(NDCC_TrueNC);
00139   ND_MC->GetObject("hRecoToTrueCCSelectedTrueCCNuMu",  NDCC_NuMu);     assert(NDCC_NuMu);
00140   ND_MC->GetObject("hRecoToTrueCCSelectedBeamNue",     NDCC_BeamNue);  assert(NDCC_BeamNue);
00141   ND_Nue->GetObject("hRecoToTrueCCSelectedAppearNue",   NDCC_AppNue);   assert(NDCC_AppNue);
00142   ND_NuTau->GetObject("hRecoToTrueCCSelectedAppearNuTau", NDCC_AppNuTau); assert(NDCC_AppNuTau);
00143 
00144   FD_MC->GetObject("hRecoToTrueNCSelectedTrueNC",      FDNC_TrueNC);   assert(FDNC_TrueNC);
00145   FD_MC->GetObject("hRecoToTrueNCSelectedTrueCCNuMu",  FDNC_NuMu);     assert(FDNC_NuMu);
00146   FD_MC->GetObject("hRecoToTrueNCSelectedBeamNue",     FDNC_BeamNue);  assert(FDNC_BeamNue);
00147   FD_Nue->GetObject("hRecoToTrueNCSelectedAppearNue",   FDNC_AppNue);   assert(FDNC_AppNue);
00148   FD_NuTau->GetObject("hRecoToTrueNCSelectedAppearNuTau", FDNC_AppNuTau); assert(FDNC_AppNuTau);
00149 
00150   FD_MC->GetObject("hRecoToTrueCCSelectedTrueNC",      FDCC_TrueNC);   assert(FDCC_TrueNC);
00151   FD_MC->GetObject("hRecoToTrueCCSelectedTrueCCNuMu",  FDCC_NuMu);     assert(FDCC_NuMu);
00152   FD_MC->GetObject("hRecoToTrueCCSelectedBeamNue",     FDCC_BeamNue);  assert(FDCC_BeamNue);
00153   FD_Nue->GetObject("hRecoToTrueCCSelectedAppearNue",   FDCC_AppNue);   assert(FDCC_AppNue);
00154   FD_NuTau->GetObject("hRecoToTrueCCSelectedAppearNuTau", FDCC_AppNuTau); assert(FDCC_AppNuTau);
00155 
00156   ND_MC->GetObject("hTotalPot", ND_MC_POT);    assert(ND_MC_POT);
00157   ND_Nue->GetObject("hTotalPot", ND_Nue_POT);   assert(ND_Nue_POT);
00158   ND_NuTau->GetObject("hTotalPot", ND_NuTau_POT); assert(ND_NuTau_POT);
00159   FD_MC->GetObject("hTotalPot", FD_MC_POT);    assert(FD_MC_POT);
00160   FD_Nue->GetObject("hTotalPot", FD_Nue_POT);   assert(FD_Nue_POT);
00161   FD_NuTau->GetObject("hTotalPot", FD_NuTau_POT); assert(FD_NuTau_POT);
00162 
00163   if( DatafromTFile == true ){
00164 
00165     std::cout << "Obtaining data from TFile." << std::endl;
00166 
00167     FD_data->GetObject("hRecoEnergyNC",    FD_dataNC); assert(FD_dataNC);
00168     FD_dataNC->SetName("hRecoEnergyNC_FD");
00169     FD_data->GetObject("hRecoEnergyCCPQ", FD_dataCC); assert(FD_dataCC);
00170     FD_dataCC->SetName("hRecoEnergyCCPQ_FD");
00171 
00172     ND_data->GetObject("hRecoEnergyNC",    ND_dataNC); assert(ND_dataNC);
00173     ND_dataNC->SetName("hRecoEnergyNC_ND");
00174     ND_data->GetObject("hRecoEnergyCCPQ", ND_dataCC); assert(ND_dataCC);
00175     ND_dataCC->SetName("hRecoEnergyCCPQ_ND");
00176 
00177     // Normalise ND with POT
00178     ND_data->GetObject("hTotalPot", ND_data_POT);  assert(ND_data_POT);
00179     double dataPOT = ND_data_POT->Integral();
00180     ND_dataNC->Scale(POT/dataPOT);
00181     ND_dataCC->Scale(POT/dataPOT);
00182 
00183     // Might as well rebin the data now
00184     FD_dataNC = SpectrumClass->SterileSpec::Rebin4Chi2(FD_dataNC, SterileSpec::NC);
00185     FD_dataCC = SpectrumClass->SterileSpec::Rebin4Chi2(FD_dataCC, SterileSpec::CC);
00186     ND_dataNC = SpectrumClass->SterileSpec::Rebin4Chi2(ND_dataNC, SterileSpec::NC);
00187     ND_dataCC = SpectrumClass->SterileSpec::Rebin4Chi2(ND_dataCC, SterileSpec::CC);
00188 
00189     // Create data ratios
00190     RdataCC = (TH1D*)FD_dataCC->Clone();
00191     RdataCC->Divide(ND_dataCC);
00192 
00193     RdataNC = (TH1D*)FD_dataNC->Clone();
00194     RdataNC->Divide(ND_dataNC);
00195   }
00196 
00197   // Normalise everything
00198   double ndmcPOT = ND_MC_POT->Integral();
00199   NDNC_TrueNC->Scale(POT/ndmcPOT);
00200   NDNC_NuMu->Scale(POT/ndmcPOT);
00201   NDNC_BeamNue->Scale(POT/ndmcPOT);
00202   NDCC_TrueNC->Scale(POT/ndmcPOT);
00203   NDCC_NuMu->Scale(POT/ndmcPOT);
00204   NDCC_BeamNue->Scale(POT/ndmcPOT);
00205 
00206   double ndnuePOT = ND_Nue_POT->Integral();
00207   NDNC_AppNue->Scale(POT/ndnuePOT);
00208   NDCC_AppNue->Scale(POT/ndnuePOT);
00209 
00210   double ndnutauPOT = ND_NuTau_POT->Integral();
00211   NDNC_AppNuTau->Scale(POT/ndnutauPOT);
00212   NDCC_AppNuTau->Scale(POT/ndnutauPOT);
00213 
00214   double fdmcPOT = FD_MC_POT->Integral();
00215   FDNC_TrueNC->Scale(POT/fdmcPOT);
00216   FDNC_NuMu->Scale(POT/fdmcPOT);
00217   FDNC_BeamNue->Scale(POT/fdmcPOT);
00218   FDCC_TrueNC->Scale(POT/fdmcPOT);
00219   FDCC_NuMu->Scale(POT/fdmcPOT);
00220   FDCC_BeamNue->Scale(POT/fdmcPOT);
00221 
00222   double fdnuePOT = FD_Nue_POT->Integral();
00223   FDNC_AppNue->Scale(POT/fdnuePOT);
00224   FDCC_AppNue->Scale(POT/fdnuePOT);
00225 
00226   double fdnutauPOT = FD_NuTau_POT->Integral();
00227   FDNC_AppNuTau->Scale(POT/fdnutauPOT);
00228   FDCC_AppNuTau->Scale(POT/fdnutauPOT);
00229 
00230   got_helpers = true;
00231 }

void FarOverNearFitPQ::LoadMatrices (  ) 

Definition at line 99 of file FarOverNearFitPQ.cxx.

References CoVarCC, CoVarCCinvert, CoVarNC, CoVarNCinvert, got_matrices, and matrix.

Referenced by Initalise().

00100 {
00101   if(got_matrices) return;
00102 
00103   CoVarCCinvert = (TMatrixD*)matrix->Get("TotalInvertCC"); assert(CoVarCCinvert);
00104   CoVarNCinvert = (TMatrixD*)matrix->Get("TotalInvertNC"); assert(CoVarNCinvert);
00105 
00106   CoVarCC = (TMatrixD*)matrix->Get("TotalCCCovar"); assert(CoVarCC);
00107   CoVarNC = (TMatrixD*)matrix->Get("TotalNCCovar"); assert(CoVarNC);
00108 
00109 }

std::vector<Double_t> FarOverNearFitPQ::LogBins ( int  nbins,
double  xlo,
double  xhi 
)
void FarOverNearFitPQ::MakeFlucuatedRatios ( const NuMMParameters parameters  ) 

Definition at line 334 of file FarOverNearFitPQ.cxx.

References CoVarCC, CoVarNC, CreateFakeHighStatsData(), MultiVarGauss::Generate(), RfakeCC, RfakeNC, RflucCC, and RflucNC.

00335 {
00336   CreateFakeHighStatsData(pars);
00337 
00338   // Make sure my pointers are clean and tidy
00339   if (RflucCC) {delete RflucCC;  RflucCC = 0;}
00340   if (RflucNC) {delete RflucNC;  RflucNC = 0;}
00341 
00342   // Flucuate it bin to bin correlations from matrix
00343   MultiVarGauss SampleFlucCC(RfakeCC, CoVarCC);
00344   MultiVarGauss SampleFlucNC(RfakeNC, CoVarNC);
00345 
00346   RflucCC = new TH1D(*SampleFlucCC.Generate());
00347   RflucNC = new TH1D(*SampleFlucNC.Generate());
00348 }

Double_t FarOverNearFitPQ::NDNormPenaltyTerm ( whichPred  Pred  ) 

Definition at line 267 of file FarOverNearFitPQ.cxx.

References CalculateNDIntegrals(), CC, NC, ND_dataCC, ND_dataNC, NDOscCC_MC, NDOscNC_MC, TotalNDCC, and TotalNDNC.

Referenced by ComparePredWithData().

00268 {
00269   CalculateNDIntegrals();
00270 
00271   Double_t UnOsc = 0.0;
00272   Double_t TotalNDData = 0.0;
00273   Double_t TotalOscNDMC = 0.0;
00274 
00275   if(Pred == CC){
00276     UnOsc = TotalNDCC;
00277     TotalNDData = ND_dataCC->Integral(1, ND_dataCC->FindFixBin(40) );
00278     TotalOscNDMC = NDOscCC_MC->Integral(1, NDOscCC_MC->FindFixBin(40));
00279   }
00280 
00281   if(Pred == NC){
00282     UnOsc = TotalNDNC;
00283     TotalNDData = ND_dataNC->Integral(1, ND_dataNC->FindFixBin(40));
00284     TotalOscNDMC = NDOscNC_MC->Integral(1, NDOscNC_MC->FindFixBin(40));
00285   }
00286 
00287   // This is a 50% uncertainty 
00288   Double_t sigma = 0.5*UnOsc;
00289   Double_t Norm = (TotalNDData - TotalOscNDMC) * (TotalNDData - TotalOscNDMC);
00290 
00291   Norm = Norm / (sigma * sigma);
00292 
00293   return Norm;
00294 }

Double_t FarOverNearFitPQ::PenaltyTermDm232 ( Double_t  dm232  ) 

Definition at line 404 of file FarOverNearFitPQ.cxx.

Referenced by ComparePredWithData().

00405 {
00406   // This is just (Dm2 - CentralValue)^2/(sigma)^2 
00407   Double_t dm232_pen = 0.0;
00408   dm232_pen = TMath::Power( (TMath::Abs(dm232) - 0.0025) , 2); // numerator
00409   dm232_pen /= TMath::Power( 0.0005, 2);
00410 
00411   return dm232_pen;
00412 }

void FarOverNearFitPQ::PerformInitialThreeFlavourFit ( NuSystFitter fitter,
NuMMParameters  pars 
)

Definition at line 605 of file FarOverNearFitPQ.cxx.

References ComparePredWithData(), NuMMParameters::ConstrainDelta1(), NuMMParameters::ConstrainDelta2(), NuMMParameters::ConstrainDelta3(), NuMMParameters::ConstrainTheta23(), NuMMParameters::ConstrainTheta24(), NuMMParameters::ConstrainTheta34(), CreateThreeFlavPars(), NuMMParameters::Dm2(), Do3FlavFit, Initalise(), NuSystFitter::Minimise(), ProfileMH, NuMMParameters::Theta23(), and vfitPars_three.

00606 {
00607   Initalise();
00608 
00609   std::cout << " " << std::endl;
00610   std::cout << "Initally performing Three flavour fit" << std::endl;
00611   
00612   std::vector<NuMMParameters> vpars;
00613   std::vector<Double_t> vchi2;
00614   
00615   if( ProfileMH == true ){
00616 
00617     std::cout << "Profiling over both mass hierarchies" << std::endl;
00618 
00619     for (int i = 0; i < 2; ++i) {
00620       for (int j = 0; j < 2; ++j) {
00621 
00622         NuMMParameters currPars = CreateThreeFlavPars( pars, i, j);
00623 
00624         //currPars.ConstrainDm2( -1e-2, 1e-2 );
00625         currPars.ConstrainTheta23( 0, TMath::Pi()/2 );
00626         currPars.ConstrainTheta34( 0, TMath::Pi()/2 );
00627         currPars.ConstrainTheta24( 0, TMath::Pi()/2 );
00628         currPars.ConstrainDelta1(  0, 2*TMath::Pi() );
00629         currPars.ConstrainDelta2(  0, 2*TMath::Pi() );
00630         currPars.ConstrainDelta3(  0, 2*TMath::Pi() );
00631 
00632         NuMMParameters currBest = fitter->Minimise( currPars );
00633         double currChi2 = ComparePredWithData( currBest );
00634 
00635         vpars.push_back( currPars );
00636         vfitPars_three.push_back( currBest );
00637         vchi2.push_back( currChi2 );
00638       }
00639     }
00640   }
00641   else{
00642     Int_t MH(0);
00643 
00644     if( pars.Dm2() > 0 ){
00645       std::cout << "Only doing NH" << std::endl;
00646       MH = 1;
00647     }
00648     else{
00649       std::cout << "Only doing IH" << std::endl;
00650       MH = 0;
00651     }
00652 
00653     for (int i = 0; i < 2; ++i) {
00654 
00655       NuMMParameters currPars = CreateThreeFlavPars( pars, i, MH);
00656 
00657       //if ( MH == 1 ) currPars.ConstrainDm2( 0      , 1e-2 );
00658       //if ( MH == 0 ) currPars.ConstrainDm2( -1e-2 , 0     );
00659 
00660       currPars.ConstrainTheta23( 0, TMath::Pi()/2 );
00661       currPars.ConstrainTheta34( 0, TMath::Pi()/2 );
00662       currPars.ConstrainTheta24( 0, TMath::Pi()/2 );
00663       currPars.ConstrainDelta1(  0, 2*TMath::Pi() );
00664       currPars.ConstrainDelta2(  0, 2*TMath::Pi() );
00665       currPars.ConstrainDelta3(  0, 2*TMath::Pi() );
00666 
00667       NuMMParameters currBest = fitter->Minimise( currPars );
00668       double currChi2 = ComparePredWithData( currBest );
00669 
00670       vpars.push_back( currPars );
00671       vfitPars_three.push_back( currBest );
00672       vchi2.push_back( currChi2 );
00673     }
00674   }
00675 
00676   NuMMParameters bestPars;
00677   Double_t bestChi2 = vchi2[0];
00678 
00679   for ( Int_t i = 0; i < (Int_t)vchi2.size(); ++i) {
00680     if ( vchi2[i] <= bestChi2 ) {
00681       bestChi2 = vchi2[i];
00682       bestPars = vfitPars_three[i];
00683     }
00684   }
00685 
00686   std::cout << " " << std::endl;
00687   std::cout << "Three flavour fit Complete:" << std::endl;
00688 
00689   if( ProfileMH == true ){
00690     std::cout << "Dm232 best LO IH = " << vfitPars_three[0].Dm2() << " eV^2" << std::endl;
00691     std::cout << "Dm232 best LO NH = " << vfitPars_three[1].Dm2() << " eV^2" << std::endl;
00692     std::cout << "Dm232 best UO IH = " << vfitPars_three[2].Dm2() << " eV^2" << std::endl;
00693     std::cout << "Dm232 best UO NH = " << vfitPars_three[3].Dm2() << " eV^2" << std::endl;
00694     std::cout << "th23 best LO IH  = " << vfitPars_three[0].Theta23() << " radians" << std::endl;
00695     std::cout << "th23 best LO NH  = " << vfitPars_three[1].Theta23() << " radians " << std::endl;
00696     std::cout << "th23 best UO IH  = " << vfitPars_three[2].Theta23() << " radians" << std::endl;
00697     std::cout << "th23 best UO NH  = " << vfitPars_three[3].Theta23() << " radians " << std::endl;
00698     std::cout << "chi2 LO IH       = " << vchi2[0] << " units." << std::endl;
00699     std::cout << "chi2 LO NH       = " << vchi2[1] << " units." << std::endl;
00700     std::cout << "chi2 UO IH       = " << vchi2[2] << " units." << std::endl;
00701     std::cout << "chi2 UO NH       = " << vchi2[3] << " units." << std::endl;
00702   }
00703   else{
00704     std::cout << "Dm232 best LO  = " << vfitPars_three[0].Dm2() << " eV^2" << std::endl;
00705     std::cout << "Dm232 best UO  = " << vfitPars_three[1].Dm2() << " eV^2" << std::endl;
00706     std::cout << "th23 best LO   = " << vfitPars_three[0].Theta23() << " radians" << std::endl;
00707     std::cout << "th23 best UO   = " << vfitPars_three[1].Theta23() << " radians" << std::endl;
00708     std::cout << "chi2 LO        = " << vchi2[0] << " units." << std::endl;
00709     std::cout << "chi2 UO        = " << vchi2[1] << " units." << std::endl;
00710   }
00711 
00712   std::cout << " " << std::endl;
00713   std::cout << "Theta23 best     = " << bestPars.Theta23() << " radians" << std::endl;
00714   std::cout << "Dm232 best       = " << bestPars.Dm2() << " eV^2" << std::endl;
00715   std::cout << "chi2 best value  = " << bestChi2 << std::endl;
00716   std::cout << " " << std::endl;
00717 
00718   Do3FlavFit = true;
00719 
00720 }

void FarOverNearFitPQ::ProfileMassHierarchy (  ) 

Definition at line 863 of file FarOverNearFitPQ.cxx.

References ProfileMH.

00864 {
00865   ProfileMH = true;
00866 }

void FarOverNearFitPQ::SetDataFromTFile ( TFile *  NDData_file,
TFile *  FDData_file 
)

Definition at line 61 of file FarOverNearFitPQ.cxx.

References DatafromTFile, FD_data, and ND_data.

00062 {
00063   ND_data = NDData_file;
00064   FD_data = FDData_file;
00065 
00066   DatafromTFile = true;
00067 }

void FarOverNearFitPQ::SetFDBaseline ( double  baseline  ) 

Definition at line 87 of file FarOverNearFitPQ.cxx.

References FD_baseline.

00088 {
00089   FD_baseline = baseline;
00090 }

void FarOverNearFitPQ::SetFDMC ( TFile *  MC_file,
TFile *  Nue_file,
TFile *  NuTau_file 
)

Definition at line 75 of file FarOverNearFitPQ.cxx.

References FD_MC, FD_Nue, and FD_NuTau.

00076 {
00077   FD_MC    = MC_file;
00078   FD_Nue   = Nue_file;
00079   FD_NuTau = NuTau_file;
00080 }

void FarOverNearFitPQ::SetMatrices ( TFile *  Data_file  ) 

Definition at line 82 of file FarOverNearFitPQ.cxx.

References matrix.

00083 {
00084   matrix = Data_file;
00085 }

void FarOverNearFitPQ::SetNDBaseline ( double  baseline  ) 

Definition at line 69 of file FarOverNearFitPQ.cxx.

References ND_baseline.

00070 {
00071   ND_baseline = baseline;
00072 }

void FarOverNearFitPQ::SetNDMC ( TFile *  MC_file,
TFile *  Nue_file,
TFile *  NuTau_file 
)

Definition at line 53 of file FarOverNearFitPQ.cxx.

References ND_MC, ND_Nue, and ND_NuTau.

00054 {
00055   ND_MC    = MC_file;
00056   ND_Nue   = Nue_file;
00057   ND_NuTau = NuTau_file;
00058 }

void FarOverNearFitPQ::SetPOT ( double  POT_  ) 

Definition at line 93 of file FarOverNearFitPQ.cxx.

00094 {
00095   POT = POT_;
00096 }

void FarOverNearFitPQ::UseDm241 ( bool  YesorNo  ) 

Definition at line 868 of file FarOverNearFitPQ.cxx.

References SpectrumClass, and use41.

00869 {
00870   use41 = YesorNo;
00871   SpectrumClass->SterileSpec::UseDm241(use41);
00872 }

std::vector< TH1D > FarOverNearFitPQ::WriteFDPredHistos ( const NuMMParameters pars  )  const [virtual]

Implements NuMMRun.

Definition at line 874 of file FarOverNearFitPQ.cxx.

00875 {
00876   // This is a virtual function i need because i inherhit
00877   return vector<TH1D>();
00878 }


Member Data Documentation

Definition at line 77 of file FarOverNearFitPQ.h.

Referenced by Initalise(), LoadMatrices(), and MakeFlucuatedRatios().

Definition at line 75 of file FarOverNearFitPQ.h.

Referenced by ComparePredWithData(), Initalise(), and LoadMatrices().

Definition at line 77 of file FarOverNearFitPQ.h.

Referenced by Initalise(), LoadMatrices(), and MakeFlucuatedRatios().

Definition at line 75 of file FarOverNearFitPQ.h.

Referenced by ComparePredWithData(), Initalise(), and LoadMatrices().

Definition at line 124 of file FarOverNearFitPQ.h.

Referenced by LoadHelpers(), and SetDataFromTFile().

Definition at line 126 of file FarOverNearFitPQ.h.

Referenced by DoFit(), FitTheta34Only(), and PerformInitialThreeFlavourFit().

Definition at line 126 of file FarOverNearFitPQ.h.

Referenced by DoFit(), and FitTheta34Only().

Definition at line 105 of file FarOverNearFitPQ.h.

Referenced by Initalise(), and SetFDBaseline().

TFile * FarOverNearFitPQ::FD_data [private]

Definition at line 116 of file FarOverNearFitPQ.h.

Referenced by LoadHelpers(), and SetDataFromTFile().

Definition at line 92 of file FarOverNearFitPQ.h.

Referenced by LoadHelpers().

Definition at line 92 of file FarOverNearFitPQ.h.

Referenced by LoadHelpers().

TFile* FarOverNearFitPQ::FD_MC [private]

Definition at line 116 of file FarOverNearFitPQ.h.

Referenced by LoadHelpers(), and SetFDMC().

Definition at line 81 of file FarOverNearFitPQ.h.

Referenced by LoadHelpers().

TFile * FarOverNearFitPQ::FD_Nue [private]

Definition at line 116 of file FarOverNearFitPQ.h.

Referenced by LoadHelpers(), and SetFDMC().

Definition at line 81 of file FarOverNearFitPQ.h.

Referenced by LoadHelpers().

TFile * FarOverNearFitPQ::FD_NuTau [private]

Definition at line 116 of file FarOverNearFitPQ.h.

Referenced by LoadHelpers(), and SetFDMC().

Definition at line 81 of file FarOverNearFitPQ.h.

Referenced by LoadHelpers().

Definition at line 89 of file FarOverNearFitPQ.h.

Referenced by Initalise(), and LoadHelpers().

Definition at line 89 of file FarOverNearFitPQ.h.

Referenced by Initalise(), and LoadHelpers().

Definition at line 89 of file FarOverNearFitPQ.h.

Referenced by Initalise(), and LoadHelpers().

Definition at line 89 of file FarOverNearFitPQ.h.

Referenced by Initalise(), and LoadHelpers().

Definition at line 89 of file FarOverNearFitPQ.h.

Referenced by Initalise(), and LoadHelpers().

Definition at line 93 of file FarOverNearFitPQ.h.

Referenced by CreateFakeHighStatsData().

Definition at line 93 of file FarOverNearFitPQ.h.

Referenced by CreateFakeHighStatsData().

Definition at line 88 of file FarOverNearFitPQ.h.

Referenced by Initalise(), and LoadHelpers().

Definition at line 88 of file FarOverNearFitPQ.h.

Referenced by Initalise(), and LoadHelpers().

Definition at line 88 of file FarOverNearFitPQ.h.

Referenced by Initalise(), and LoadHelpers().

Definition at line 88 of file FarOverNearFitPQ.h.

Referenced by Initalise(), and LoadHelpers().

Definition at line 88 of file FarOverNearFitPQ.h.

Referenced by Initalise(), and LoadHelpers().

Definition at line 96 of file FarOverNearFitPQ.h.

Referenced by ComparePredWithData().

Definition at line 96 of file FarOverNearFitPQ.h.

Referenced by ComparePredWithData().

Definition at line 110 of file FarOverNearFitPQ.h.

Referenced by LoadHelpers().

Definition at line 110 of file FarOverNearFitPQ.h.

Referenced by LoadMatrices().

Definition at line 124 of file FarOverNearFitPQ.h.

Referenced by CalculateNDIntegrals().

bool FarOverNearFitPQ::init [private]

Definition at line 124 of file FarOverNearFitPQ.h.

Referenced by Initalise().

TFile* FarOverNearFitPQ::matrix [private]

Definition at line 119 of file FarOverNearFitPQ.h.

Referenced by LoadMatrices(), and SetMatrices().

Definition at line 105 of file FarOverNearFitPQ.h.

Referenced by Initalise(), and SetNDBaseline().

TFile * FarOverNearFitPQ::ND_data [private]

Definition at line 115 of file FarOverNearFitPQ.h.

Referenced by LoadHelpers(), and SetDataFromTFile().

Definition at line 80 of file FarOverNearFitPQ.h.

Referenced by LoadHelpers().

Definition at line 92 of file FarOverNearFitPQ.h.

Referenced by LoadHelpers(), and NDNormPenaltyTerm().

Definition at line 92 of file FarOverNearFitPQ.h.

Referenced by LoadHelpers(), and NDNormPenaltyTerm().

TFile* FarOverNearFitPQ::ND_MC [private]

Definition at line 115 of file FarOverNearFitPQ.h.

Referenced by LoadHelpers(), and SetNDMC().

Definition at line 80 of file FarOverNearFitPQ.h.

Referenced by LoadHelpers().

TFile * FarOverNearFitPQ::ND_Nue [private]

Definition at line 115 of file FarOverNearFitPQ.h.

Referenced by LoadHelpers(), and SetNDMC().

Definition at line 80 of file FarOverNearFitPQ.h.

Referenced by LoadHelpers().

TFile * FarOverNearFitPQ::ND_NuTau [private]

Definition at line 115 of file FarOverNearFitPQ.h.

Referenced by LoadHelpers(), and SetNDMC().

Definition at line 80 of file FarOverNearFitPQ.h.

Referenced by LoadHelpers().

Definition at line 85 of file FarOverNearFitPQ.h.

Referenced by Initalise(), and LoadHelpers().

Definition at line 85 of file FarOverNearFitPQ.h.

Referenced by Initalise(), and LoadHelpers().

Definition at line 85 of file FarOverNearFitPQ.h.

Referenced by Initalise(), and LoadHelpers().

Definition at line 85 of file FarOverNearFitPQ.h.

Referenced by Initalise(), and LoadHelpers().

Definition at line 85 of file FarOverNearFitPQ.h.

Referenced by Initalise(), and LoadHelpers().

Definition at line 93 of file FarOverNearFitPQ.h.

Referenced by CreateFakeHighStatsData().

Definition at line 93 of file FarOverNearFitPQ.h.

Referenced by CreateFakeHighStatsData().

Definition at line 84 of file FarOverNearFitPQ.h.

Referenced by Initalise(), and LoadHelpers().

Definition at line 84 of file FarOverNearFitPQ.h.

Referenced by Initalise(), and LoadHelpers().

Definition at line 84 of file FarOverNearFitPQ.h.

Referenced by Initalise(), and LoadHelpers().

Definition at line 84 of file FarOverNearFitPQ.h.

Referenced by Initalise(), and LoadHelpers().

Definition at line 84 of file FarOverNearFitPQ.h.

Referenced by Initalise(), and LoadHelpers().

Definition at line 96 of file FarOverNearFitPQ.h.

Referenced by ComparePredWithData(), and NDNormPenaltyTerm().

Definition at line 96 of file FarOverNearFitPQ.h.

Referenced by ComparePredWithData(), and NDNormPenaltyTerm().

Double_t FarOverNearFitPQ::POT [private]

Definition at line 121 of file FarOverNearFitPQ.h.

Definition at line 99 of file FarOverNearFitPQ.h.

Referenced by ComparePredWithData(), and LoadHelpers().

Definition at line 99 of file FarOverNearFitPQ.h.

Referenced by ComparePredWithData(), and LoadHelpers().

Definition at line 102 of file FarOverNearFitPQ.h.

Referenced by CreateFakeHighStatsData(), and MakeFlucuatedRatios().

Definition at line 102 of file FarOverNearFitPQ.h.

Referenced by CreateFakeHighStatsData(), and MakeFlucuatedRatios().

Definition at line 101 of file FarOverNearFitPQ.h.

Referenced by MakeFlucuatedRatios().

Definition at line 101 of file FarOverNearFitPQ.h.

Referenced by MakeFlucuatedRatios().

Definition at line 100 of file FarOverNearFitPQ.h.

Referenced by ComparePredWithData().

Definition at line 100 of file FarOverNearFitPQ.h.

Referenced by ComparePredWithData().

Definition at line 106 of file FarOverNearFitPQ.h.

Referenced by ComparePredWithData().

Definition at line 106 of file FarOverNearFitPQ.h.

Referenced by ComparePredWithData(), and GetTotalChi2_CC().

Definition at line 106 of file FarOverNearFitPQ.h.

Referenced by ComparePredWithData(), and GetTotalChi2_NC().

Double_t FarOverNearFitPQ::TotalNDCC [private]

Definition at line 122 of file FarOverNearFitPQ.h.

Referenced by CalculateNDIntegrals(), and NDNormPenaltyTerm().

Double_t FarOverNearFitPQ::TotalNDNC [private]

Definition at line 122 of file FarOverNearFitPQ.h.

Referenced by CalculateNDIntegrals(), and NDNormPenaltyTerm().

Definition at line 108 of file FarOverNearFitPQ.h.

Referenced by UseDm241().

Definition at line 72 of file FarOverNearFitPQ.h.

Referenced by DoFit(), and FitTheta34Only().

Definition at line 71 of file FarOverNearFitPQ.h.

Referenced by DoFit(), FitTheta34Only(), and PerformInitialThreeFlavourFit().


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

Generated on 22 Nov 2017 for loon by  doxygen 1.6.1