00001 ////////////////////////////////////////////////////////////////////////////////////////////////// 00002 /*! \file MagneticModel.h 00003 * \brief Class for describing the magnetic model of a central body. 00004 * \author $Author: jayhawk_hokie $ 00005 * \version $Revision: 1.2 $ 00006 * \date $Date: 2005/06/10 12:53:28 $ 00007 *////////////////////////////////////////////////////////////////////////////////////////////////// 00008 /* 00009 */ 00010 ////////////////////////////////////////////////////////////////////////////////////////////////// 00011 00012 #ifndef __OSESSAME_MAGNETIC_MODEL_H__ 00013 #define __OSESSAME_MAGNETIC_MODEL_H__ 00014 00015 #include <matrix/Matrix.h> 00016 #include <utils/Time.h> 00017 00018 namespace O_SESSAME { 00019 00020 /** @brief Structure to hold typical magnetic model coefficients. */ 00021 typedef struct { 00022 ssfTime modelEpoch; /**< time of model epoch, set in ssfTime::Epoch */ 00023 double H0; /**< coefficient of Field strength, [nT] */ 00024 double DipoleCoelevation; /**< coelevation of the dipole at epoch, [rad] */ 00025 double DipoleEastLongitude; /**< east longitude of the dipole at epoch, [rad] */ 00026 double CBAvgRotationRate; /**< average rotation rate of central body, [rad/s] */ 00027 double CBRadius; /**< radius of the central body, [km] */ 00028 } MagneticFieldCoefficients; 00029 00030 /** @brief The MagneticModel class encapsulates a magnetic model of a central body. 00031 * @ingroup EnvironmentModels 00032 */ 00033 class MagneticModel 00034 { 00035 public: 00036 virtual ~MagneticModel() {} 00037 00038 virtual Vector GetMagneticField(const ssfTime& _currentTime, const Vector& _PositionVector) = 0; 00039 virtual void SetMagFieldCoefficients(const MagneticFieldCoefficients& _newMagFieldCoeffs) {m_MagFieldCoeffs = _newMagFieldCoeffs;} 00040 00041 protected: 00042 MagneticModel() {} 00043 00044 MagneticFieldCoefficients m_MagFieldCoeffs; 00045 00046 private: 00047 00048 }; 00049 } 00050 #endif 00051 // Do not change the comments below - they will be added automatically by CVS 00052 /***************************************************************************** 00053 * $Log: MagneticModel.h,v $ 00054 * Revision 1.2 2005/06/10 12:53:28 jayhawk_hokie 00055 * Changed header file format to make it easier to link to the spacecraft code by only having to specify dsacss/dep/spacecraft/src (ex. "file.h" changed to <dir/file.h> where dir is a folder in src). 00056 * 00057 * Revision 1.1.1.1 2005/04/26 17:40:56 cakinli 00058 * Adding OpenSESSAME to DSACSS distrib to capture fixed version. 00059 * 00060 * Revision 1.4 2003/10/18 21:37:28 rsharo 00061 * Removed "../utils" from all qmake project paths. Prepended "utils 00062 * /" to all #include directives for utils. Removed ".h" extensions from STL header 00063 * s and referenced STL components from "std::" namespace. Overall, changed to be 00064 * more portable. 00065 * 00066 * Revision 1.3 2003/06/12 18:00:31 nilspace 00067 * Fixed references to CentralBody. 00068 * 00069 * Revision 1.2 2003/06/10 14:45:43 nilspace 00070 * Changed include from Vector.h to Matrix.h 00071 * 00072 * Revision 1.1 2003/06/10 14:26:50 nilspace 00073 * Initial Submission. 00074 * 00075 * 00076 ******************************************************************************/