LSST Applications g0f08755f38+9c285cab97,g1635faa6d4+13f3999e92,g1653933729+a8ce1bb630,g1a0ca8cf93+bf6eb00ceb,g28da252d5a+0829b12dee,g29321ee8c0+5700dc9eac,g2bbee38e9b+9634bc57db,g2bc492864f+9634bc57db,g2cdde0e794+c2c89b37c4,g3156d2b45e+41e33cbcdc,g347aa1857d+9634bc57db,g35bb328faa+a8ce1bb630,g3a166c0a6a+9634bc57db,g3e281a1b8c+9f2c4e2fc3,g414038480c+077ccc18e7,g41af890bb2+fde0dd39b6,g5fbc88fb19+17cd334064,g781aacb6e4+a8ce1bb630,g80478fca09+55a9465950,g82479be7b0+d730eedb7d,g858d7b2824+9c285cab97,g9125e01d80+a8ce1bb630,g9726552aa6+10f999ec6a,ga5288a1d22+2a84bb7594,gacf8899fa4+c69c5206e8,gae0086650b+a8ce1bb630,gb58c049af0+d64f4d3760,gc28159a63d+9634bc57db,gcf0d15dbbd+4b7d09cae4,gda3e153d99+9c285cab97,gda6a2b7d83+4b7d09cae4,gdaeeff99f8+1711a396fd,ge2409df99d+5e831397f4,ge79ae78c31+9634bc57db,gf0baf85859+147a0692ba,gf3967379c6+41c94011de,gf3fb38a9a8+8f07a9901b,gfb92a5be7c+9c285cab97,w.2024.46
LSST Data Management Base Package
|
A 2D linear coordinate transformation. More...
#include <LinearTransform.h>
Public Types | |
enum | Parameters { XX = 0 , YX = 1 , XY = 2 , YY = 3 } |
typedef Eigen::Matrix< double, 4, 1 > | ParameterVector |
typedef Eigen::Matrix< double, 2, 4 > | TransformDerivativeMatrix |
typedef Eigen::Matrix< double, 4, 4 > | ProductDerivativeMatrix |
typedef Eigen::Matrix< double, 2, 2, Eigen::DontAlign > | Matrix |
Public Member Functions | |
LinearTransform () noexcept | |
Construct an empty (identity) LinearTransform. | |
LinearTransform (Matrix const &matrix) noexcept | |
Construct an LinearTransform from an Eigen::Matrix. | |
LinearTransform (LinearTransform const &other) noexcept | |
LinearTransform (LinearTransform &&other) noexcept | |
~LinearTransform () noexcept=default | |
LinearTransform | operator* (LinearTransform const &other) const noexcept |
LinearTransform & | operator= (LinearTransform const &other) noexcept |
LinearTransform & | operator= (LinearTransform &&other) noexcept |
LinearTransform & | operator+= (LinearTransform const &other) noexcept |
LinearTransform | operator+ (LinearTransform const &other) noexcept |
LinearTransform & | operator-= (LinearTransform const &other) noexcept |
LinearTransform | operator- (LinearTransform const &other) noexcept |
ParameterVector const | getParameterVector () const noexcept |
Return the transform matrix elements as a parameter vector. | |
void | setParameterVector (ParameterVector const &vector) noexcept |
Set the transform matrix elements from a parameter vector. | |
Matrix const & | getMatrix () const noexcept |
Matrix & | getMatrix () noexcept |
double & | operator[] (int i) |
double const & | operator[] (int i) const |
LinearTransform const | inverted () const |
Return the inverse transform. | |
double | computeDeterminant () const noexcept |
Return the determinant of the 2x2 matrix. | |
bool | isIdentity () const noexcept |
Whether the transform is a no-op. | |
Point2D | operator() (Point2D const &p) const noexcept |
Transform a Point2D object. | |
Extent2D | operator() (Extent2D const &p) const noexcept |
Transform a Extent2D object. | |
double | applyX (double x, double y) const noexcept |
Transform a point given and returned as separate double values. | |
double | applyY (double x, double y) const noexcept |
TransformDerivativeMatrix | dTransform (Point2D const &input) const noexcept |
Derivative of (*this)(input) with respect to the transform elements (for Point). | |
TransformDerivativeMatrix | dTransform (Extent2D const &input) const noexcept |
Derivative of (*this)(input) with respect to the transform elements (for Extent);. | |
Static Public Member Functions | |
static LinearTransform | makeScaling (double s) noexcept |
static LinearTransform | makeScaling (double s, double t) noexcept |
static LinearTransform | makeRotation (Angle t) noexcept |
A 2D linear coordinate transformation.
The transform is represented by a matrix \( \mathbf{M} \) such that
\[ \left[\begin{array}{ c } x_f \\ y_f \end{array}\right] = \mathbf{M} \left[\begin{array}{ c } x_i \\ y_i \end{array}\right] \]
where \((x_i,y_i)\) are the input coordinates and \((x_f,y_f)\) are the output coordinates.
If \( x_f(x_i,y_i) \) and \( y_f(x_i,y_i) \) are continuous differentiable functions, then
\[ \mathbf{M} = \left[\begin{array}{ c c } \displaystyle\frac{\partial x_f}{\partial x_i} & \displaystyle\frac{\partial x_f}{\partial y_i} \\ \displaystyle\frac{\partial y_f}{\partial x_i} & \displaystyle\frac{\partial y_f}{\partial y_i} \end{array}\right] \]
evaluated at \((x_i,y_i)\).
Definition at line 69 of file LinearTransform.h.
typedef Eigen::Matrix<double, 2, 2, Eigen::DontAlign> lsst::geom::LinearTransform::Matrix |
Definition at line 77 of file LinearTransform.h.
typedef Eigen::Matrix<double, 4, 1> lsst::geom::LinearTransform::ParameterVector |
Definition at line 73 of file LinearTransform.h.
typedef Eigen::Matrix<double, 4, 4> lsst::geom::LinearTransform::ProductDerivativeMatrix |
Definition at line 75 of file LinearTransform.h.
typedef Eigen::Matrix<double, 2, 4> lsst::geom::LinearTransform::TransformDerivativeMatrix |
Definition at line 74 of file LinearTransform.h.
|
inlinenoexcept |
Construct an empty (identity) LinearTransform.
Definition at line 80 of file LinearTransform.h.
|
inlineexplicitnoexcept |
Construct an LinearTransform from an Eigen::Matrix.
Definition at line 83 of file LinearTransform.h.
|
inlinenoexcept |
Definition at line 86 of file LinearTransform.h.
|
inlinenoexcept |
Definition at line 87 of file LinearTransform.h.
|
defaultnoexcept |
|
inlinenoexcept |
Transform a point given and returned as separate double values.
This interface is intended primarily for use in Python (where it is vectorized to support NumPy array arguments).
Definition at line 195 of file LinearTransform.h.
|
inlinenoexcept |
Definition at line 196 of file LinearTransform.h.
|
noexcept |
Return the determinant of the 2x2 matrix.
Definition at line 54 of file LinearTransform.cc.
|
inlinenoexcept |
Derivative of (*this)(input) with respect to the transform elements (for Extent);.
Definition at line 205 of file LinearTransform.h.
|
noexcept |
Derivative of (*this)(input) with respect to the transform elements (for Point).
Definition at line 56 of file LinearTransform.cc.
|
inlinenoexcept |
Definition at line 151 of file LinearTransform.h.
|
inlinenoexcept |
Definition at line 152 of file LinearTransform.h.
|
noexcept |
Return the transform matrix elements as a parameter vector.
The elements will be ordered XX, YX, XY, YY
Definition at line 32 of file LinearTransform.cc.
LinearTransform const lsst::geom::LinearTransform::inverted | ( | ) | const |
Return the inverse transform.
lsst::geom::SingularTransformException | if not invertible |
Definition at line 45 of file LinearTransform.cc.
|
inlinenoexcept |
|
inlinestaticnoexcept |
Definition at line 102 of file LinearTransform.h.
|
inlinestaticnoexcept |
Definition at line 94 of file LinearTransform.h.
|
inlinestaticnoexcept |
Definition at line 98 of file LinearTransform.h.
Transform a Extent2D object.
This operation is equivalent to applying the LinearTransform to an lsst::geom::Point
Definition at line 186 of file LinearTransform.h.
Transform a Point2D object.
This operation is equivalent to applying the LinearTransform to an lsst::geom::Extent
Definition at line 178 of file LinearTransform.h.
|
inlinenoexcept |
Definition at line 90 of file LinearTransform.h.
|
inlinenoexcept |
Definition at line 121 of file LinearTransform.h.
|
inlinenoexcept |
Definition at line 116 of file LinearTransform.h.
|
inlinenoexcept |
Definition at line 132 of file LinearTransform.h.
|
inlinenoexcept |
Definition at line 127 of file LinearTransform.h.
|
inlinenoexcept |
Definition at line 111 of file LinearTransform.h.
|
inlinenoexcept |
Definition at line 107 of file LinearTransform.h.
|
inline |
Definition at line 154 of file LinearTransform.h.
|
inline |
Definition at line 155 of file LinearTransform.h.
|
noexcept |