MOOS 0.2375
Classes | Public Member Functions
CMOOSGeodesy Class Reference

Implements simple geodesy calculations. More...

#include <MOOSGeodesy.h>

Collaboration diagram for CMOOSGeodesy:
Collaboration graph
[legend]

List of all members.

Classes

class  CEllipsoid

Public Member Functions

 CMOOSGeodesy ()
virtual ~CMOOSGeodesy ()
double GetOriginNorthing ()
double GetOriginEasting ()
bool LatLong2LocalUTM (double lat, double lon, double &MetersNorth, double &MetersEast)
bool LocalGrid2LatLong (double dfEast, double dfNorth, double &dfLat, double &dfLon)
bool UTM2LatLong (double dfX, double dfY, double &dfLat, double &dfLong)
char * GetUTMZone ()
int GetRefEllipsoid ()
double GetMetersEast ()
double GetMetersNorth ()
double GetOriginLatitude ()
double GetOriginLongitude ()
bool Initialise (double lat, double lon)
double GetLocalGridY ()
double GetLocalGridX ()
bool LatLong2LocalGrid (double lat, double lon, double &MetersNorth, double &MetersEast)
double DMS2DecDeg (double dfVal)

Detailed Description

Implements simple geodesy calculations.

Definition at line 52 of file MOOSGeodesy.h.


Constructor & Destructor Documentation

CMOOSGeodesy::CMOOSGeodesy ( )

Definition at line 62 of file MOOSGeodesy.cpp.

CMOOSGeodesy::~CMOOSGeodesy ( ) [virtual]

Definition at line 86 of file MOOSGeodesy.cpp.


Member Function Documentation

double CMOOSGeodesy::DMS2DecDeg ( double  dfVal)

Definition at line 390 of file MOOSGeodesy.cpp.

double CMOOSGeodesy::GetLocalGridX ( )

Definition at line 444 of file MOOSGeodesy.cpp.

double CMOOSGeodesy::GetLocalGridY ( )

Definition at line 449 of file MOOSGeodesy.cpp.

double CMOOSGeodesy::GetMetersEast ( )

Definition at line 161 of file MOOSGeodesy.cpp.

double CMOOSGeodesy::GetMetersNorth ( )

Definition at line 156 of file MOOSGeodesy.cpp.

double CMOOSGeodesy::GetOriginEasting ( )

Definition at line 380 of file MOOSGeodesy.cpp.

double CMOOSGeodesy::GetOriginLatitude ( )

Definition at line 140 of file MOOSGeodesy.cpp.

double CMOOSGeodesy::GetOriginLongitude ( )

Definition at line 135 of file MOOSGeodesy.cpp.

double CMOOSGeodesy::GetOriginNorthing ( )

Definition at line 385 of file MOOSGeodesy.cpp.

int CMOOSGeodesy::GetRefEllipsoid ( )

Definition at line 291 of file MOOSGeodesy.cpp.

char * CMOOSGeodesy::GetUTMZone ( )

Definition at line 307 of file MOOSGeodesy.cpp.

bool CMOOSGeodesy::Initialise ( double  lat,
double  lon 
)

This method is called to set the Origins of the Coordinate system being used by the vehicle for a mission. This class will store the vehicle's position in Northings and Eastings. This allows for tracking the vehicle as if it were operating on a grid.

Parameters:
latthe Latitude of where the vehicle is as it begins a mission
lonthe Longitude of where the vehicle is as it begins a mission
Returns:
only returns true at the moment, no reason as to why it should fail perhaps some way of checking UTM zones vs a list of some sort?

Definition at line 104 of file MOOSGeodesy.cpp.

bool CMOOSGeodesy::LatLong2LocalGrid ( double  lat,
double  lon,
double &  MetersNorth,
double &  MetersEast 
)

Definition at line 401 of file MOOSGeodesy.cpp.

bool CMOOSGeodesy::LatLong2LocalUTM ( double  lat,
double  lon,
double &  MetersNorth,
double &  MetersEast 
)

This method is the interface to this class and allows the client to query the amount of ground covered with respect to the origin where the origin is defined as a point in the UTM grid where we got an initial GPS fix that we defined to be the origin. What this method does not take into account is the curvature of the reference ellipsoid at a particular Lat/Lon value. Curvature influences the deltaX and deltaY that this method calculates for determining the overall distance traveled wrt the origin. Therefore, at Lat/Lon values that are significantly far enough (~300km) away from the origin of the UTM grid (0,0), a shift in one dimension, i.e. just along Latitude, or just along Longitude, does not map to a corresponding one dimensional shift in our "local" grid where we should be seeing just a deltaX or deltaY result in moving in only one direction. Instead, we have observed that moving just .0001 degrees in Longitude (~1m in local) results in both a deltaX that is coupled to a deltaY.

Parameters:
latThe current Latitude the vehicle is at
lonThe current Longitude the vehicle is at
MetersNorthThe distance in meters traveled North wrt to Origin
MetersEastThe distance in meters traveled East wrt to Origin

Definition at line 334 of file MOOSGeodesy.cpp.

bool CMOOSGeodesy::LocalGrid2LatLong ( double  dfEast,
double  dfNorth,
double &  dfLat,
double &  dfLon 
)

Utility method for converting from a local grid fix to the global Lat, Lon pair. This method will work for small grid approximations - <300km sq

Parameters:
dfEastThe current local grid distance in meters traveled East (X dir) wrt to Origin
dfNorthThe current local grid distance in meters traveled North (Y dir) wrt to Origin
dfLatthe calculated latitude out
dfLonthe calculated longitude out

Definition at line 464 of file MOOSGeodesy.cpp.

bool CMOOSGeodesy::UTM2LatLong ( double  dfX,
double  dfY,
double &  dfLat,
double &  dfLong 
)

Definition at line 489 of file MOOSGeodesy.cpp.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines