GammaLib  2.0.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
cta_nroi_elliptical_kern_rho Class Reference

Kernel for zenith angle Nroi integration of elliptical model. More...

#include <GCTAResponse_helpers.hpp>

Inheritance diagram for cta_nroi_elliptical_kern_rho:
GFunction

Public Member Functions

 cta_nroi_elliptical_kern_rho (const GCTAResponseIrf *rsp, const GCTAObservation *obs, const GModelSpatialElliptical *model, const GMatrix *rot, const double &semimajor, const double &semiminor, const double &posangle, const GEnergy &srcEng, const GTime &srcTime, const GEnergy &obsEng, const GTime &obsTime, const double &rho_roi, const double &posangle_roi, const double &radius_roi, const int &iter)
 
double eval (const double &rho)
 Kernel for zenith angle Nroi integration of elliptical model. More...
 
- Public Member Functions inherited from GFunction
 GFunction (void)
 Void constructor. More...
 
 GFunction (const GFunction &function)
 Copy constructor. More...
 
virtual ~GFunction (void)
 Destructor. More...
 
GFunctionoperator= (const GFunction &function)
 Assignment operator. More...
 

Protected Attributes

const GCTAResponseIrfm_rsp
 CTA response. More...
 
const GCTAObservationm_obs
 CTA observation. More...
 
const GModelSpatialEllipticalm_model
 Elliptical model. More...
 
const GMatrixm_rot
 Rotation matrix. More...
 
double m_semimajor
 Ellipse boundary semimajor axis. More...
 
double m_semiminor
 Ellipse boundary semiminor axis. More...
 
double m_posangle
 Ellipse boundary position angle. More...
 
GEnergy m_srcEng
 True photon energy. More...
 
GTime m_srcTime
 True photon arrival time. More...
 
GEnergy m_obsEng
 Observed photon energy. More...
 
GTime m_obsTime
 Observed photon arrival time. More...
 
double m_rho_roi
 Distance between model and ROI centre. More...
 
double m_cos_rho_roi
 Cosine of m_rho_roi. More...
 
double m_sin_rho_roi
 Sine of m_rho_roi. More...
 
double m_posangle_roi
 Position angle of ROI. More...
 
double m_radius_roi
 ROI+PSF radius. More...
 
double m_cos_radius_roi
 Cosine of m_radius_roi. More...
 
int m_iter
 Integration iterations. More...
 

Additional Inherited Members

- Protected Member Functions inherited from GFunction
void init_members (void)
 Initialise class members. More...
 
void copy_members (const GFunction &function)
 Copy class members. More...
 
void free_members (void)
 Delete class members. More...
 

Detailed Description

Kernel for zenith angle Nroi integration of elliptical model.

This class implements the integration kernel \(K(\rho)\) for the integration

\[ \int_{\rho_{\rm min}}^{\rho_{\rm max}} K(\rho | E, t) d\rho \]

of elliptical elliptical models. The eval() method computes

\[ K(\rho | E, t) = \sin \rho \times \int_{\omega_{\rm min}}^{\omega_{\rm max}} S_{\rm p}(\rho,\omega | E, t) \, N_{\rm pred}(\rho,\omega) d\omega \]

where

  • \(S_{\rm p}(\rho,\omega | E, t)\) is the elliptical model,
  • \(N_{\rm pred}(\rho,\omega)\) is the data space integral of the Instrument Response Function for a point spread function over the Region Of Interest,
  • \(\rho\) is the distance from the model centre, and
  • \(\omega\) is the azimuth angle is the position angle with respect to the connecting line between the model centre and the observed photon arrival direction.

Definition at line 621 of file GCTAResponse_helpers.hpp.

Constructor & Destructor Documentation

cta_nroi_elliptical_kern_rho::cta_nroi_elliptical_kern_rho ( const GCTAResponseIrf rsp,
const GCTAObservation obs,
const GModelSpatialElliptical model,
const GMatrix rot,
const double &  semimajor,
const double &  semiminor,
const double &  posangle,
const GEnergy srcEng,
const GTime srcTime,
const GEnergy obsEng,
const GTime obsTime,
const double &  rho_roi,
const double &  posangle_roi,
const double &  radius_roi,
const int &  iter 
)
inline

Definition at line 623 of file GCTAResponse_helpers.hpp.

Member Function Documentation

double cta_nroi_elliptical_kern_rho::eval ( const double &  rho)
virtual

Kernel for zenith angle Nroi integration of elliptical model.

Parameters
[in]rhoElliptical model offset angle (radians).

Computes

\[ K(\rho | E, t) = \sin \rho \times \int_{\omega_{\rm min}}^{\omega_{\rm max}} S_{\rm p}(\rho,\omega | E, t) \, N_{\rm pred}(\rho,\omega) d\omega \]

where \(\omega\) is the azimuth angle with respect to the model centre, counted counterclockwise from the vector connecting the model centre to the ROI centre, and \(\rho\) is the radial distance from the model centre. \(S_{\rm p}(\rho, \omega | E, t)\) is the elliptical source model for a given true photon energy and photon arrival time, \(N_{\rm pred}(\rho,\omega)\) is the data space integral over the response function.

The method performs the required coordinate transformations from the model system, spanned by \((\rho, \omega)\), to the system needed for Npred computations. Furthermore, the method limits the integration range to area where the ellipse intersects the ROI.

Implements GFunction.

Definition at line 1018 of file GCTAResponse_helpers.cpp.

References gammalib::acos(), cos(), GIntegral::fixed_iter(), g_ellipse_kludge_radius, gammalib::is_infinite(), gammalib::is_notanumber(), gammalib::limit_omega(), m_cos_radius_roi, m_cos_rho_roi, m_iter, m_model, m_obs, m_obsEng, m_obsTime, m_posangle, m_posangle_roi, m_radius_roi, m_rho_roi, m_rot, m_rsp, m_semimajor, m_semiminor, m_sin_rho_roi, m_srcEng, m_srcTime, max(), min(), gammalib::pi, gammalib::roi_arclength(), GIntegral::romberg(), sin(), and sqrt().

Member Data Documentation

double cta_nroi_elliptical_kern_rho::m_cos_radius_roi
protected

Cosine of m_radius_roi.

Definition at line 674 of file GCTAResponse_helpers.hpp.

Referenced by eval().

double cta_nroi_elliptical_kern_rho::m_cos_rho_roi
protected

Cosine of m_rho_roi.

Definition at line 670 of file GCTAResponse_helpers.hpp.

Referenced by eval().

int cta_nroi_elliptical_kern_rho::m_iter
protected

Integration iterations.

Definition at line 675 of file GCTAResponse_helpers.hpp.

Referenced by eval().

const GModelSpatialElliptical* cta_nroi_elliptical_kern_rho::m_model
protected

Elliptical model.

Definition at line 660 of file GCTAResponse_helpers.hpp.

Referenced by eval().

const GCTAObservation* cta_nroi_elliptical_kern_rho::m_obs
protected

CTA observation.

Definition at line 659 of file GCTAResponse_helpers.hpp.

Referenced by eval().

GEnergy cta_nroi_elliptical_kern_rho::m_obsEng
protected

Observed photon energy.

Definition at line 667 of file GCTAResponse_helpers.hpp.

Referenced by eval().

GTime cta_nroi_elliptical_kern_rho::m_obsTime
protected

Observed photon arrival time.

Definition at line 668 of file GCTAResponse_helpers.hpp.

Referenced by eval().

double cta_nroi_elliptical_kern_rho::m_posangle
protected

Ellipse boundary position angle.

Definition at line 664 of file GCTAResponse_helpers.hpp.

Referenced by eval().

double cta_nroi_elliptical_kern_rho::m_posangle_roi
protected

Position angle of ROI.

Definition at line 672 of file GCTAResponse_helpers.hpp.

Referenced by eval().

double cta_nroi_elliptical_kern_rho::m_radius_roi
protected

ROI+PSF radius.

Definition at line 673 of file GCTAResponse_helpers.hpp.

Referenced by eval().

double cta_nroi_elliptical_kern_rho::m_rho_roi
protected

Distance between model and ROI centre.

Definition at line 669 of file GCTAResponse_helpers.hpp.

Referenced by eval().

const GMatrix* cta_nroi_elliptical_kern_rho::m_rot
protected

Rotation matrix.

Definition at line 661 of file GCTAResponse_helpers.hpp.

Referenced by eval().

const GCTAResponseIrf* cta_nroi_elliptical_kern_rho::m_rsp
protected

CTA response.

Definition at line 658 of file GCTAResponse_helpers.hpp.

Referenced by eval().

double cta_nroi_elliptical_kern_rho::m_semimajor
protected

Ellipse boundary semimajor axis.

Definition at line 662 of file GCTAResponse_helpers.hpp.

Referenced by eval().

double cta_nroi_elliptical_kern_rho::m_semiminor
protected

Ellipse boundary semiminor axis.

Definition at line 663 of file GCTAResponse_helpers.hpp.

Referenced by eval().

double cta_nroi_elliptical_kern_rho::m_sin_rho_roi
protected

Sine of m_rho_roi.

Definition at line 671 of file GCTAResponse_helpers.hpp.

Referenced by eval().

GEnergy cta_nroi_elliptical_kern_rho::m_srcEng
protected

True photon energy.

Definition at line 665 of file GCTAResponse_helpers.hpp.

Referenced by eval().

GTime cta_nroi_elliptical_kern_rho::m_srcTime
protected

True photon arrival time.

Definition at line 666 of file GCTAResponse_helpers.hpp.

Referenced by eval().


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