File: mu.dem

package info (click to toggle)
scilab 2.4-1
  • links: PTS
  • area: non-free
  • in suites: potato, slink
  • size: 55,196 kB
  • ctags: 38,019
  • sloc: ansic: 231,970; fortran: 148,976; tcl: 7,099; makefile: 4,585; sh: 2,978; csh: 154; cpp: 101; asm: 39; sed: 5
file content (41 lines) | stat: -rw-r--r-- 1,290 bytes parent folder | download | duplicates (4)
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
//test of musolve
// Copyright INRIA
mode(-1)
M1 = [ ..
   5.2829       5.7683      -2.4004       1.2205      -6.4148    
   9.7769e-01   2.9786      -3.0408       5.0257e-01  -2.6504    
   7.0819       9.6324      -3.5750       3.3016      -6.7030    
  -1.6261      -2.9763       1.6870      -1.0603       1.2211    
   2.3056       4.3712      -2.4785       2.6152      -1.9832    ];

M2 = [ ..
  -1.1308      -1.7785       8.7974e-01  -7.5206e-01   1.2089    
  -3.5255e-01  -5.7002e-01   2.9305e-01  -2.5442e-01   3.7691e-01
  -1.3724      -2.1501       1.0741      -9.1188e-01   1.4669   
   3.5839e-01   5.5101e-01  -2.7290e-01   2.3565e-01  -3.7663e-01
  -4.9015e-01  -7.8706e-01   4.0215e-01  -3.3617e-01   5.3261e-01];
//*******************************************************
M=M1 +%i*M2;
// Let the structure be all scalar blocks
K = [1 1 1 1 1]'; 
// Let the first, the third and the fifth blocks be real,
// and let the rest of blocks be complex
T = [1 2 1 2 1]';
[D,g,mu] = musolve(M,K,T);
spec(M'*D*M+%i*(G*M-M'*G')-mu^2*D)


// Now, we compute it again with respect to all complex blocks
T = [2 2 2 2 2]';
[D,g,mu] = musolve(M,K,T);
spec(M'*D*M+%i*(G*M-M'*G')-mu^2*D)


T = 3*[1 1 1 1 1]';
[D,g,mu] = musolve(M,K,T;
//
K = [2 3]';
T = [2 2]';
[D,g,mu] = musolve(M,K,T);