Mercurial > hg > ltpda
comparison m-toolbox/html_help/help/ug/sdomainfit_content.html @ 0:f0afece42f48
Import.
author | Daniele Nicolodi <nicolodi@science.unitn.it> |
---|---|
date | Wed, 23 Nov 2011 19:22:13 +0100 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:f0afece42f48 |
---|---|
1 <!-- $Id: sdomainfit_content.html,v 1.3 2009/08/27 11:38:58 luigi Exp $ --> | |
2 | |
3 <!-- ================================================== --> | |
4 <!-- BEGIN CONTENT FILE --> | |
5 <!-- ================================================== --> | |
6 <!-- ===== link box: Begin ===== --> | |
7 <p> | |
8 <table border="1" width="80%"> | |
9 <tr> | |
10 <td> | |
11 <table border="0" cellpadding="5" class="categorylist" width="100%"> | |
12 <colgroup> | |
13 <col width="37%"/> | |
14 <col width="63%"/> | |
15 </colgroup> | |
16 <tbody> | |
17 <tr valign="top"> | |
18 <td> | |
19 <a href="#description">Description</a> | |
20 </td> | |
21 <td>S-domain system identification in LTPDA.</td> | |
22 </tr> | |
23 <tr valign="top"> | |
24 <td> | |
25 <a href="#algorithm">Algorithm</a> | |
26 </td> | |
27 <td>Fit Algorithm.</td> | |
28 </tr> | |
29 <tr valign="top"> | |
30 <td> | |
31 <a href="#examples">Examples</a> | |
32 </td> | |
33 <td>Usage example of s-domain system identification tool.</td> | |
34 </tr> | |
35 <tr valign="top"> | |
36 <td> | |
37 <a href="#references">References</a> | |
38 </td> | |
39 <td>Bibliographic references.</td> | |
40 </tr> | |
41 </tbody> | |
42 </table> | |
43 </td> | |
44 </tr> | |
45 </table> | |
46 </p> | |
47 <!-- ===== link box: End ====== --> | |
48 | |
49 <h2><a name="description">S-domain system identification in LTPDA</a></h2> | |
50 <p> | |
51 System identification in s-domain is performed with the function | |
52 <a href="matlab:doc('ao/sDomainFit')">sDomainFit</a>. | |
53 It is based on a modeified version of the vector fitting algorithm. | |
54 Details on the core agorithm can be found in [1 - 2]. | |
55 </p> | |
56 | |
57 | |
58 | |
59 <h2><a name="algorithm">Fit Algorithm</a></h2> | |
60 | |
61 <p> | |
62 The function performs a fitting loop to automatically identify model | |
63 order and parameters in s-domain. Output is a s-domain model expanded | |
64 in partial fractions: | |
65 </p> | |
66 <div class="fragment"><pre> | |
67 r1 rN | |
68 f(s) = ------- + ... + ------- + d | |
69 s - p1 s - pN | |
70 </pre></div> | |
71 <p> | |
72 Since the function can fit more than one input analysis object at a time | |
73 with a common set of poles, output | |
74 <a href="parfrac.html">parfrac</a> are embedded in a | |
75 <a href="class_desc_matrix.html">matrix</a> (note that this characteristic | |
76 will be probably changed becausse of the introduction of the | |
77 <a href="class_desc_collection.html">collection</a> class). | |
78 </p> | |
79 <p> | |
80 Identification loop stops when the stop condition is reached. | |
81 Stop criterion is based on three different approachs: | |
82 <ol> | |
83 <li> Mean Squared Error and variation <br> | |
84 Check if the normalized mean squared error is lower than the value specified in | |
85 <tt>FITTOL</tt> and if the relative variation of the mean squared error is lower | |
86 than the value specified in <tt>MSEVARTOL</tt>. | |
87 E.g. <tt>FITTOL = 1e-3</tt>, <tt>MSEVARTOL = 1e-2</tt> search for a fit with | |
88 normalized meam square error lower than <tt>1e-3</tt> and <tt>MSE</tt> relative | |
89 variation lower than <tt>1e-2</tt>. | |
90 </li> | |
91 <li> Log residuals difference and root mean squared error | |
92 <ul> | |
93 <li> Log Residuals difference </br> | |
94 Check if the minimum of the logarithmic difference between data and | |
95 residuals is larger than a specified value. ie. if the conditioning | |
96 value is <tt>2</tt>, the function ensures that the difference between data and | |
97 residuals is at lest two order of magnitude lower than data itsleves. | |
98 <li> Root Mean Squared Error </br> | |
99 Check that the variation of the root mean squared error is lower than | |
100 <tt>10^(-1*value)</tt>. | |
101 </ul> | |
102 </li> | |
103 <li> Residuals spectral flatness and root mean squared error | |
104 <ul> | |
105 <li> Residuals Spectral Flatness </br> | |
106 In case of a fit on noisy data, the residuals from a good fit are | |
107 expected to be as much as possible similar to a white noise. This | |
108 property can be used to test the accuracy of a fit procedure. In | |
109 particular it can be tested that the spectral flatness coefficient of | |
110 the residuals is larger than a certain qiantity sf such that <tt>0 < sf < 1</tt>. | |
111 <li> Root Mean Squared Error </br> | |
112 Check that the variation of the root mean squared error is lower than | |
113 <tt>10^(-1*value)</tt>. | |
114 </ul> | |
115 </li> | |
116 </ol> | |
117 | |
118 </p> | |
119 <p> | |
120 The function can also perform a single loop without taking care of | |
121 the stop conditions. This happens when <span class="string">'AutoSearch'</span> parameter is | |
122 set to <span class="string">'off'</span>. | |
123 </p> | |
124 | |
125 | |
126 <h2><a name="examples">Usage example of s-domain system identification tool</a></h2> | |
127 <p> | |
128 In this example we fit a given frequency response to get a partial fraction model. | |
129 For the meaning of any parameter please refer to | |
130 <a href="matlab:doc('ao')">ao</a> and | |
131 <a href="matlab:doc('ao/sDomainFit')">sDomainFit</a> | |
132 documentation pages. | |
133 </p> | |
134 | |
135 <div class="fragment"><pre> | |
136 pl = plist(... | |
137 <span class="string">'fsfcn'</span>, <span class="string">'(1e-3./(f).^2 + 1e3./(0.001+f) + 1e5.*f.^2).*1e-10'</span>,... | |
138 <span class="string">'f1'</span>, 1e-6,... | |
139 <span class="string">'f2'</span>, 5,... | |
140 <span class="string">'nf'</span>, 100); | |
141 | |
142 a = ao(pl); | |
143 a.setName; | |
144 | |
145 <span class="comment">% Fit parameter list</span> | |
146 pl_fit = plist(... | |
147 <span class="string">'AutoSearch'</span>,<span class="string">'on'</span>,... | |
148 <span class="string">'StartPolesOpt'</span>,<span class="string">'clog'</span>,... | |
149 <span class="string">'maxiter'</span>,50,... | |
150 <span class="string">'minorder'</span>,7,... | |
151 <span class="string">'maxorder'</span>,15,... | |
152 <span class="string">'weightparam'</span>,<span class="string">'abs'</span>,... | |
153 <span class="string">'CONDTYPE'</span>,<span class="string">'MSE'</span>,... | |
154 <span class="string">'FITTOL'</span>,1e-3,... | |
155 <span class="string">'MSEVARTOL'</span>,1e-2,... | |
156 <span class="string">'Plot'</span>,<span class="string">'on'</span>,... | |
157 <span class="string">'ForceStability'</span>,<span class="string">'off'</span>); | |
158 | |
159 <span class="comment">% Do fit</span> | |
160 mod = sDomainFit(a, pl_fit); | |
161 </pre></div> | |
162 | |
163 <p> | |
164 <tt>mod</tt> is a <tt>matrix</tt> object containing a <tt>parfrac</tt> object. | |
165 </p> | |
166 | |
167 <div class="fragment"><pre> | |
168 >> mod | |
169 ---- matrix 1 ---- | |
170 name: fit(a) | |
171 size: 1x1 | |
172 01: parfrac | parfrac(fit(a)) | |
173 description: | |
174 UUID: 2dc1ac28-4199-42d2-9b1a-b420252b3f8c | |
175 ------------------ | |
176 </pre></div> | |
177 | |
178 <div class="fragment"><pre> | |
179 >> mod.objs | |
180 ---- parfrac 1 ---- | |
181 model: fit(a) | |
182 res: [1.69531090137847e-006;-1.69531095674486e-006;1.39082537801437e-007;-1.39094453401266e-007;3.9451875151135e-007;-3.94524993613367e-007;4.53671387948961e-007;-4.53664974359603e-007;1124.81020427899;0.000140057852149302-i*0.201412268649905;0.000140057852149302+i*0.201412268649905] | |
183 poles: [-1.18514026248382e-006;1.18514354570495e-006;-0.00457311582050939;0.0045734088943545;-0.0316764149343339;0.0316791653277322;-0.276256442292693;0.27627799022013;330754.550617933;-0.0199840558095427+i*118.439896186467;-0.0199840558095427-i*118.439896186467] | |
184 dir: 0 | |
185 pmul: [1;1;1;1;1;1;1;1;1;1;1] | |
186 iunits: [] | |
187 ounits: [] | |
188 description: | |
189 UUID: 2afc4c82-7c2a-4fe3-8910-d8590884d58c | |
190 ------------------- | |
191 </pre></div> | |
192 | |
193 | |
194 <h2><a name="references">References</a></h2> | |
195 <p> | |
196 <ol> | |
197 <li> B. Gustavsen and A. Semlyen, "Rational approximation of frequency | |
198 domain responses by Vector Fitting", IEEE Trans. Power Delivery | |
199 vol. 14, no. 3, pp. 1052-1061, July 1999. | |
200 <li> B. Gustavsen, "Improving the Pole Relocating Properties of Vector | |
201 Fitting", IEEE Trans. Power Delivery vol. 21, no. 3, pp. | |
202 1587-1592, July 2006. | |
203 </ol> | |
204 </p> |