23 #include "Utilities/func/MathUtil.h" 51 const Cut cutNDPIDNue(
kLEM > .64 );
52 const Cut cutNDNue( cutNDContNue && cutNDPIDNue );
56 const std::string farNonS =
"$NOVA_PROD/mc/FA14-10-28/genie/fd/caf/000148/*/*fhc_nonswap*.caf.root";
57 const std::string farSwap =
"$NOVA_PROD/mc/FA14-10-28/genie/fd/caf/000148/*/*fhc_swap*.caf.root";
58 const std::string nearNonS =
"$NOVA_PROD/mc/FA14-11-25/genie/nd/caf/*103/10378/*s101*.caf.root";
68 shift.
SetShift(
new GenieRwgtTableSyst(rwgt::fReweightRvnCC2pi), +2);
69 shift.
SetShift(
new GenieRwgtTableSyst(rwgt::fReweightRvnNC2pi), +2);
70 shift.
SetShift(
new GenieRwgtTableSyst(rwgt::fReweightRvbarnCC2pi), +2);
71 shift.
SetShift(
new GenieRwgtTableSyst(rwgt::fReweightRvbarnNC2pi), +2);
82 Spectrum CCMCME (EAxis.label, loaderNDMC,
83 EAxis.bins, EAxis.var,
86 Spectrum NCMCME (EAxis.label, loaderNDMC,
87 EAxis.bins, EAxis.var,
90 Spectrum NEMCME (EAxis.label, loaderNDMC,
91 EAxis.bins, EAxis.var,
94 Spectrum CCDataME(EAxis.label, loaderNDMC,
95 EAxis.bins, EAxis.var,
98 Spectrum NCDataME(EAxis.label, loaderNDMC,
99 EAxis.bins, EAxis.var,
101 cutNDNue &&
kIsNC, shift);
102 Spectrum NEDataME(EAxis.label, loaderNDMC,
103 EAxis.bins, EAxis.var,
124 EAxis.label, EAxis.bins, EAxis.var, cutNDPIDNue,
kNoShift);
129 EAxis.label, EAxis.bins, EAxis.var, cutNDPIDNue, shift);
144 double ourPOT = CCDataME.
POT();
161 TFile*
outFile =
new TFile(
"Rvn2pi.root",
"RECREATE");
164 CCMCME.
ToTH2(ourPOT)->Write(
"ME_Dist_CCMC");
165 NCMCME.
ToTH2(ourPOT)->Write(
"ME_Dist_NCMC");
166 NEMCME.
ToTH2(ourPOT)->Write(
"ME_Dist_NuEMC");
167 CCDataME.
ToTH2(ourPOT)->Write(
"ME_Dist_CCData");
168 NCDataME.
ToTH2(ourPOT)->Write(
"ME_Dist_NCData");
169 NEDataME.
ToTH2(ourPOT)->Write(
"ME_Dist_NuEData");
171 obsBlah.
ToTH1(ourPOT)->Write(
"obsDCMP");
172 obsNominal.
ToTH1(ourPOT)->Write(
"obsNominal");
173 obsShifts.
ToTH1(ourPOT)->Write(
"obsShifted");
175 bkgdDCMP.
ToTH1(ourPOT)->Write(
"bkgdDCMP");
176 bkgdNominal.
ToTH1(ourPOT)->Write(
"bkgdNominal");
177 bkgdShifted.
ToTH1(ourPOT)->Write(
"bkgdShifted");
179 CCMC.
ToTH1(ourPOT)->Write(
"ND_CCMC");
180 CCData.
ToTH1(ourPOT)->Write(
"ND_CCData");
181 CCDCMP.
ToTH1(ourPOT)->Write(
"ND_CCDCMP");
183 NCMC.
ToTH1(ourPOT)->Write(
"ND_NCMC");
184 NCData.
ToTH1(ourPOT)->Write(
"ND_NCData");
185 NCDCMP.
ToTH1(ourPOT)->Write(
"ND_NCDCMP");
187 NEMC.
ToTH1(ourPOT)->Write(
"ND_NEMC");
188 NEData.
ToTH1(ourPOT)->Write(
"ND_NEData");
189 NEDCMP.
ToTH1(ourPOT)->Write(
"ND_NEDCMP");
const Cut kIsNumuCC(CCFlavSel(14, 14))
Select CC .
virtual void SetL(double L)=0
TH2 * ToTH2(double exposure, EExposureType expotype=kPOT, EBinType bintype=kBinContent) const
Spectrum must be 2D to obtain TH2.
Represent the binning of a Spectrum's x-axis.
Cuts and Vars for the 2020 FD DiF Study.
TH1D * ToTH1(double exposure, Color_t col=kBlack, Style_t style=kSolid, EExposureType expotype=kPOT, EBinType bintype=kBinContent) const
Histogram made from this Spectrum, scaled to some exposure.
virtual void SetDmsq21(const T &dmsq21)=0
Simple record of shifts applied to systematic parameters.
virtual Spectrum AntiNumuComponent() const override
virtual void SetTh13(const T &th13)=0
const Cut kIsBeamNue(CCFlavSel(12, 12))
Select CC .
virtual Spectrum NumuComponent() const override
virtual void SetDmsq32(const T &dmsq32)=0
void resetCalc(osc::IOscCalcAdjustable *calc)
Representation of a spectrum in any variable, with associated POT.
virtual Spectrum AntiNueComponent() const override
Charged-current interactions.
Uses MC for NC and CC components, assigns remainder of data to CC.
const Var kCaloE
Summed calorimetric energy of all hits in slice, uncorrected.
const Cut kIsNC([](const caf::SRProxy *sr){if(sr->mc.nnu==0) return false;assert(sr->mc.nnu==1);return!sr->mc.nu[0].iscc;})
Is this a Neutral Current event?
Spectrum FakeData(double pot) const
Synonymous with AsimovData(). Retained for compatibility.
Optimized version of OscCalcPMNS.
virtual Spectrum NueComponent() const override
virtual void Go() override
Load all the registered spectra.
const Var kNMichels([](const caf::SRProxy *sr){int n_me=0;for(int i=0;i< (int) sr->me.nslc;i++) if(sr->me.slc[i].mid > 1. &&sr->me.slc[i].deltat > 1200.) n_me++;for(int i=0;i< (int) sr->me.nkalman;i++) if(sr->me.trkkalman[i].mid > 0. &&sr->me.trkkalman[i].deltat > 800.) n_me++;if(n_me > 2) n_me=2;return n_me;})
Number of SlcME's assoc with slice.
const SystShifts kNoShift
const Cut kNDContainNue([](const caf::SRProxy *sr){if(sr->vtx.elastic.fuzzyk.nshwlid<=0) return false;const caf::SRShowerLIDProxy &shwlid=sr->vtx.elastic.fuzzyk.png[0].shwlid;const caf::SRVector3DProxy &start=shwlid.start;const caf::SRVector3DProxy &stop=shwlid.stop;return(std::min(start.X(), stop.X()) >-150 && std::max(start.X(), stop.X())< +150 && std::min(start.Y(), stop.Y()) >-150 && std::max(start.Y(), stop.Y())< +150 && std::min(start.Z(), stop.Z()) > 50 && std::max(start.Z(), stop.Z())< 1230);})
virtual void SetRho(double rho)=0
Collaborates with Spectrum and OscillatableSpectrum to fill spectra from CAF files.
virtual void SetTh23(const T &th23)=0
Both neutrinos and antineutrinos.
static Binning Simple(int n, double lo, double hi, const std::vector< std::string > &labels={})
void SetShift(const ISyst *syst, double shift, bool force=false)
static NullLoader kNullLoader
Dummy loader that doesn't load any files.
virtual void SetTh12(const T &th12)=0
virtual Spectrum NCTotalComponent() const override
virtual void SetdCP(const T &dCP)=0
Compare a single data spectrum to the MC + cosmics expectation.