BeamNueCuts.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include "CAFAna/Core/Cut.h"
9 
10 namespace ana {
11 
12  //Cuts for nue from K+ estimation
13  //From Kuldeep K. Mann. See e.g. docid=14999
14  extern const Cut kBENKaNumuFiducial;
15 
16  extern const Cut kBENKaNumuContain;
17 
18  const Cut kBENKaNumuCut = kNumuBasicQuality && kBENKaNumuFiducial && !kBENKaNumuContain && kNumuNCRej;
19 
20 
21  // decaf cuts for BEN
23  const Cut kNumuUncontainNDDecafCut = kNumuBasicQuality && kBENKaNumuFiducial && (!kNumuContainND2020 || !kNumuContainND || !kBENKaNumuContain) && (kNumuNCRej || kNumu2020PID);
24 
25  // Cuts for nue from Pi+ estimation
26  extern const Cut kNumuHadSel;
27 
29 
30  //Truth cuts:
31  extern const Cut kParentIsPiPlus;
32  extern const Cut kParentIsKaPlus;
33  extern const Cut kParentIsMuPlus;
34 
35  extern const Cut kIsNumuFromKaDecay;
36  extern const Cut kIsNumuFromPiDecay;
37  extern const Cut kIsNueFromKaDecay;
38  extern const Cut kIsNueFromPiDecay;
39 
40  extern const Cut kBENLowTrueECut;
41 
46 
51 
56 
61 
62 
69  kNueNDEnergyExtend &&
71  const Cut kNueNDExtend = kNueNDPreselExtend && kNue2018CVNCut;
72 }
const Cut kIsNumuCC(CCFlavSel(14, 14))
Select CC .
const Cut kIsNumuCCNotFromKaDk
Definition: BeamNueCuts.h:48
const Cut kIsNueFromKaDecay([](const caf::SRProxy *sr){if(sr->mc.nnu==0) return false;assert(sr->mc.nnu==1);return(( sr->mc.nu[0].beam.tptype==321)|| sr->mc.nu[0].beam.tptype==130);})
Definition: BeamNueCuts.h:37
Cuts and Vars for the 2020 FD DiF Study.
Definition: vars.h:6
const Cut kBENKaNumuCut
Definition: BeamNueCuts.h:18
const Cut kIsNueCCFromPiDk
Definition: BeamNueCuts.h:44
const Cut kIsNumuCCFromKa
Definition: BeamNueCuts.h:57
const Cut kNumu2020ND
Definition: NumuCuts2020.h:57
const Cut kIsNueCCNotFromPi
Definition: BeamNueCuts.h:55
const Cut kIsNumuCCFromPi
Definition: BeamNueCuts.h:52
const Cut kIsAntiNu([](const caf::SRProxy *sr){if(sr->mc.nnu==0) return false;assert(sr->mc.nnu==1);return sr->mc.nu[0].pdg< 0;})
Is this truly an antineutrino?
Definition: TruthCuts.h:53
const Cut kNueDQ2017CVN([](const caf::SRProxy *sr){if(sr->sel.nuecosrej.hitsperplane >=8) return false;if(!sr->vtx.elastic.IsValid) return false;if(sr->vtx.elastic.fuzzyk.npng==0) return false;return true;})
Definition: NueCuts2017.h:28
const Cut kIsBeamNue(CCFlavSel(12, 12))
Select CC .
const Cut kIsNumuCCNotFromPi
Definition: BeamNueCuts.h:53
const Cut kNue2018CVNCut([](const caf::SRProxy *sr){if(kIsRHC(sr)) return kNue2018RHCCVNCut(sr);else return kNue2018FHCCVNCut(sr);})
Definition: NueCuts2018.h:49
const Cut kNue2017NDProngLength
Definition: NueCuts2017.h:277
const Cut kNueNDPreselExtend
Definition: BeamNueCuts.h:64
const Cut kNumuContainND([](const caf::SRProxy *sr){return( sr->trk.kalman.ntracks > sr->trk.kalman.idxremid &&sr->slc.ncellsfromedge > 1 &&sr->slc.firstplane > 1 &&sr->slc.lastplane< 212 &&sr->trk.kalman.tracks[0].start.Z()< 1150 &&( sr->trk.kalman.tracks[0].stop.Z()< 1275 ||sr->sel.contain.kalyposattrans< 55) &&( sr->energy.numu.ndhadcalcatE +sr->energy.numu.ndhadcaltranE)< 0.03 &&sr->sel.contain.kalfwdcellnd > 4 &&sr->sel.contain.kalbakcellnd > 8);})
Definition: NumuCuts.h:22
const Cut kIsNueFromPiDecay([](const caf::SRProxy *sr){if(sr->mc.nnu==0) return false;assert(sr->mc.nnu==1);return(sr->mc.nu[0].beam.ndecay==11 && (sr->mc.nu[0].beam.tptype==211|| sr->mc.nu[0].beam.tptype==3122|| sr->mc.nu[0].beam.tptype==3222) );})
Definition: BeamNueCuts.h:38
const Cut kNumu2020PID([](const caf::SRProxy *sr){return(sr->sel.remid.pid > 0.30 && sr->sel.cvnloosepreselptp.numuid > 0.80);})
Definition: NumuCuts2020.h:21
const Cut kIsNumuCCNotFromPiDk
Definition: BeamNueCuts.h:43
const Cut kNue2017NDNHits
Definition: NueCuts2017.h:265
const Var kNueEnergy2018([](const caf::SRProxy *sr){if(!sr->vtx.elastic.IsValid) return-1.0;if(sr->vtx.elastic.fuzzyk.npng< 1) return-1.0;if(kIsRHC(sr)) return kNueEnergyRHC(sr);else return kNueEnergyFHC(sr);})
Definition: NueEnergy2018.h:25
const Cut kIsNueCCFromKaDk
Definition: BeamNueCuts.h:49
const Cut kNueNDEnergyExtend
Definition: BeamNueCuts.h:63
const Cut kBENLowTrueECut([](const caf::SRProxy *sr){return(sr->mc.nnu==0)?false:sr->mc.nu[0].E< 4;})
Definition: BeamNueCuts.h:40
const Cut kBENPiNumuCut
Definition: BeamNueCuts.h:28
const Cut kNue2017NDFrontPlanes
No hits in the first 5 planes of the detector, doc 12879.
const Cut kIsNumuCCNotFromKa
Definition: BeamNueCuts.h:58
const Cut kIsNueCCNotFromKa
Definition: BeamNueCuts.h:60
const Cut kNumuNCRej([](const caf::SRProxy *sr){return(sr->sel.remid.pid >0.75);})
Definition: NumuCuts.h:24
const Cut kIsNumuCCFromPiDk
Definition: BeamNueCuts.h:42
const Cut kIsNumuFromKaDecay([](const caf::SRProxy *sr){if(sr->mc.nnu==0) return false;assert(sr->mc.nnu==1);return((sr->mc.nu[0].beam.ndecay==5|| sr->mc.nu[0].beam.ndecay==7)&& sr->mc.nu[0].beam.tptype==321);})
Definition: BeamNueCuts.h:35
const Cut kNumuUncontainNDDecafCut
Definition: BeamNueCuts.h:23
const Cut kIsNueCCFromKa
Definition: BeamNueCuts.h:59
const Cut kNumuBasicQuality([](const caf::SRProxy *sr){return(sr->energy.numu.trkccE > 0 && sr->sel.remid.pid > 0 && sr->slc.nhit > 20 && sr->slc.ncontplanes > 4 && sr->trk.cosmic.ntracks > 0);})
Definition: NumuCuts.h:14
const Cut kBENKaNumuFiducial([](const caf::SRProxy *sr){if(!sr->vtx.elastic.IsValid) return false;if(sr->trk.kalman.ntracks<=0) return false;return(sr->vtx.elastic.vtx.X() >-170 && sr->vtx.elastic.vtx.X()< 170 && sr->vtx.elastic.vtx.Y() >-170 && sr->vtx.elastic.vtx.Y()< 170 && sr->vtx.elastic.vtx.Z() > 30 && sr->vtx.elastic.vtx.Z()< 1150 && sr->trk.kalman.tracks[0].start.X() >-170 && sr->trk.kalman.tracks[0].start.X()< 170 && sr->trk.kalman.tracks[0].start.Y() >-170 && sr->trk.kalman.tracks[0].start.Y()< 170 && sr->trk.kalman.tracks[0].start.Z() > 30 && sr->trk.kalman.tracks[0].start.Z()< 1150 );})
Definition: BeamNueCuts.h:14
const Cut kParentIsPiPlus([](const caf::SRProxy *sr){return(sr->mc.nu[0].beam.ptype==211);})
Definition: BeamNueCuts.h:31
const Cut kNumuHadSel([](const caf::SRProxy *sr){std::cout<< "WARNING! Attempting to access kNumuHadSel which relies on qepid (which no longer exists.) Aborting..."<< std::endl;abort(); return false;})
Definition: BeamNueCuts.h:26
const Cut kNue2017NDContain([](const caf::SRProxy *sr){for(unsigned int ix=0;ix< sr->vtx.elastic.fuzzyk.nshwlid;++ix){TVector3 start=sr->vtx.elastic.fuzzyk.png[ix].shwlid.start;TVector3 stop=sr->vtx.elastic.fuzzyk.png[ix].shwlid.stop;if(std::min(start.X(), stop.X())< -170.0) return false;if(std::max(start.X(), stop.X()) > 170.0) return false;if(std::min(start.Y(), stop.Y())< -170.0) return false;if(std::max(start.Y(), stop.Y()) > 170.0) return false;if(std::min(start.Z(), stop.Z())< 100.0) return false;if(std::max(start.Z(), stop.Z()) > 1225.0) return false;}return true;})
Loose containtment on start and end of all showers, docdb-12943.
Definition: NueCuts2017.h:259
const Cut kIsNueCCNotFromKaDk
Definition: BeamNueCuts.h:50
const Cut kIsNueCCFromPi
Definition: BeamNueCuts.h:54
const Cut kBENKaNumuContain([](const caf::SRProxy *sr){if(sr->trk.kalman.ntracks<=0) return false;return( sr->trk.kalman.tracks[0].stop.X() >-185 && sr->trk.kalman.tracks[0].stop.X()< 185 && sr->trk.kalman.tracks[0].stop.Y() >-185 && sr->trk.kalman.tracks[0].stop.Y()< 185 && sr->trk.kalman.tracks[0].stop.Z() > 19 && sr->trk.kalman.tracks[0].stop.Z()< 1275 );})
Definition: BeamNueCuts.h:16
Template for Cut and SpillCut.
Definition: Cut.h:15
const Cut kIsNumuCCFromKaDk
Definition: BeamNueCuts.h:47
const Cut kNumuContainND2020([](const caf::SRProxy *sr){if(!sr->vtx.elastic.IsValid) return false;for(unsigned int i=0;i< sr->vtx.elastic.fuzzyk.nshwlid;++i){const caf::SRVector3DProxy &start=sr->vtx.elastic.fuzzyk.png[i].shwlid.start;const caf::SRVector3DProxy &stop=sr->vtx.elastic.fuzzyk.png[i].shwlid.stop;if(std::min(start.X(), stop.X())< -180.0) return false;if(std::max(start.X(), stop.X()) > 180.0) return false;if(std::min(start.Y(), stop.Y())< -180.0) return false;if(std::max(start.Y(), stop.Y()) > 180.0) return false;if(std::min(start.Z(), stop.Z())< 40.0) return false;if(std::max(start.Z(), stop.Z()) > 1525.0) return false;}if(sr->trk.kalman.ntracks< 1) return false;for(unsigned int i=0;i< sr->trk.kalman.ntracks;++i){if(i==sr->trk.kalman.idxremid) continue;else if(sr->trk.kalman.tracks[i].start.Z() > 1275||sr->trk.kalman.tracks[i].stop.Z() > 1275) return false;}return(sr->trk.kalman.ntracks > sr->trk.kalman.idxremid &&sr->slc.firstplane > 1 &&sr->slc.lastplane< 212 &&sr->trk.kalman.tracks[0].start.Z()< 1100 &&(sr->trk.kalman.tracks[0].stop.Z()< 1275 ||sr->sel.contain.kalyposattrans< 55) &&sr->sel.contain.kalfwdcellnd > 5 &&sr->sel.contain.kalbakcellnd > 10);})
Definition: NumuCuts2020.h:31
const Cut kParentIsKaPlus([](const caf::SRProxy *sr){return(sr->mc.nu[0].beam.ptype==321);})
Definition: BeamNueCuts.h:32
const Cut kIsNumuFromPiDecay([](const caf::SRProxy *sr){if(sr->mc.nnu==0) return false;assert(sr->mc.nnu==1);return(sr->mc.nu[0].beam.ndecay==13 && sr->mc.nu[0].beam.tptype==211);})
Definition: BeamNueCuts.h:36
const Cut kNueNDExtend
Definition: BeamNueCuts.h:71
const Cut kIsNueCCNotFromPiDk
Definition: BeamNueCuts.h:45
const Cut kParentIsMuPlus([](const caf::SRProxy *sr){return(sr->mc.nu[0].beam.ptype==13);})
Definition: BeamNueCuts.h:33
const Cut kNumuContainNDDecafCut
Definition: BeamNueCuts.h:22
const Cut kNue2017NDFiducial([](const caf::SRProxy *sr){assert(sr->vtx.elastic.IsValid &&"Must apply DQ cuts");if(sr->vtx.elastic.vtx.X()< -100.0) return false;if(sr->vtx.elastic.vtx.X() > 160.0) return false;if(sr->vtx.elastic.vtx.Y()< -160.0) return false;if(sr->vtx.elastic.vtx.Y() > 100.0) return false;if(sr->vtx.elastic.vtx.Z()< 150.0) return false;if(sr->vtx.elastic.vtx.Z() > 900.0) return false;return true;})
Cut on ND vertex position.
Definition: NueCuts2017.h:256