This repository has been archived by the owner on Sep 30, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 5
/
estProbe.m
81 lines (69 loc) · 3.26 KB
/
estProbe.m
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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
function R = estProbe(sys,m,l)
%%% project: emgr - EMpirical GRamian Framework ( https://gramian.de )
%%% version: 5.99 (2022-04-13)
%%% authors: Christian Himpe (0000-0003-2194-6754)
%%% license: BSD-2-Clause (opensource.org/licenses/BSD-2-Clause)
%%% summary: estProbe - factorial test of emgr option flags
% sys: [], system-structure
% m: "controllability", "observability", "minimality"
% l: "linear", "nonlinear"
disp(['Explore: ',m,' - ',l]);
if isempty(sys)
M = 1;
N = 16;
A = full(-gallery('tridiag',N));
A(1,1) = -1;
B = double(1:N==1)';
C = B';
sys = struct('M',M, ...
'N',N, ...
'Q',M, ...
'f',@(x,u,p,t) A*x + B*u, ...
'g',@(x,u,p,t) C*x, ...
'F',@(x,u,p,t) (x'*A + u'*C)', ...
'p',zeros(N,1), ...
'dt',0.01, ...
'Tf',1.0);
end%if
T = 0;
R = NaN;
for n = {'unit','lie','hyp','quadratic','cubic','sigmoid','mercersigmoid','logarithmic','exponential','gauss','dmd','single'}
for o = {'impulse','step','sinc','chirp','random'}
for p = {'none','linear','quadratic','state','scale','rsqrt'}
for q = {'none','steady','final','mean','rms','midrange'}
for r = {'none','steady','jacobi'}
for s = {'standard','special'}
for t = {'no','yes'}
try
S = est(sys, ...
struct('type','singular_values', ...
'method',m), ...
struct('linearity',l, ...
'kernel',n{:}, ...
'training',o{:}, ...
'weighting',p{:}, ...
'centering',q{:}, ...
'rotations','single', ...
'normalize',r{:}, ...
'stype',s{:}, ...
'extra_input',t{:}, ...
'test',true,'score',true));
if (T < S) && (S < 1)
T = S;
R = struct('kernel',n{:}, ...
'training',o{:}, ...
'weighting',p{:}, ...
'centering',q{:}, ...
'normalize',r{:}, ...
'stype',s{:}, ...
'extra_input',t{:});
end%if
end%try
end%for
end%for
end%for
end%for
end%for
end%for
end%for
end