casacore
Loading...
Searching...
No Matches
MCFrame.h
Go to the documentation of this file.
1//# MCFrame.h: Measure frame calculations proxy
2//# Copyright (C) 1996-2003,2007
3//# Associated Universities, Inc. Washington DC, USA.
4//#
5//# This library is free software; you can redistribute it and/or modify it
6//# under the terms of the GNU Library General Public License as published by
7//# the Free Software Foundation; either version 2 of the License, or (at your
8//# option) any later version.
9//#
10//# This library is distributed in the hope that it will be useful, but WITHOUT
11//# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
12//# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public
13//# License for more details.
14//#
15//# You should have received a copy of the GNU Library General Public License
16//# along with this library; if not, write to the Free Software Foundation,
17//# Inc., 675 Massachusetts Ave, Cambridge, MA 02139, USA.
18//#
19//# Correspondence concerning AIPS++ should be addressed as follows:
20//# Internet email: casa-feedback@nrao.edu.
21//# Postal address: AIPS++ Project Office
22//# National Radio Astronomy Observatory
23//# 520 Edgemont Road
24//# Charlottesville, VA 22903-2475 USA
25
26#ifndef MEASURES_MCFRAME_H
27#define MEASURES_MCFRAME_H
28
29//# Includes
30#include <casacore/casa/aips.h>
31#include <casacore/casa/Arrays/Vector.h>
32#include <casacore/measures/Measures/Measure.h>
33#include <casacore/measures/Measures/MeasFrame.h>
34
35namespace casacore { //# NAMESPACE CASACORE - BEGIN
36
37//# Forward Declarations
38class MVDirection;
39class MVPosition;
40
41// <summary>
42// Measure frame calculations proxy
43// </summary>
44
45// <use visibility=local>
46
47// <reviewed reviewer="UNKNOWN" date="before2004/08/25" tests="tMeasure" demos="">
48// </reviewed>
49
50// <prerequisite>
51// <li> <linkto class=Measure>Measure</linkto> class
52// <li> <linkto class=MeasFrame>MeasFrame</linkto> class
53// </prerequisite>
54//
55// <etymology>
56// From Measure and Frame
57// </etymology>
58//
59// <synopsis>
60// The <linkto class=MeasFrame>MeasFrame</linkto> class contains the 'when
61// and where' of an observed Measure. Calculations to get the appropiate
62// value (e.g. the Earth's longitude) from this frame for conversions are
63// done in this class, together with all the caching of (intermediate) results
64// that can speed-up calculations.<br>
65// The MCFrame class is used by the individual measure conversion classes
66// (see <linkto class=MCBase>MCBase</linkto> class).<br>
67// </synopsis>
68//
69// <example>
70// <srcblock>
71// MEpoch my_epoch(Quantity(MeasData::MJDB1950,"d")); // an epoch
72// MCFrame frame(my_epoch); // used in a frame
73// frame.set(obser); // add observatory (an MPosition)
74// MEpoch::Convert conv(my_epoch, MEPoch::Ref(MEpoch::LAST, frame));
75// </srcblock>
76// The <em>conv</em> conversion engine will (transpararently) use the MCFrame
77// class in calls from MCEpoch (the time conversions), which will be called
78// by the MEpoch::Convert () operator.
79// </example>
80//
81// <motivation>
82// To separate the frame calculations from the Measure containers, to enable
83// e.g. Tables to have Measures.
84// </motivation>
85//
86// <todo asof="1997/04/17">
87// </todo>
88
89class MCFrame {
90
91public:
92
93 //# Friends
94
95 //# Constructors
96 // Construct using the MeasFrame parent
98
99 // Destructor
101
102 //# Operators
103
104 //# General member functions
105 // Reset Epoch value
107 // Reset Position value
109 // Reset Direction value
111 // Reset RadialVelocity value
113 // Reset Comet
115 // Make full Epoch
116 void makeEpoch();
117 // Make full Position
119 // Make full Direction
121 // Make full RadialVelocity
123 // Make full Comet
124 void makeComet();
125
126 // Get TDB in days
128 // Get UT1 in days
130 // Get TT in days
132 // Get the longitude (in rad)
134 // Get the latitude (ITRF) (in rad)
136 // Get the position
138 // Get the geocentric position (in m)
140 // Get the geodetic latitude
142 // Get the LAST (in days)
144 // Get the LAST (in rad)
146 // Get J2000 coordinates (direction cosines) and long/lat (rad)
147 // <group>
151 // </group>
152 // Get B1950 coordinates (direction cosines) and long/lat (rad)
153 // <group>
157 // </group>
158 // Get apparent coordinates (direction cosines) and long/lat (rad)
159 // <group>
163 // </group>
164 // Get LSR radial velocity (m/s)
166 // Get Comet type
168 // Get Comet position
170
171private:
172 //# Data
173 // The belonging frame pointer
175 // The actual measure conversion values
176 // <group>
177 // Conversion to TDB time (due to some (for me) unsolvable dependency
178 // errors)
179 // not the proper MeasConvert* here)
181 // TDB time
183 // Conversion to UT1 time
185 // UT1 time
187 // Conversion to TT time
188 void *epConvTT;
189 // TT time
191 // Conversion to LAST time
193 // LAST time
195 // Conversion to ITRF longitude/latitude
197 // Longitude
199 // Position
201 // Conversion to geodetic longitude/latitude
203 // Latitude
205 // Position
207 // Conversion to J2000
209 // Longitude
211 // J2000 coordinates
213 // Conversion to B1950
215 // Longitude
217 // B1950 coordinates
219 // Conversion to apparent coordinates
221 // Longitude
223 // Apparent coordinates
225 // Conversion to LSR radial velocity
227 // Radial velocity
229 // </group>
230
231 //# Member functions
232 // Default constructor (not implemented)
234 // Copy constructor (not implemented)
235 MCFrame(const MCFrame &other);
236 // Copy assignment (not implemented)
237 MCFrame &operator=(const MCFrame &other);
238};
239
240
241} //# NAMESPACE CASACORE - END
242
243#endif
Double * epTTp
TT time.
Definition MCFrame.h:190
Bool getJ2000Long(Double &tdb)
void makeEpoch()
Make full Epoch.
MVPosition * posGeop
Position.
Definition MCFrame.h:206
void resetPosition()
Reset Position value.
void * epConvLAST
Conversion to LAST time.
Definition MCFrame.h:192
void resetComet()
Reset Comet.
void resetEpoch()
Reset Epoch value.
MVDirection * dirB1950p
B1950 coordinates.
Definition MCFrame.h:218
MeasFrame myf
The belonging frame pointer.
Definition MCFrame.h:174
void makeComet()
Make full Comet.
MVPosition * posITRFp
Position.
Definition MCFrame.h:200
void * posConvLongGeo
Conversion to geodetic longitude/latitude.
Definition MCFrame.h:202
Bool getApp(MVDirection &tdb)
Get apparent coordinates (direction cosines) and long/lat (rad)
void * dirConvApp
Conversion to apparent coordinates.
Definition MCFrame.h:220
Bool getLong(Double &tdb)
Get the longitude (in rad)
Vector< Double > * b1950Longp
Longitude.
Definition MCFrame.h:216
void makeRadialVelocity()
Make full RadialVelocity.
MCFrame()
Default constructor (not implemented)
Bool getJ2000Lat(Double &tdb)
Vector< Double > * appLongp
Longitude.
Definition MCFrame.h:222
Bool getCometType(uInt &tdb)
Get Comet type.
Bool getLat(Double &tdb)
Get the latitude (ITRF) (in rad)
void * radConvLSR
Conversion to LSR radial velocity.
Definition MCFrame.h:226
void * epConvTT
Conversion to TT time.
Definition MCFrame.h:188
Bool getTT(Double &tdb)
Get TT in days.
Bool getRadius(Double &tdb)
Get the geocentric position (in m)
Vector< Double > * j2000Longp
Longitude.
Definition MCFrame.h:210
Double * epUT1p
UT1 time.
Definition MCFrame.h:186
Bool getLAST(Double &tdb)
Get the LAST (in days)
void makePosition()
Make full Position.
MVDirection * dirAppp
Apparent coordinates.
Definition MCFrame.h:224
Bool getLASTr(Double &tdb)
Get the LAST (in rad)
void * dirConvJ2000
Conversion to J2000.
Definition MCFrame.h:208
Bool getAppLat(Double &tdb)
Bool getITRF(MVPosition &tdb)
Get the position.
void * epConvUT1
Conversion to UT1 time.
Definition MCFrame.h:184
void * dirConvB1950
Conversion to B1950.
Definition MCFrame.h:214
void * posConvLong
Conversion to ITRF longitude/latitude.
Definition MCFrame.h:196
Double * radLSRp
Radial velocity.
Definition MCFrame.h:228
Bool getJ2000(MVDirection &tdb)
Get J2000 coordinates (direction cosines) and long/lat (rad)
void * epConvTDB
The actual measure conversion values.
Definition MCFrame.h:180
Bool getLatGeo(Double &tdb)
Get the geodetic latitude.
Bool getB1950Long(Double &tdb)
Double * epLASTp
LAST time.
Definition MCFrame.h:194
Bool getAppLong(Double &tdb)
Vector< Double > * posLongGeop
Latitude.
Definition MCFrame.h:204
Bool getB1950Lat(Double &tdb)
MCFrame(const MCFrame &other)
Copy constructor (not implemented)
void resetDirection()
Reset Direction value.
void resetRadialVelocity()
Reset RadialVelocity value.
void makeDirection()
Make full Direction.
Bool getUT1(Double &tdb)
Get UT1 in days.
MCFrame & operator=(const MCFrame &other)
Copy assignment (not implemented)
MCFrame(MeasFrame &inf)
Construct using the MeasFrame parent.
MVDirection * dirJ2000p
J2000 coordinates.
Definition MCFrame.h:212
Bool getComet(MVPosition &tdb)
Get Comet position.
Bool getTDB(Double &tdb)
Get TDB in days.
Bool getLSR(Double &tdb)
Get LSR radial velocity (m/s)
Bool getB1950(MVDirection &tdb)
Get B1950 coordinates (direction cosines) and long/lat (rad)
~MCFrame()
Destructor.
Double * epTDBp
TDB time.
Definition MCFrame.h:182
Vector< Double > * posLongp
Longitude.
Definition MCFrame.h:198
this file contains all the compiler specific defines
Definition mainpage.dox:28
unsigned int uInt
Definition aipstype.h:49
bool Bool
Define the standard types used by Casacore.
Definition aipstype.h:40
double Double
Definition aipstype.h:53