Public Member Functions | Protected Member Functions | List of all members
osc::OscCalcDumb Class Reference

Simple oscillation probability calculator that has no solar term or mass hierarchy or delta so it's some kind of average of all of those. More...

#include "/cvmfs/nova.opensciencegrid.org/externals/osclib/v00.07/src/OscLib/OscCalcDumb.h"

Inheritance diagram for osc::OscCalcDumb:
osc::_IOscCalc< T >

Public Member Functions

virtual IOscCalcCopy () const override
 
virtual double P (int flavBefore, int flavAfter, double E) override
 E in GeV; flavors as PDG codes (so, neg==>antinu) More...
 
virtual Eigen::Array< T, Eigen::Dynamic, 1 > P (int flavBefore, int flavAfter, const std::vector< double > &E)
 
virtual Eigen::Array< T, Eigen::Dynamic, 1 > P (int flavBefore, int flavAfter, const Eigen::ArrayXd &E)
 
virtual TMD5 * GetParamsHash () const
 Use to check two calculators are in the same state. More...
 

Protected Member Functions

template<class T >
T sqr (T x) const
 

Detailed Description

Simple oscillation probability calculator that has no solar term or mass hierarchy or delta so it's some kind of average of all of those.

Definition at line 16 of file OscCalcDumb.h.

Member Function Documentation

virtual IOscCalc* osc::OscCalcDumb::Copy ( ) const
inlineoverridevirtual
template<typename T>
virtual TMD5* osc::_IOscCalc< T >::GetParamsHash ( ) const
inlinevirtualinherited
virtual double osc::OscCalcDumb::P ( int  flavBefore,
int  flavAfter,
double  E 
)
inlineoverridevirtual

E in GeV; flavors as PDG codes (so, neg==>antinu)

Implements osc::_IOscCalc< T >.

Definition at line 21 of file OscCalcDumb.h.

References abs(), CLHEP::L, std::sin(), sqr(), and ssth23.

Referenced by DrawCCOscillations(), ana::CovMxSurface::DrawSurfacePoint(), NuMu2020_TrimCAFs(), prob_biprob_pedagogical(), and caf::CAFMaker::SimpleOscProb().

22  {
23  const double L = 810.; // km
24  const double ldm = 2.40e-3; // large delta m^2, m23
25  const double ss2t13 = 0.1; // sin^2(2theta_13)
26  const double ss2t23 = 1.; // maximal sin^2(2theta_23)
27  const double ssth23 = 0.5; // sin^2(theta_23) corresponding to above
28 
29  // Signal
30  if(abs(flavAfter) == 12 && abs(flavBefore) == 14){
31  // Nue appearance
32  return ss2t13*ssth23*sqr(sin(1.267*ldm*L/E));
33  }
34  if(abs(flavAfter) == 14 && abs(flavBefore) == 14){
35  // CC mu disappearance
36  return 1-ss2t23*sqr(sin(1.267*ldm*L/E));
37  }
38 
39  // Background
40  if(abs(flavAfter) == 12 && abs(flavBefore) == 12){
41  // Beam nue
42  return 1-ss2t13*sqr(sin(1.267*ldm*L/E));
43  }
44  if(abs(flavAfter) == 14 && abs(flavBefore) == 12){
45  // CC mu appearance
46  return ss2t13*ssth23*sqr(sin(1.267*ldm*L/E));
47  }
48  if(abs(flavAfter) == 16 && abs(flavBefore) == 14){
49  //numu to nutau CC appearance
50  return (1-ss2t13)*ss2t23*sqr(sin(1.267*ldm*L/E));
51  }
52  if(abs(flavAfter) == 16 && abs(flavBefore) == 12){
53  //nue to nutau CC appearance
54  return ss2t13*(1-ssth23)*sqr(sin(1.267*ldm*L/E));
55  }
56  if(abs(flavAfter) == 16 && abs(flavBefore) == 16){
57  //nutau to nutau CC disappearance
58  return 1-(ss2t23-ss2t23*ss2t13+ss2t13-ss2t13*ssth23)*sqr(sin(1.267*ldm*L/E));
59  }
60 
61  // Don't know what this is
62  return 0;
63  }
double ssth23
void abs(TH1 *hist)
static constexpr double L
Float_t E
Definition: plot.C:20
T sin(T number)
Definition: d0nt_math.hpp:132
T sqr(T x) const
Definition: OscCalcDumb.h:66
template<class T >
Eigen::Array< T, Eigen::Dynamic, 1 > osc::_IOscCalc< T >::P ( int  flavBefore,
int  flavAfter,
const std::vector< double > &  E 
)
virtualinherited

Default implementation forwards to non-vector version using a simple loop. Override if your calculator has a more efficient implementation.

Reimplemented in osc::analytic::_OscCalc< T >, osc::OscCalcPMNSOptEigen, and osc::_OscCalcDMP< T >.

Definition at line 27 of file IOscCalc.cxx.

References MECModelEnuComparisons::i, osc::_IOscCalc< T >::P(), runNovaSAM::ret, and submit_hadd::u.

Referenced by osc::_IOscCalc< T >::P().

28  {
29  Eigen::Matrix<T,Eigen::Dynamic,1> ret(E.size());
30  for(auto i = 0u; i < E.size(); i++) {
31  ret(i) = this->P(flavBefore, flavAfter, E[i]);
32  }
33  return ret.array().isNaN().select(0, ret);
34  }
Float_t E
Definition: plot.C:20
virtual T P(int flavBefore, int flavAfter, double E)=0
E in GeV; flavors as PDG codes (so, neg==>antinu)
template<class T >
Eigen::Array< T, Eigen::Dynamic, 1 > osc::_IOscCalc< T >::P ( int  flavBefore,
int  flavAfter,
const Eigen::ArrayXd &  E 
)
virtualinherited

Default implementation forawrds to vector<double> version. Override if your calculator has a more efficient implementation.

Reimplemented in osc::analytic::_OscCalc< T >.

Definition at line 37 of file IOscCalc.cxx.

References P.

38  {
39  return P(flavBefore, flavAfter, std::vector<double>(&E[0], &E[0]+E.size()));
40  }
Float_t E
Definition: plot.C:20
virtual T P(int flavBefore, int flavAfter, double E)=0
E in GeV; flavors as PDG codes (so, neg==>antinu)
template<class T >
T osc::OscCalcDumb::sqr ( T  x) const
inlineprotected

Definition at line 66 of file OscCalcDumb.h.

References submit_syst::x.

Referenced by P().

66 {return x*x;}

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