Public Member Functions | Protected Member Functions | List of all members
FitSinSqTheta23MaxMix Class Reference

#include "/cvmfs/nova-development.opensciencegrid.org/novasoft/releases/N21-01-18/3FlavorAna/Ana2018/nue/reach/sensitivity_tools.h"

Inheritance diagram for FitSinSqTheta23MaxMix:
ana::IConstrainedFitVar ana::IConstrainedFitVar ana::IFitVar ana::IFitVar

Public Member Functions

virtual double GetValue (const osc::IOscCalcAdjustable *osc) const
 
virtual void SetValue (osc::IOscCalcAdjustable *osc, double val) const
 
virtual std::string ShortName () const
 
virtual std::string LatexName () const
 
virtual double LowLimit () const
 
virtual double HighLimit () const
 
virtual double GetValue (const osc::IOscCalcAdjustable *osc) const
 
virtual void SetValue (osc::IOscCalcAdjustable *osc, double val) const
 
virtual std::string ShortName () const
 
virtual std::string LatexName () const
 
virtual double LowLimit () const
 
virtual double HighLimit () const
 
double Penalty (double val, osc::IOscCalcAdjustable *) const override
 Override the default implementation with one that pushes back towards the center of the constrained space. More...
 

Protected Member Functions

template<typename T >
T Clamp (T val) const
 

Detailed Description

Definition at line 247 of file reach_2018_dCPfractions.C.

Member Function Documentation

template<typename T >
T ana::IConstrainedFitVar::Clamp ( T  val) const
inlineprotectedinherited
virtual double FitSinSqTheta23MaxMix::GetValue ( const osc::IOscCalcAdjustable osc) const
inlinevirtual

Implements ana::IFitVar.

Definition at line 250 of file reach_2018_dCPfractions.C.

References osc::_IOscCalcAdjustable< T >::GetTh23(), std::sin(), and util::sqr().

250  {
251  return util::sqr(sin(osc->GetTh23()));};
virtual T GetTh23() const
Definition: IOscCalc.h:94
T sqr(T x)
More efficient square function than pow(x,2)
Definition: MathUtil.h:23
T sin(T number)
Definition: d0nt_math.hpp:132
virtual double FitSinSqTheta23MaxMix::GetValue ( const osc::IOscCalcAdjustable osc) const
inlinevirtual

Implements ana::IFitVar.

Definition at line 361 of file sensitivity_tools.h.

References osc::_IOscCalcAdjustable< T >::GetTh23(), std::sin(), and util::sqr().

361  {
362  return util::sqr(sin(osc->GetTh23()));};
virtual T GetTh23() const
Definition: IOscCalc.h:94
T sqr(T x)
More efficient square function than pow(x,2)
Definition: MathUtil.h:23
T sin(T number)
Definition: d0nt_math.hpp:132
virtual double FitSinSqTheta23MaxMix::HighLimit ( ) const
inlinevirtual

Implements ana::IConstrainedFitVar.

Definition at line 257 of file reach_2018_dCPfractions.C.

257 {return 0.51;}
virtual double FitSinSqTheta23MaxMix::HighLimit ( ) const
inlinevirtual

Implements ana::IConstrainedFitVar.

Definition at line 368 of file sensitivity_tools.h.

368 {return 0.51;}
virtual std::string FitSinSqTheta23MaxMix::LatexName ( ) const
inlinevirtual

Definition at line 255 of file reach_2018_dCPfractions.C.

255 {return "sin^{2}#theta_{23} MaxMix";}
virtual std::string FitSinSqTheta23MaxMix::LatexName ( ) const
inlinevirtual

Definition at line 366 of file sensitivity_tools.h.

366 {return "sin^{2}#theta_{23} MaxMix";}
virtual double FitSinSqTheta23MaxMix::LowLimit ( ) const
inlinevirtual

Implements ana::IConstrainedFitVar.

Definition at line 256 of file reach_2018_dCPfractions.C.

256 {return 0.49;}
virtual double FitSinSqTheta23MaxMix::LowLimit ( ) const
inlinevirtual

Implements ana::IConstrainedFitVar.

Definition at line 367 of file sensitivity_tools.h.

367 {return 0.49;}
double ana::IConstrainedFitVar::Penalty ( double  val,
osc::IOscCalcAdjustable  
) const
overridevirtualinherited

Override the default implementation with one that pushes back towards the center of the constrained space.

Reimplemented from ana::IFitVar.

Definition at line 8 of file IFitVar.cxx.

References hi(), ana::IConstrainedFitVar::HighLimit(), lo(), ana::IConstrainedFitVar::LowLimit(), extractScale::mean, Munits::rad, and util::sqr().

Referenced by ana::SigmaDelta::SigmaPenalty().

10  {
11  const auto lo = LowLimit();
12  const auto hi = HighLimit();
13 
14  if (val >= lo && val <= hi) return 0;
15 
16  // Try to direct fit back towards centre of the space. Engineer penalty to
17  // be zero at the limits.
18  const auto mean = (lo + hi) / 2;
19  const auto rad = (hi - lo) / 2;
20  return util::sqr((val - mean) / rad) - 1;
21 
22 
23  // if(val < lo) return util::sqr(lo-val);
24  // if(val > hi) return util::sqr(val-hi);
25  // return 0;
26  }
virtual double HighLimit() const =0
TSpline3 lo("lo", xlo, ylo, 12,"0")
virtual double LowLimit() const =0
T sqr(T x)
More efficient square function than pow(x,2)
Definition: MathUtil.h:23
TSpline3 hi("hi", xhi, yhi, 18,"0")
static constexpr Double_t rad
Definition: Munits.h:162
virtual void FitSinSqTheta23MaxMix::SetValue ( osc::IOscCalcAdjustable osc,
double  val 
) const
inlinevirtual

Implements ana::IFitVar.

Definition at line 252 of file reach_2018_dCPfractions.C.

References std::asin(), lem::Clamp(), osc::_IOscCalcAdjustable< T >::SetTh23(), and std::sqrt().

252  {
253  osc->SetTh23(asin(sqrt(Clamp(val))));};
T sqrt(T number)
Definition: d0nt_math.hpp:156
T Clamp(T val) const
Definition: IFitVar.h:60
virtual void SetTh23(const T &th23)=0
T asin(T number)
Definition: d0nt_math.hpp:60
virtual void FitSinSqTheta23MaxMix::SetValue ( osc::IOscCalcAdjustable osc,
double  val 
) const
inlinevirtual

Implements ana::IFitVar.

Definition at line 363 of file sensitivity_tools.h.

References std::asin(), ana::IConstrainedFitVar::Clamp(), osc::_IOscCalcAdjustable< T >::SetTh23(), and std::sqrt().

363  {
364  osc->SetTh23(asin(sqrt(Clamp(val))));};
T sqrt(T number)
Definition: d0nt_math.hpp:156
T Clamp(T val) const
Definition: IFitVar.h:60
virtual void SetTh23(const T &th23)=0
T asin(T number)
Definition: d0nt_math.hpp:60
virtual std::string FitSinSqTheta23MaxMix::ShortName ( ) const
inlinevirtual

Definition at line 254 of file reach_2018_dCPfractions.C.

254 {return "ssth23MaxMix";}
virtual std::string FitSinSqTheta23MaxMix::ShortName ( ) const
inlinevirtual

Definition at line 365 of file sensitivity_tools.h.

365 {return "ssth23MaxMix";}

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