00001 00002 ////////////////////////////////////////////////////////////////////////////////////////////////// 00003 /*! \file KalmanFilterHistory.h 00004 * \brief A class to store additional data specific to the Kalman Filter. Derived from SequentialFilter. 00005 * \author $Author: cakinli $ 00006 * \version $Revision: 1.8 $ 00007 * \date $Date: 2005/03/16 18:08:13 $ 00008 *////////////////////////////////////////////////////////////////////////////////////////////////// 00009 /* 00010 */ 00011 ////////////////////////////////////////////////////////////////////////////////////////////////// 00012 00013 #ifndef __SSSL_KALMANFILTER_HISTORY_H__ 00014 #define __SSSL_KALMANFILTER_HISTORY_H__ 00015 00016 #include <matrix/Matrix.h> 00017 #include <datahandling/History.h> 00018 #include "utils/Time.h" 00019 #include <Filtering/KalmanFilter.h> 00020 #include <Logging/SequentialFilterHistory.h> 00021 #include <vector> 00022 using namespace std; 00023 using namespace O_SESSAME; 00024 00025 /*! \brief A class to store additional data specific to the Kalman Filter. Derived from SequentialFilter. 00026 ** 00027 */ 00028 class KalmanFilterHistory : public SequentialFilterHistory { 00029 00030 public: 00031 // CONSTRUCTOR / DESTRUCTOR 00032 KalmanFilterHistory() {}; /*!< Needed for derived classes. */ 00033 KalmanFilterHistory(SequentialFilter* _ptr_filter); 00034 /*! \brief Default Deconstructor. */ 00035 virtual ~KalmanFilterHistory() {}; 00036 00037 // OPERATORS 00038 virtual void AppendHistory(const double& _appendTime); 00039 virtual void AppendHistory(const ssfTime& _appendTime); 00040 00041 void ResetHistory(); 00042 00043 // INSPECTORS 00044 Matrix GetHistory(); 00045 void GetKalmanHistory(Matrix& _sfHistMatrix, Matrix& _kfHistMatrix); 00046 00047 // void GetState(const ssfTime& _requestedTime, sequentialFilterData& _returnSequentialStruct); 00048 00049 protected: 00050 /*! \brief internal vector container of covariance matrices, P. */ 00051 vector<Matrix> m_kfCovarianceHistory; 00052 /*! \brief internal vector container of Kalman gain matrices, K. */ 00053 vector<Matrix> m_kfKalmanGainHistory; 00054 00055 }; 00056 00057 00058 #endif 00059 00060 00061 // Do not change the comments below - they will be added automatically by CVS 00062 /***************************************************************************** 00063 * $Log: KalmanFilterHistory.h,v $ 00064 * Revision 1.8 2005/03/16 18:08:13 cakinli 00065 * *** empty log message *** 00066 * 00067 * Revision 1.7 2003/11/01 21:00:15 rsharo 00068 * changed "Time.h" includes to "utils/Time.h" includes. Also eliminated excess compile warnings. 00069 * 00070 * Revision 1.6 2003/07/12 18:19:59 simpliciter 00071 * Fixed linker errors. 00072 * 00073 * Revision 1.5 2003/07/12 17:54:40 simpliciter 00074 * Added IEKF and EKF Histories. 00075 * 00076 * Revision 1.4 2003/06/28 00:45:37 simpliciter 00077 * Basic housekeeping. 00078 * 00079 * Revision 1.3 2003/06/27 01:52:50 simpliciter 00080 * Fully commented! And almost fully functional. 00081 * Once I learn the best way to copy chunks of one Matrix 00082 * into another I'll finish GetKalmanHistory. Otherwise 00083 * everything is done. GetState is not implemented because 00084 * it would require / desire interpolations, which seems out 00085 * of spirit with tracking the effectiveness of a filter. 00086 * 00087 * Revision 1.2 2003/06/24 15:50:06 simpliciter 00088 * Everything but the all important "GetHistory" command 00089 * should work. :) 00090 * 00091 * Revision 1.1 2003/06/12 20:47:23 simpliciter 00092 * Previously IterativeFilterHistory.h 00093 * 00094 * Revision 1.0 2003/06/11 20:55:53 simpliciter 00095 * Initial submission. 00096 * 00097 * 00098 * 00099 ******************************************************************************/