Changeset 67
- Timestamp:
- 04/09/08 15:40:33 (17 years ago)
- Location:
- bdm
- Files:
-
- 4 modified
Legend:
- Unmodified
- Added
- Removed
-
bdm/estim/libKF.cpp
r62 r67 62 62 63 63 /////////////////////////////// EKFS 64 EKFfull::EKFfull ( RV rvx0, RV rvy0, RV rvu0 ) : BM ( rvx0 ) {};64 EKFfull::EKFfull ( RV rvx0, RV rvy0, RV rvu0 ) : BM ( rvx0 ),E(rvx0) {}; 65 65 66 66 void EKFfull::set_parameters ( diffbifn* pfxu0, diffbifn* phxu0,const mat Q0,const mat R0 ) { … … 105 105 mu += _K* ( y-yp ); 106 106 107 E.set_mu(mu); 108 107 109 if ( BM::evalll ) { 108 110 //from enorm -
bdm/estim/libKF.h
r62 r67 173 173 */ 174 174 class EKFfull : public KalmanFull, public BM { 175 175 176 //! Internal Model f(x,u) 176 177 diffbifn* pfxu; 177 178 //! Observation Model h(x,u) 178 179 diffbifn* phxu; 180 181 enorm<fsqmat> E; 179 182 public: 180 183 //! Default constructor … … 187 190 void set_est (vec mu0, mat P0){mu=mu0;P=P0;}; 188 191 //!dummy! 189 epdf& _epdf(){ enorm<fsqmat> E(rv);return E;};192 epdf& _epdf(){return E;}; 190 193 }; 191 194 -
bdm/estim/libPF.h
r60 r67 171 171 } 172 172 173 _w /=sum ( _w ); //? 174 173 if (sum(_w)>0.0){ 174 _w /=sum ( _w ); //? 175 } 176 else 177 { 178 cout<<"sum(w)==0"<<endl; 179 } 175 180 176 181 177 182 double eff = 1.0/ ( _w*_w ); 178 if ( eff < ( 0. 1*n ) ) {183 if ( eff < ( 0.3*n ) ) { 179 184 ind = est.resample(); 180 185 // Resample Bms! -
bdm/stat/libEF.h
r60 r67 101 101 //! returns a pointer to the internal mean value. Use with Care! 102 102 vec* _mu() {return μ} 103 104 //! access function 105 void set_mu(const vec mu0) { mu=mu0;} 103 106 104 107 //! returns pointers to the internal variance and its inverse. Use with Care!