GammaLib 2.0.0
Loading...
Searching...
No Matches
GBilinear Class Reference

Bilinear interpolator class. More...

#include <GBilinear.hpp>

Inheritance diagram for GBilinear:
GBase

Public Member Functions

 GBilinear (void)
 Void constructor.
 
 GBilinear (const GBilinear &interpolator)
 Copy constructor.
 
virtual ~GBilinear (void)
 Destructor.
 
GBilinearoperator= (const GBilinear &interpolator)
 Assignment operator.
 
double operator() (const double *array)
 Interpolator.
 
void clear (void)
 Clear node array.
 
GBilinearclone (void) const
 Clone bilinear interolator.
 
std::string classname (void) const
 Return class name.
 
int & index1 (void)
 Access index 1.
 
int & index2 (void)
 Access index 2.
 
int & index3 (void)
 Access index 3.
 
int & index4 (void)
 Access index 4.
 
double & weight1 (void)
 Access weight 1.
 
double & weight2 (void)
 Access weight 2.
 
double & weight3 (void)
 Access weight 3.
 
double & weight4 (void)
 Access weight 4.
 
std::string print (const GChatter &chatter=NORMAL) const
 Print nodes.
 
- Public Member Functions inherited from GBase
virtual ~GBase (void)
 Destructor.
 

Private Member Functions

void init_members (void)
 Initialise class members.
 
void copy_members (const GBilinear &interpolator)
 Copy class members.
 
void free_members (void)
 Delete class members.
 

Private Attributes

int m_inx1
 
int m_inx2
 
int m_inx3
 
int m_inx4
 
double m_wgt1
 
double m_wgt2
 
double m_wgt3
 
double m_wgt4
 

Detailed Description

Bilinear interpolator class.

Definition at line 40 of file GBilinear.hpp.

Constructor & Destructor Documentation

◆ GBilinear() [1/2]

GBilinear::GBilinear ( void )

Void constructor.

Definition at line 54 of file GBilinear.cpp.

References init_members().

Referenced by clone().

◆ GBilinear() [2/2]

GBilinear::GBilinear ( const GBilinear & interpolator)

Copy constructor.

Parameters
[in]interpolatorBilinear interpolator.

Definition at line 69 of file GBilinear.cpp.

References copy_members(), and init_members().

◆ ~GBilinear()

GBilinear::~GBilinear ( void )
virtual

Destructor.

Definition at line 85 of file GBilinear.cpp.

References free_members().

Member Function Documentation

◆ classname()

std::string GBilinear::classname ( void ) const
inlinevirtual

Return class name.

Returns
String containing the class name ("GBilinear").

Implements GBase.

Definition at line 90 of file GBilinear.hpp.

◆ clear()

void GBilinear::clear ( void )
virtual

Clear node array.

Implements GBase.

Definition at line 156 of file GBilinear.cpp.

References free_members(), and init_members().

Referenced by GSkyMap::extract(), and GSkyMap::init_members().

◆ clone()

GBilinear * GBilinear::clone ( void ) const
virtual

Clone bilinear interolator.

Returns
Pointer to deep copy of bilinear interolator.

Implements GBase.

Definition at line 174 of file GBilinear.cpp.

References GBilinear().

◆ copy_members()

void GBilinear::copy_members ( const GBilinear & interpolator)
private

Copy class members.

Parameters
[in]interpolatorBilinear interpolator.

Definition at line 249 of file GBilinear.cpp.

References m_inx1, m_inx2, m_inx3, m_inx4, m_wgt1, m_wgt2, m_wgt3, and m_wgt4.

Referenced by GBilinear(), and operator=().

◆ free_members()

void GBilinear::free_members ( void )
private

Delete class members.

Definition at line 269 of file GBilinear.cpp.

Referenced by clear(), operator=(), and ~GBilinear().

◆ index1()

int & GBilinear::index1 ( void )
inline

Access index 1.

Returns
Reference to index 1.

Definition at line 102 of file GBilinear.hpp.

References m_inx1.

Referenced by GHealpix::interpolator(), and GSkyMap::operator()().

◆ index2()

int & GBilinear::index2 ( void )
inline

Access index 2.

Returns
Reference to index 2.

Definition at line 114 of file GBilinear.hpp.

References m_inx2.

Referenced by GHealpix::interpolator(), and GSkyMap::operator()().

◆ index3()

int & GBilinear::index3 ( void )
inline

Access index 3.

Returns
Reference to index 3.

Definition at line 126 of file GBilinear.hpp.

References m_inx3.

Referenced by GHealpix::interpolator(), and GSkyMap::operator()().

◆ index4()

int & GBilinear::index4 ( void )
inline

Access index 4.

Returns
Reference to index 4.

Definition at line 138 of file GBilinear.hpp.

References m_inx4.

Referenced by GHealpix::interpolator(), and GSkyMap::operator()().

◆ init_members()

void GBilinear::init_members ( void )
private

Initialise class members.

Definition at line 227 of file GBilinear.cpp.

References m_inx1, m_inx2, m_inx3, m_inx4, m_wgt1, m_wgt2, m_wgt3, and m_wgt4.

Referenced by clear(), GBilinear(), GBilinear(), and operator=().

◆ operator()()

double GBilinear::operator() ( const double * array)

Interpolator.

Parameters
[in]arrayBilinear interpolator.
Returns
Interpolated value.

Definition at line 134 of file GBilinear.cpp.

References m_inx1, m_inx2, m_inx3, m_inx4, m_wgt1, m_wgt2, m_wgt3, and m_wgt4.

◆ operator=()

GBilinear & GBilinear::operator= ( const GBilinear & interpolator)

Assignment operator.

Parameters
[in]interpolatorBilinear interpolator.
Returns
Bilinear interpolator.

Definition at line 107 of file GBilinear.cpp.

References copy_members(), free_members(), and init_members().

◆ print()

std::string GBilinear::print ( const GChatter & chatter = NORMAL) const
virtual

Print nodes.

Parameters
[in]chatterChattiness (defaults to NORMAL).
Returns
String containing nodes information.

Implements GBase.

Definition at line 186 of file GBilinear.cpp.

References m_inx1, m_inx2, m_inx3, m_inx4, m_wgt1, m_wgt2, m_wgt3, m_wgt4, gammalib::parformat(), SILENT, and gammalib::str().

◆ weight1()

double & GBilinear::weight1 ( void )
inline

Access weight 1.

Returns
Reference to weight 1.

Definition at line 150 of file GBilinear.hpp.

References m_wgt1.

Referenced by GHealpix::interpolator(), and GSkyMap::operator()().

◆ weight2()

double & GBilinear::weight2 ( void )
inline

Access weight 2.

Returns
Reference to weight 2.

Definition at line 162 of file GBilinear.hpp.

References m_wgt2.

Referenced by GHealpix::interpolator(), and GSkyMap::operator()().

◆ weight3()

double & GBilinear::weight3 ( void )
inline

Access weight 3.

Returns
Reference to weight 3.

Definition at line 174 of file GBilinear.hpp.

References m_wgt3.

Referenced by GHealpix::interpolator(), and GSkyMap::operator()().

◆ weight4()

double & GBilinear::weight4 ( void )
inline

Access weight 4.

Returns
Reference to weight 4.

Definition at line 186 of file GBilinear.hpp.

References m_wgt4.

Referenced by GHealpix::interpolator(), and GSkyMap::operator()().

Member Data Documentation

◆ m_inx1

int GBilinear::m_inx1
private

Definition at line 73 of file GBilinear.hpp.

Referenced by copy_members(), index1(), init_members(), operator()(), and print().

◆ m_inx2

int GBilinear::m_inx2
private

Definition at line 74 of file GBilinear.hpp.

Referenced by copy_members(), index2(), init_members(), operator()(), and print().

◆ m_inx3

int GBilinear::m_inx3
private

Definition at line 75 of file GBilinear.hpp.

Referenced by copy_members(), index3(), init_members(), operator()(), and print().

◆ m_inx4

int GBilinear::m_inx4
private

Definition at line 76 of file GBilinear.hpp.

Referenced by copy_members(), index4(), init_members(), operator()(), and print().

◆ m_wgt1

double GBilinear::m_wgt1
private

Definition at line 77 of file GBilinear.hpp.

Referenced by copy_members(), init_members(), operator()(), print(), and weight1().

◆ m_wgt2

double GBilinear::m_wgt2
private

Definition at line 78 of file GBilinear.hpp.

Referenced by copy_members(), init_members(), operator()(), print(), and weight2().

◆ m_wgt3

double GBilinear::m_wgt3
private

Definition at line 79 of file GBilinear.hpp.

Referenced by copy_members(), init_members(), operator()(), print(), and weight3().

◆ m_wgt4

double GBilinear::m_wgt4
private

Definition at line 80 of file GBilinear.hpp.

Referenced by copy_members(), init_members(), operator()(), print(), and weight4().


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