Changeset 565 for library/bdm/estim/kalman.cpp
- Timestamp:
- 08/19/09 16:54:24 (15 years ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
library/bdm/estim/kalman.cpp
r527 r565 11 11 dimy = C0.rows(); 12 12 13 it_assert_debug ( A0.cols() == dimx, "KalmanFull: A is not square" );14 it_assert_debug ( B0.rows() == dimx, "KalmanFull: B is not compatible" );15 it_assert_debug ( C0.cols() == dimx, "KalmanFull: C is not square" );16 it_assert_debug ( ( D0.rows() == dimy ) || ( D0.cols() == dimu ),"KalmanFull: D is not compatible" );17 it_assert_debug ( ( Q0.cols() == dimx ) || ( Q0.rows() == dimx ), "KalmanFull: Q is not compatible" );18 it_assert_debug ( ( R0.cols() == dimy ) || ( R0.rows() == dimy ), "KalmanFull: R is not compatible" );13 bdm_assert_debug ( A0.cols() == dimx, "KalmanFull: A is not square" ); 14 bdm_assert_debug ( B0.rows() == dimx, "KalmanFull: B is not compatible" ); 15 bdm_assert_debug ( C0.cols() == dimx, "KalmanFull: C is not square" ); 16 bdm_assert_debug ( ( D0.rows() == dimy ) || ( D0.cols() == dimu ), "KalmanFull: D is not compatible" ); 17 bdm_assert_debug ( ( Q0.cols() == dimx ) || ( Q0.rows() == dimx ), "KalmanFull: Q is not compatible" ); 18 bdm_assert_debug ( ( R0.cols() == dimy ) || ( R0.rows() == dimy ), "KalmanFull: R is not compatible" ); 19 19 20 20 A = A0; … … 32 32 33 33 void KalmanFull::bayes ( const vec &dt ) { 34 it_assert_debug ( dt.length() == ( dimy + dimu ), "KalmanFull::bayes wrong size of dt" );34 bdm_assert_debug ( dt.length() == ( dimy + dimu ), "KalmanFull::bayes wrong size of dt" ); 35 35 36 36 vec u = dt.get ( dimy, dimy + dimu - 1 ); … … 86 86 87 87 void EKFfull::bayes ( const vec &dt ) { 88 it_assert_debug ( dt.length() == ( dimy + dimu ), "KalmanFull::bayes wrong size of dt" );88 bdm_assert_debug ( dt.length() == ( dimy + dimu ), "EKFull::bayes wrong size of dt" ); 89 89 90 90 vec u = dt.get ( dimy, dimy + dimu - 1 ); … … 142 142 preA.set_submatrix ( dimy, dimy, ( _P._Ch() ) *A.T() ); 143 143 144 // if ( !qr ( preA,Q,postA ) ) it_warning ( "QR in kalman unstable!" );145 144 if ( !qr ( preA, postA ) ) { 146 it_warning ( "QR in kalmanunstable!" );145 bdm_warning ( "QR in KalmanCh unstable!" ); 147 146 } 148 147 … … 217 216 // cout << "_mu:" << _mu <<endl; 218 217 219 // if ( !qr ( preA,Q,postA ) ) it_warning ( "QR in kalman unstable!" );220 218 if ( !qr ( preA, postA ) ) { 221 it_warning ( "QR in kalmanunstable!" );219 bdm_warning ( "QR in EKFCh unstable!" ); 222 220 } 223 221