Changeset 565 for library/bdm/design

Show
Ignore:
Timestamp:
08/19/09 16:54:24 (15 years ago)
Author:
vbarta
Message:

using own error macros (basically copied from IT++, but never aborting)

Location:
library/bdm/design
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • library/bdm/design/ctrlbase.cpp

    r508 r565  
    88        dimu = B0.cols(); 
    99 
    10         it_assert_debug ( A0.cols() == dimx, "LQG: A is not square" ); 
    11         it_assert_debug ( B0.rows() == dimx, "LQG: B is not compatible" ); 
    12         it_assert_debug ( C0.cols() == dimx, "LQG: C is not square" ); 
     10        bdm_assert_debug ( A0.cols() == dimx, "LQG: A is not square" ); 
     11        bdm_assert_debug ( B0.rows() == dimx, "LQG: B is not compatible" ); 
     12        bdm_assert_debug ( C0.cols() == dimx, "LQG: C is not square" ); 
    1313 
    1414        A=A0; 
     
    2020 
    2121void LQG::set_control_parameters(const mat &Qy0, const mat &Qu0, const vec y_req0, int horizon0){ 
    22         it_assert_debug ( Qy0.cols() == dimy, "LQG: wrong dimensions of Qy " ); 
    23         it_assert_debug ( Qu0.cols() == dimu, "LQG: wrong dimensions of Qu " ); 
    24         it_assert_debug ( y_req0.length() == dimy, "LQG: wrong dimensions of y_req " ); 
     22        bdm_assert_debug ( Qy0.cols() == dimy, "LQG: wrong dimensions of Qy " ); 
     23        bdm_assert_debug ( Qu0.cols() == dimu, "LQG: wrong dimensions of Qu " ); 
     24        bdm_assert_debug ( y_req0.length() == dimy, "LQG: wrong dimensions of y_req " ); 
    2525 
    2626        Qy=Qy0; 
  • library/bdm/design/ctrlbase.h

    r508 r565  
    1919        public: 
    2020                //! Redesign control strategy  
    21                 virtual void redesign(){it_error("Not implemented"); }; 
     21                virtual void redesign() { 
     22                        bdm_error("Not implemented"); 
     23                } 
     24 
    2225                //! apply control strategy to obtain control input 
    23                 virtual vec apply(const vec &cond){it_error("Not implemented"); return vec(0);} 
     26                virtual vec apply(const vec &cond) { 
     27                        bdm_error("Not implemented"); 
     28                        return vec(); 
     29                } 
    2430}; 
    2531 
     
    8995                        pre_qr.set_submatrix(0,0,s*pr); 
    9096                        pre_qr.set_submatrix(dimx+dimu+dimy, dimu+dimx, -Qy*y_req); 
    91                         if (!qr(pre_qr,post_qr)) it_warning("QR in LQG unstable"); 
     97                        if (!qr(pre_qr,post_qr)) bdm_warning("QR in LQG unstable"); 
    9298                        triu(post_qr); 
    9399        // hn(m+1:2*m+n+r,m+1:2*m+n+r);