Jpp  master_rocky-40-g5f0272dcd
the software that should make you happy
Public Member Functions | Public Attributes | Protected Attributes | List of all members
JMARKOV::JPMTTarget Class Reference

Implementation of the JTargetModel class that represents a single PMT on a DOM. More...

#include <JScatteringModel.hh>

Inheritance diagram for JMARKOV::JPMTTarget:
JMARKOV::JTargetModel

Public Member Functions

 JPMTTarget (JAxis3D _axis, double _alpha, double _r=0.2159)
 Constructor. More...
 
double getOpeningAngle () const
 return the PMT opening angle in radians More...
 
double getEfficiency (JVersor3D dir) const
 Return the efficiency, which is defined as the probability that a photon with the given direction hitting the target will be registered. More...
 
double getEffectiveArea () const
 
virtual double getEffectiveArea ()
 Return the effective area, i.e. More...
 
void setRadius (double _r)
 
double getRadius () const
 
void setPosition (JPosition3D &_pos)
 
const JPosition3DgetPosition () const
 
void setDirection (JVersor3D &_dir)
 
const JVersor3DgetDirection () const
 

Public Attributes

double ctmin
 

Protected Attributes

double alpha
 
double r
 
JAxis3D axis
 

Detailed Description

Implementation of the JTargetModel class that represents a single PMT on a DOM.

Definition at line 320 of file JScatteringModel.hh.

Constructor & Destructor Documentation

◆ JPMTTarget()

JMARKOV::JPMTTarget::JPMTTarget ( JAxis3D  _axis,
double  _alpha,
double  _r = 0.2159 
)
inline

Constructor.

_r is DOM radius, default = 0.2159 [m] (=17 inch diameter glass sphere)

_alpha is the opening angle in radians

Definition at line 330 of file JScatteringModel.hh.

330  {
331  setRadius(_r) ;
332  axis = _axis ;
333  alpha = _alpha ;
334 
335  // minimal dot product of PMT direction vs hit direction on DOM
336  ctmin = cos(0.5*_alpha) ;
337  }
void setRadius(double _r)

Member Function Documentation

◆ getOpeningAngle()

double JMARKOV::JPMTTarget::getOpeningAngle ( ) const
inline

return the PMT opening angle in radians

Definition at line 340 of file JScatteringModel.hh.

340 { return alpha ; }

◆ getEfficiency()

double JMARKOV::JPMTTarget::getEfficiency ( JVersor3D  dir) const
inlinevirtual

Return the efficiency, which is defined as the probability that a photon with the given direction hitting the target will be registered.

Note that we assume by convention that the direction is the PHOTON direction, NOT the direction that you would see the photon coming from!

By convention the highest efficiency is 1.

Implements JMARKOV::JTargetModel.

Definition at line 342 of file JScatteringModel.hh.

342  {
343  const double ct = axis.getDirection().getDot(dir) ;
344  if( ct > ctmin ) {
345  return 1.0 ;
346  } else {
347  return 0.0 ;
348  }
349  }
const JDirection3D & getDirection() const
Get direction.
double getDot(const JAngle3D &angle) const
Get dot product.

◆ getEffectiveArea() [1/2]

double JMARKOV::JPMTTarget::getEffectiveArea ( ) const
inline

Definition at line 351 of file JScatteringModel.hh.

351  {
352  return 2.0*r*r*M_PI*(1-ctmin) ;
353  }

◆ getEffectiveArea() [2/2]

virtual double JMARKOV::JTargetModel::getEffectiveArea ( )
inlinevirtualinherited

Return the effective area, i.e.

the integral over the whole surface of the target, weighted by the efficiency.

Definition at line 296 of file JScatteringModel.hh.

296 { return 0.0 ; }

◆ setRadius()

void JMARKOV::JTargetModel::setRadius ( double  _r)
inlineinherited

Definition at line 299 of file JScatteringModel.hh.

299 { r = _r ; }

◆ getRadius()

double JMARKOV::JTargetModel::getRadius ( ) const
inlineinherited

Definition at line 302 of file JScatteringModel.hh.

302 { return r ; }

◆ setPosition()

void JMARKOV::JTargetModel::setPosition ( JPosition3D _pos)
inlineinherited

Definition at line 304 of file JScatteringModel.hh.

304 { axis = JAxis3D(_pos,axis.getDirection()) ; }
Axis object.
Definition: JAxis3D.hh:41

◆ getPosition()

const JPosition3D& JMARKOV::JTargetModel::getPosition ( ) const
inlineinherited

Definition at line 305 of file JScatteringModel.hh.

305 { return axis.getPosition() ; }
const JPosition3D & getPosition() const
Get position.
Definition: JPosition3D.hh:130

◆ setDirection()

void JMARKOV::JTargetModel::setDirection ( JVersor3D _dir)
inlineinherited

Definition at line 307 of file JScatteringModel.hh.

307 { axis = JAxis3D(axis.getPosition(),_dir) ; }

◆ getDirection()

const JVersor3D& JMARKOV::JTargetModel::getDirection ( ) const
inlineinherited

Definition at line 308 of file JScatteringModel.hh.

308 { return axis.getDirection() ; }

Member Data Documentation

◆ ctmin

double JMARKOV::JPMTTarget::ctmin

Definition at line 355 of file JScatteringModel.hh.

◆ alpha

double JMARKOV::JPMTTarget::alpha
protected

Definition at line 359 of file JScatteringModel.hh.

◆ r

double JMARKOV::JTargetModel::r
protectedinherited

Definition at line 312 of file JScatteringModel.hh.

◆ axis

JAxis3D JMARKOV::JTargetModel::axis
protectedinherited

Definition at line 313 of file JScatteringModel.hh.


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