gastro  0.1.0
 All Classes Files Functions Variables Pages
mapping.h
1 #ifndef MAPPING__H
2 #define MAPPING__H
3 
4 
5 #include <vector>
6 #include "eigenstuff.h"
7 #include "countedref.h"
8 
9 class FatPoint;
10 class Point;
11 
13 class Mapping : public RefCount
14 {
15 
16  public :
17 
19  virtual unsigned Npar() const = 0;
20 
21 
23  virtual void GetMappingIndices(std::vector<unsigned> &Indices) const = 0;
24 
26 
29  virtual void ComputeTransformAndDerivatives(const FatPoint &Where,
30  FatPoint &OutPos,
31  Eigen::MatrixX2d &H) const = 0;
33  virtual void TransformPosAndErrors(const FatPoint &Where,
34  FatPoint &OutPos) const = 0;
35 
36 
38  virtual void PosDerivative(Point &Where, Eigen::Matrix2d &Der, const double & Eps) const = 0;
39 
41  virtual ~Mapping() {};
42 
43 };
44 
45 // typedef std::list<CountedRef<Mapping> > MappingList;
46 // typedef MappingList::iterator MappingIterator;
47 // typedef MappingList::const_iterator MappingCIterator;
48 
49 
50 #endif /* MAPPING__H */
virtual void PosDerivative(Point &Where, Eigen::Matrix2d &Der, const double &Eps) const =0
The derivative w.r.t. position.
virtual class needed in the abstraction of the distortion model
Definition: mapping.h:13
virtual void TransformPosAndErrors(const FatPoint &Where, FatPoint &OutPos) const =0
The same as above but without the parameter derivatives (used to evaluate chi^2)
virtual void ComputeTransformAndDerivatives(const FatPoint &Where, FatPoint &OutPos, Eigen::MatrixX2d &H) const =0
Actually applies the mapping and evaluates the derivatives w.r.t the fitted parameters.
virtual unsigned Npar() const =0
Mumber of parameters in total.
virtual void GetMappingIndices(std::vector< unsigned > &Indices) const =0
Provides for this parameter set (of length Npar()) how they map into the "grand" fit.