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

Kernel for radial spatial model PSF phi angle integration. More...

#include <cta_helpers_response_stacked_vector.hpp>

Inheritance diagram for cta_psf_radial_kerns_phi:
GFunctions

Public Member Functions

 cta_psf_radial_kerns_phi (cta_psf_radial_kerns_delta *outer, const double &sin_delta_sin_zeta, const double &sin_delta_cos_zeta, const double &cos_delta_sin_zeta, const double &cos_delta_cos_zeta)
 
int size (void) const
 
GVector eval (const double &phi)
 Kernel for azimuthal radial model integration. More...
 
- Public Member Functions inherited from GFunctions
 GFunctions (void)
 Void constructor. More...
 
 GFunctions (const GFunctions &functions)
 Copy constructor. More...
 
virtual ~GFunctions (void)
 Destructor. More...
 
GFunctionsoperator= (const GFunctions &functions)
 Assignment operator. More...
 

Protected Attributes

cta_psf_radial_kerns_deltam_outer
 Pointer to outer integr. More...
 
int m_size
 Result size. More...
 
double m_sin_delta_sin_zeta
 sin(delta) * sin(zeta) More...
 
double m_sin_delta_cos_zeta
 sin(delta) * cos(zeta) More...
 
double m_cos_delta_sin_zeta
 cos(delta) * sin(zeta) More...
 
double m_cos_delta_cos_zeta
 cos(delta) * cos(zeta) More...
 
GVector m_values
 Return value. More...
 

Additional Inherited Members

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

Detailed Description

Kernel for radial spatial model PSF phi angle integration.

This class provides the kernel for the radial spatial model integration of the azimuth angle of the PSF system.

The eval() method of the kernel returns a vector that contains for a given azimuth angle phi the model value and all model parameter gradients.

Definition at line 96 of file cta_helpers_response_stacked_vector.hpp.

Constructor & Destructor Documentation

cta_psf_radial_kerns_phi::cta_psf_radial_kerns_phi ( cta_psf_radial_kerns_delta outer,
const double &  sin_delta_sin_zeta,
const double &  sin_delta_cos_zeta,
const double &  cos_delta_sin_zeta,
const double &  cos_delta_cos_zeta 
)
inline

Definition at line 98 of file cta_helpers_response_stacked_vector.hpp.

Member Function Documentation

GVector cta_psf_radial_kerns_phi::eval ( const double &  phi)
virtual

Kernel for azimuthal radial model integration.

Parameters
[in]phiAzimuth angle (radians).
Returns
Vector of radial model value and parameter factor gradients.

Computes the value and parameter factor gradients of the radial model at the position \((\delta,\phi)\) given in point spread function coordinates.

The angle \(\theta\) of the radial model is computed using

\[ \theta = \arccos \left( \cos \delta \cos \zeta + \sin \delta \sin \zeta \cos \phi \right) \]

where \(\delta\) is the angle between true and measured photon direction, \(\zeta\) is the angle between model centre and measured photon direction, and \(\phi\) is the azimuth angle with respect to the measured photon direction, where \(\phi=0\) corresponds to the connecting line between model centre and measured photon direction.

If gradient computation is requested, the method also returns the gradients

\[ \frac{\partial f}{\partial \alpha_0} \]

and

\[ \frac{\partial f}{\partial \beta_0} \]

in the second and third slot of the returned vector. The following slots contains gradients with respect to other model parameters.

Implements GFunctions.

Definition at line 374 of file cta_helpers_response_stacked_vector.cpp.

References gammalib::acos(), cos(), GModelSpatialRadial::eval(), GOptimizerPar::factor_gradient(), G_PSF_RADIAL_KERNS_PHI, gammalib::is_infinite(), gammalib::is_notanumber(), m_cos_delta_cos_zeta, m_cos_delta_sin_zeta, cta_psf_radial_kerns_delta::m_dphi_dalpha_0, cta_psf_radial_kerns_delta::m_dphi_dbeta_0, cta_psf_radial_kerns_delta::m_dzeta_dalpha_0, cta_psf_radial_kerns_delta::m_dzeta_dbeta_0, cta_psf_radial_kerns_delta::m_grad, cta_psf_radial_kerns_delta::m_model, m_outer, cta_psf_radial_kerns_delta::m_par_lat, cta_psf_radial_kerns_delta::m_par_lon, m_sin_delta_cos_zeta, m_sin_delta_sin_zeta, m_size, m_values, cta_psf_radial_kerns_delta::m_zeta, norm(), sin(), sqrt(), gammalib::str(), and gammalib::warning().

int cta_psf_radial_kerns_phi::size ( void  ) const
inlinevirtual

Implements GFunctions.

Definition at line 110 of file cta_helpers_response_stacked_vector.hpp.

References m_size.

Member Data Documentation

double cta_psf_radial_kerns_phi::m_cos_delta_cos_zeta
protected

cos(delta) * cos(zeta)

Definition at line 118 of file cta_helpers_response_stacked_vector.hpp.

Referenced by eval().

double cta_psf_radial_kerns_phi::m_cos_delta_sin_zeta
protected

cos(delta) * sin(zeta)

Definition at line 117 of file cta_helpers_response_stacked_vector.hpp.

Referenced by eval().

cta_psf_radial_kerns_delta* cta_psf_radial_kerns_phi::m_outer
protected

Pointer to outer integr.

Definition at line 113 of file cta_helpers_response_stacked_vector.hpp.

Referenced by eval().

double cta_psf_radial_kerns_phi::m_sin_delta_cos_zeta
protected

sin(delta) * cos(zeta)

Definition at line 116 of file cta_helpers_response_stacked_vector.hpp.

Referenced by eval().

double cta_psf_radial_kerns_phi::m_sin_delta_sin_zeta
protected

sin(delta) * sin(zeta)

Definition at line 115 of file cta_helpers_response_stacked_vector.hpp.

Referenced by eval().

int cta_psf_radial_kerns_phi::m_size
protected

Result size.

Definition at line 114 of file cta_helpers_response_stacked_vector.hpp.

Referenced by eval(), and size().

GVector cta_psf_radial_kerns_phi::m_values
protected

Return value.

Definition at line 119 of file cta_helpers_response_stacked_vector.hpp.

Referenced by eval().


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