home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 10 / 10.iso / l / l455 / 7.ddi / ROBUST.DI$ / ISSYSTEM.M < prev    next >
Encoding:
Text File  |  1993-03-11  |  481 b   |  22 lines

  1. function [i,ty,n]=issytem(x)
  2. %  [I,TY,N]=ISSYSTEM(X) checks whether or not X is a system created by
  3. %  the function MKSYS.  If X is a system, then 
  4. %                I    =  1
  5. %                TY   =  system type
  6. %                N    =  number of matrices in the system (depends on TY)
  7. %  Otherwise, I=0, TY=[] and N=0.
  8.  
  9. i=0;
  10. ty=[];
  11. n=0;
  12. [j,b]=istree(x,'ty');
  13. sysmagic=27591;
  14. if j,
  15.   if x(4)==sysmagic,
  16.      i=1;
  17.      ty=b;
  18.      [junk,n]=vrsys(ty);
  19.   end
  20. end
  21.  
  22.