PremModel.cxx
//......................................................................
///
/// Get the cosTheta for a given total baseline.
///
/// Given a baseline, find the direction of the neutrino.
/// This could be useful for experiments with fixed baselines for example.
///
/// The baseline must be within the range of possible values in this
/// earth model. Will return vertical neutrinos otherwise.
///
/// @param L - The total baseline of the neutrino
///
Get the cosTheta for a given total baseline.

Given a baseline, find the direction of the neutrino.
This could be useful for experiments with fixed baselines for example.

The baseline must be within the range of possible values in this
earth model. Will return vertical neutrinos otherwise.
Get the cosTheta for a given total baseline . Given a baseline find the direction of the neutrino . This could be useful for experiments with fixed baselines for example . The baseline must be within the range of possible values in this earth model . Will return vertical neutrinos otherwise .
double PremModel::GetCosT(double L)
{
  double rAbove = fPremLayers.back().radius;     
  double rBelow = fPremLayers[fDetLayer].radius; 
  if(L < rAbove - rBelow) return  1;
  if(L > rAbove + rBelow) return -1;
  return (rAbove*rAbove - rBelow*rBelow - L*L) / (2*rBelow*L);
}
double PremModel :: GetCosT ( double L ) { double rAbove = fPremLayers . back ( ) . radius ; double rBelow = fPremLayers [ fDetLayer ] . radius ; if ( L < rAbove - rBelow ) return 1 ; if ( L > rAbove + rBelow ) return -1 ; return ( rAbove * rAbove - rBelow * rBelow - L * L ) / ( 2 * rBelow * L ) ; }
......................................................................
Get the cosTheta for a given total baseline.
...................................................................... Get the cosTheta for a given total baseline .
// Radius above detector // Radius below detector