File: spantwo.cat

package info (click to toggle)
scilab 2.6-4
  • links: PTS
  • area: non-free
  • in suites: woody
  • size: 54,632 kB
  • ctags: 40,267
  • sloc: ansic: 267,851; fortran: 166,549; sh: 10,005; makefile: 4,119; tcl: 1,070; cpp: 233; csh: 143; asm: 135; perl: 130; java: 39
file content (54 lines) | stat: -rw-r--r-- 1,647 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
spantwo           Scilab Group           Scilab Function            spantwo
NAME
   spantwo - sum and intersection of subspaces
  
CALLING SEQUENCE
 [Xp,dima,dimb,dim]=spantwo(A,B, [tol])
PARAMETERS
 A, B       : two real or complex matrices with equal number of rows
            
 Xp         : square non-singular matrix
            
 dima, dimb, dim
             : integers, dimension of subspaces
            
 tol        : nonnegative real number
            
DESCRIPTION
   Given two matrices A and B with same number of rows, returns a square
  matrix Xp (non singular but not necessarily orthogonal)  such that :
  
          [A1, 0]    (dim-dimb rows)
 Xp*[A,B]=[A2,B2]    (dima+dimb-dim rows)
          [0, B3]    (dim-dima rows)
          [0 , 0]
   The  first dima  columns of inv(Xp) span range(A).
  
   Columns dim-dimb+1 to dima of inv(Xp) span the  intersection of range(A)
  and range(B).
  
   The dim first columns of inv(Xp) span  range(A)+range(B).
  
   Columns dim-dimb+1 to dim of inv(Xp) span  range(B). 
  
   Matrix [A1;A2] has full row rank (=rank(A)). Matrix [B2;B3] has full row
  rank (=rank(B)). Matrix [A2,B2] has full row rank (=rank(A inter B)).
  Matrix [A1,0;A2,B2;0,B3] has full row rank (=rank(A+B)).
  
EXAMPLE
 A=[1,0,0,4;
    5,6,7,8;
    0,0,11,12;
    0,0,0,16];
 B=[1,2,0,0]';C=[4,0,0,1]; 
 Sl=ss2ss(syslin('c',A,B,C),rand(A));
 [no,X]=contr(Sl('A'),Sl('B'));CO=X(:,1:no);  //Controllable part
 [uo,Y]=unobs(Sl('A'),Sl('C'));UO=Y(:,1:uo);  //Unobservable part
 [Xp,dimc,dimu,dim]=spantwo(CO,UO);    //Kalman decomposition
 Slcan=ss2ss(Sl,inv(Xp));
SEE ALSO
   spanplus, spaninter
  
AUTHOR
   F. D.