trafos.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031 #ifndef PLANCK_TRAFOS_H
00032 #define PLANCK_TRAFOS_H
00033
00034 #include "vec3.h"
00035 #include "pointing.h"
00036 #include "rotmatrix.h"
00037
00038 enum coordsys { Ecliptic, Equatorial, Galactic };
00039
00040
00041 class Trafo
00042 {
00043 private:
00044 rotmatrix mat;
00045
00046 static vec3 xcc_dp_precess (const vec3 &iv, double iepoch, double oepoch);
00047 static double get_epsilon (double epoch);
00048 static vec3 xcc_dp_e_to_q (const vec3 &iv, double epoch);
00049 static vec3 xcc_dp_q_to_e (const vec3 &iv, double epoch);
00050 static vec3 xcc_dp_g_to_e (const vec3 &iv, double epoch);
00051 static vec3 xcc_dp_e_to_g (const vec3 &iv, double epoch);
00052 static vec3 xcc_v_convert(const vec3 &iv, double iepoch, double oepoch,
00053 coordsys isys,coordsys osys);
00054 static void coordsys2matrix (double iepoch, double oepoch, coordsys isys,
00055 coordsys osys, rotmatrix &matrix);
00056
00057 public:
00058
00059
00060 Trafo (double iepoch, double oepoch, coordsys isys, coordsys osys);
00061
00062
00063 vec3 operator() (const vec3 &vec) const
00064 { return mat.Transform(vec); }
00065
00066
00067 pointing operator() (const pointing &ptg) const;
00068
00069
00070
00071 void rotatefull (const pointing &ptg, pointing &newptg,
00072 double &delta_psi) const;
00073
00074
00075 void rotatefull (pointing &ptg, double &psi) const;
00076
00077
00078
00079 void rotatefull (const vec3 &vec, vec3 &newvec, double &delta_psi) const;
00080
00081
00082 void rotatefull (vec3 &vec, double &psi) const;
00083
00084
00085 const rotmatrix &Matrix() const
00086 { return mat; }
00087 };
00088
00089 #endif