home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 10 / 10.iso / l / l455 / 9.ddi / IDENT.DI$ / CONTTH.M < prev    next >
Encoding:
Text File  |  1993-03-11  |  609 b   |  21 lines

  1. function [a,b,c,d]=contth(ad,bd,cd,dd,T,flag)
  2. %CONTTH    Is an auxiliary function for eta2ss and thss2th
  3. %
  4. %    [a,b,c,d] = contth(ad,bd,cd,dd,T,flag)
  5. %
  6.  
  7. %    L. Ljung 10-2-1990
  8. %    Copyright (c) 1990 by the MathWorks, Inc.
  9. %    All Rights Reserved
  10.  
  11. if flag
  12. if exist('minreal'), eval('[ad,bd,cd,dd] = minreal(ad,bd,cd,dd);');
  13. else, error('The command does not handle multioutput, continuous time ARX-models without the CONTROL SYSTEMS TOOLBOX. See contth.m!'),end
  14. end
  15. [m,n] = size(ad);
  16. [m,nb] = size(bd);
  17. s = real(logm([[ad bd]; zeros(nb,n) eye(nb)]))/T;
  18. a = s(1:n,1:n);
  19. b = s(1:n,n+1:n+nb);
  20. c=cd;d=dd;
  21.