00001 #pragma ident "$Id: SolverLMS.hpp 1319 2008-07-28 13:46:29Z architest $" 00002 00008 #ifndef SOLVERLMS_HPP 00009 #define SOLVERLMS_HPP 00010 00011 //============================================================================ 00012 // 00013 // This file is part of GPSTk, the GPS Toolkit. 00014 // 00015 // The GPSTk is free software; you can redistribute it and/or modify 00016 // it under the terms of the GNU Lesser General Public License as published 00017 // by the Free Software Foundation; either version 2.1 of the License, or 00018 // any later version. 00019 // 00020 // The GPSTk is distributed in the hope that it will be useful, 00021 // but WITHOUT ANY WARRANTY; without even the implied warranty of 00022 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00023 // GNU Lesser General Public License for more details. 00024 // 00025 // You should have received a copy of the GNU Lesser General Public 00026 // License along with GPSTk; if not, write to the Free Software Foundation, 00027 // Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 00028 // 00029 // Dagoberto Salazar - gAGE ( http://www.gage.es ). 2006, 2007, 2008 00030 // 00031 //============================================================================ 00032 00033 00034 #include "SolverBase.hpp" 00035 #include "TypeID.hpp" 00036 #include "ProcessingClass.hpp" 00037 00038 00039 namespace gpstk 00040 { 00041 00043 00044 00045 00114 class SolverLMS : public SolverBase, public ProcessingClass 00115 { 00116 public: 00117 00118 00123 SolverLMS(); 00124 00125 00131 SolverLMS(const gnssEquationDefinition& eqDef) 00132 : defaultEqDef(eqDef) 00133 { setIndex(); }; 00134 00135 00146 virtual int Compute( const Vector<double>& prefitResiduals, 00147 const Matrix<double>& designMatrix ) 00148 throw(InvalidSolver); 00149 00150 00156 virtual satTypeValueMap& Process(satTypeValueMap& gData) 00157 throw(ProcessingException); 00158 00159 00165 virtual gnssSatTypeValue& Process(gnssSatTypeValue& gData) 00166 throw(ProcessingException) 00167 { Process(gData.body); return gData; }; 00168 00169 00175 virtual gnssRinex& Process(gnssRinex& gData) 00176 throw(ProcessingException) 00177 { Process(gData.body); return gData; }; 00178 00179 00184 virtual double getSolution(const TypeID& type) const 00185 throw(InvalidRequest); 00186 00187 00192 virtual double getVariance(const TypeID& type) const 00193 throw(InvalidRequest); 00194 00195 00201 virtual SolverLMS& setDefaultEqDefinition( 00202 const gnssEquationDefinition& eqDef ) 00203 { defaultEqDef = eqDef; return (*this); }; 00204 00205 00209 virtual gnssEquationDefinition getDefaultEqDefinition() const 00210 { return defaultEqDef; }; 00211 00212 00214 virtual int getIndex(void) const; 00215 00216 00218 virtual std::string getClassName(void) const; 00219 00220 00222 virtual ~SolverLMS() {}; 00223 00224 00225 protected: 00226 00227 00231 gnssEquationDefinition defaultEqDef; 00232 00233 00234 private: 00235 00236 00238 static int classIndex; 00239 00240 00242 int index; 00243 00244 00246 void setIndex(void) 00247 { index = classIndex++; }; 00248 00249 00250 00251 }; // End of class 'SolverLMS' 00252 00254 00255 } // End of namespace gpstk 00256 #endif // SOLVERLMS_HPP
1.3.9.1