Jpp  18.0.0-rc.3
the software that should make you happy
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Protected Attributes | List of all members
JMARKOV::JCosineTarget Class Reference

Implementation of the JTargetModel class that represents a directed target with a cos(theta) acceptance. More...

#include <JScatteringModel.hh>

Inheritance diagram for JMARKOV::JCosineTarget:
JMARKOV::JTargetModel

Public Member Functions

 JCosineTarget (JVersor3D _target_dir)
 Constructor. 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...
 
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
 

Protected Attributes

JVersor3D target_dir
 
double r
 
JAxis3D axis
 

Detailed Description

Implementation of the JTargetModel class that represents a directed target with a cos(theta) acceptance.

Definition at line 377 of file JScatteringModel.hh.

Constructor & Destructor Documentation

JMARKOV::JCosineTarget::JCosineTarget ( JVersor3D  _target_dir)
inline

Constructor.

_target_dir is the direction where the photon has the highest chance to be detected.

Definition at line 385 of file JScatteringModel.hh.

385  :
386  target_dir(_target_dir) {}

Member Function Documentation

double JMARKOV::JCosineTarget::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 388 of file JScatteringModel.hh.

388  {
389  return max( dir.getDot(target_dir), 0.0 ) ;
390  }
double getDot(const JVersor3D &versor) const
Get dot product.
Definition: JVersor3D.hh:156
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 295 of file JScatteringModel.hh.

295 { return 0.0 ; }
void JMARKOV::JTargetModel::setRadius ( double  _r)
inlineinherited

Definition at line 298 of file JScatteringModel.hh.

298 { r = _r ; }
double JMARKOV::JTargetModel::getRadius ( ) const
inlineinherited

Definition at line 301 of file JScatteringModel.hh.

301 { return r ; }
void JMARKOV::JTargetModel::setPosition ( JPosition3D _pos)
inlineinherited

Definition at line 303 of file JScatteringModel.hh.

303 { axis = JAxis3D(_pos,axis.getDirection()) ; }
const JDirection3D & getDirection() const
Get direction.
Axis object.
Definition: JAxis3D.hh:38
const JPosition3D& JMARKOV::JTargetModel::getPosition ( ) const
inlineinherited

Definition at line 304 of file JScatteringModel.hh.

304 { return axis.getPosition() ; }
const JPosition3D & getPosition() const
Get position.
Definition: JPosition3D.hh:130
void JMARKOV::JTargetModel::setDirection ( JVersor3D _dir)
inlineinherited

Definition at line 306 of file JScatteringModel.hh.

306 { axis = JAxis3D(axis.getPosition(),_dir) ; }
Axis object.
Definition: JAxis3D.hh:38
const JPosition3D & getPosition() const
Get position.
Definition: JPosition3D.hh:130
const JVersor3D& JMARKOV::JTargetModel::getDirection ( ) const
inlineinherited

Definition at line 307 of file JScatteringModel.hh.

307 { return axis.getDirection() ; }
const JDirection3D & getDirection() const
Get direction.

Member Data Documentation

JVersor3D JMARKOV::JCosineTarget::target_dir
protected

Definition at line 394 of file JScatteringModel.hh.

double JMARKOV::JTargetModel::r
protectedinherited

Definition at line 311 of file JScatteringModel.hh.

JAxis3D JMARKOV::JTargetModel::axis
protectedinherited

Definition at line 312 of file JScatteringModel.hh.


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