LSST Applications  21.0.0-172-gfb10e10a+18fedfabac,22.0.0+297cba6710,22.0.0+80564b0ff1,22.0.0+8d77f4f51a,22.0.0+a28f4c53b1,22.0.0+dcf3732eb2,22.0.1-1-g7d6de66+2a20fdde0d,22.0.1-1-g8e32f31+297cba6710,22.0.1-1-geca5380+7fa3b7d9b6,22.0.1-12-g44dc1dc+2a20fdde0d,22.0.1-15-g6a90155+515f58c32b,22.0.1-16-g9282f48+790f5f2caa,22.0.1-2-g92698f7+dcf3732eb2,22.0.1-2-ga9b0f51+7fa3b7d9b6,22.0.1-2-gd1925c9+bf4f0e694f,22.0.1-24-g1ad7a390+a9625a72a8,22.0.1-25-g5bf6245+3ad8ecd50b,22.0.1-25-gb120d7b+8b5510f75f,22.0.1-27-g97737f7+2a20fdde0d,22.0.1-32-gf62ce7b1+aa4237961e,22.0.1-4-g0b3f228+2a20fdde0d,22.0.1-4-g243d05b+871c1b8305,22.0.1-4-g3a563be+32dcf1063f,22.0.1-4-g44f2e3d+9e4ab0f4fa,22.0.1-42-gca6935d93+ba5e5ca3eb,22.0.1-5-g15c806e+85460ae5f3,22.0.1-5-g58711c4+611d128589,22.0.1-5-g75bb458+99c117b92f,22.0.1-6-g1c63a23+7fa3b7d9b6,22.0.1-6-g50866e6+84ff5a128b,22.0.1-6-g8d3140d+720564cf76,22.0.1-6-gd805d02+cc5644f571,22.0.1-8-ge5750ce+85460ae5f3,master-g6e05de7fdc+babf819c66,master-g99da0e417a+8d77f4f51a,w.2021.48
LSST Data Management Base Package
Public Types | Public Member Functions | List of all members
lsst::afw::math::ApproximateControl Class Reference

Control how to make an approximation. More...

#include <Approximate.h>

Public Types

enum  Style { UNKNOWN = -1 , CHEBYSHEV , NUM_STYLES }
 Choose the type of approximation to use. More...
 

Public Member Functions

 ApproximateControl (Style style, int orderX, int orderY=-1, bool weighting=true)
 ctor More...
 
Style getStyle () const
 Return the Style. More...
 
void setStyle (Style const style)
 Set the Style. More...
 
int getOrderX () const
 Return the order of approximation to use in the x-direction. More...
 
void setOrderX (int const orderX)
 Set the order of approximation to use in the x-direction. More...
 
int getOrderY () const
 Return the order of approximation to use in the y-direction. More...
 
void setOrderY (int const orderY)
 Set the order of approximation to use in the y-direction. More...
 
bool getWeighting () const
 Return whether inverse variance weighting will be used in calculation. More...
 
void setWeighting (bool const weighting)
 Set whether inverse variance weighting will be used in calculation. More...
 

Detailed Description

Control how to make an approximation.

Note
the x- and y-order must be the same, due to a limitation of Chebyshev1Function2

Definition at line 48 of file Approximate.h.

Member Enumeration Documentation

◆ Style

Choose the type of approximation to use.

Enumerator
UNKNOWN 
CHEBYSHEV 

Use a 2-D Chebyshev polynomial.

NUM_STYLES 

Definition at line 51 of file Approximate.h.

51  {
52  UNKNOWN = -1,
53  CHEBYSHEV,
55  };
@ CHEBYSHEV
Use a 2-D Chebyshev polynomial.
Definition: Approximate.h:53

Constructor & Destructor Documentation

◆ ApproximateControl()

lsst::afw::math::ApproximateControl::ApproximateControl ( Style  style,
int  orderX,
int  orderY = -1,
bool  weighting = true 
)

ctor

Parameters
styleType of approximation
orderXOrder of approximation to use in x-direction
orderYOrder of approximation to use in y-direction
weightingUse inverse variance weighting?

Definition at line 46 of file Approximate.cc.

47  : _style(style), _orderX(orderX), _orderY(orderY < 0 ? orderX : orderY), _weighting(weighting) {
48  if (_orderX != _orderY) {
50  str(boost::format("X- and Y-orders must be equal (%d != %d) "
51  "due to a limitation in math::Chebyshev1Function2") %
52  _orderX % _orderY));
53  }
54 }
table::Key< int > orderX
#define LSST_EXCEPT(type,...)
Create an exception with a given type.
Definition: Exception.h:48
Reports invalid arguments.
Definition: Runtime.h:66
def format(config, name=None, writeSourceLine=True, prefix="", verbose=False)
Definition: history.py:174

Member Function Documentation

◆ getOrderX()

int lsst::afw::math::ApproximateControl::getOrderX ( ) const
inline

Return the order of approximation to use in the x-direction.

Definition at line 70 of file Approximate.h.

70 { return _orderX; }

◆ getOrderY()

int lsst::afw::math::ApproximateControl::getOrderY ( ) const
inline

Return the order of approximation to use in the y-direction.

Definition at line 74 of file Approximate.h.

74 { return _orderY; }

◆ getStyle()

Style lsst::afw::math::ApproximateControl::getStyle ( ) const
inline

Return the Style.

Definition at line 66 of file Approximate.h.

66 { return _style; }

◆ getWeighting()

bool lsst::afw::math::ApproximateControl::getWeighting ( ) const
inline

Return whether inverse variance weighting will be used in calculation.

Definition at line 78 of file Approximate.h.

78 { return _weighting; }

◆ setOrderX()

void lsst::afw::math::ApproximateControl::setOrderX ( int const  orderX)
inline

Set the order of approximation to use in the x-direction.

Definition at line 72 of file Approximate.h.

72 { _orderX = orderX; }

◆ setOrderY()

void lsst::afw::math::ApproximateControl::setOrderY ( int const  orderY)
inline

Set the order of approximation to use in the y-direction.

Definition at line 76 of file Approximate.h.

76 { _orderY = orderY; }

◆ setStyle()

void lsst::afw::math::ApproximateControl::setStyle ( Style const  style)
inline

Set the Style.

Definition at line 68 of file Approximate.h.

68 { _style = style; }

◆ setWeighting()

void lsst::afw::math::ApproximateControl::setWeighting ( bool const  weighting)
inline

Set whether inverse variance weighting will be used in calculation.

Definition at line 80 of file Approximate.h.

80 { _weighting = weighting; }

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