comparison m-toolbox/html_help/help/ug/sigproc_diff_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: sigproc_diff_content.html,v 1.10 2011/04/05 08:12:13 hewitson 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>Discrete derivative estimation in LTPDA.</td>
22 </tr>
23 <tr valign="top">
24 <td>
25 <a href="#algorithm">Algorithm</a>
26 </td>
27 <td>Derivatives Algorithms.</td>
28 </tr>
29 <tr valign="top">
30 <td>
31 <a href="#examples">Examples</a>
32 </td>
33 <td>Usage examples of discrete derivative estimation tools.</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
50
51 <p>
52
53 </p>
54
55
56 <h2><a name="description">Derivative calculation for dicrete data series</a></h2>
57
58 <p>
59 Derivative estimation on discrete data series is implemented by the function
60 <a href="matlab:doc('ao/diff')">ao/diff</a>.
61 This function embeds several algorithms for the calculation
62 of zero, first and second order derivative. Where with zero order derivative we intend
63 a particular category of data smoothers [1].
64 </p>
65
66
67
68 <h2><a name="algorithm">Algorithm</a></h2>
69
70 <p>
71 <table cellspacing="0" class="body" cellpadding="2" border="0" width="80%">
72 <colgroup>
73 <col width="15%"/>
74 <col width="85%"/>
75 </colgroup>
76 <thead>
77 <tr valign="top">
78 <th class="categorylist">Method</th>
79 <th class="categorylist">Description</th>
80 </tr>
81 </thead>
82 <tbody>
83 <tr valign="top">
84 <td bgcolor="#f3f4f5">
85 <p><span class="string">'2POINT'</span></p>
86 </td>
87 <td bgcolor="#f3f4f5">
88 <p>
89 Compute first derivative with two point equation according to:
90 <div align="center">
91 <IMG src="images/sigproc_diff_algo01.gif" align="center" border="0">
92 </div>
93 </p>
94 </td>
95 </tr>
96 <tr valign="top">
97 <td bgcolor="#f3f4f5">
98 <p><span class="string">'3POINT'</span></p>
99 </td>
100 <td bgcolor="#f3f4f5">
101 <p>
102 Compute first derivative with three point equation according to:
103 <div align="center">
104 <IMG src="images/sigproc_diff_algo02.gif" align="center" border="0">
105 </div>
106 </p>
107 </td>
108 </tr>
109 <tr valign="top">
110 <td bgcolor="#f3f4f5">
111 <p><span class="string">'5POINT'</span></p>
112 </td>
113 <td bgcolor="#f3f4f5">
114 <p>
115 Compute first derivative with five point equation according to:
116 <div align="center">
117 <IMG src="images/sigproc_diff_algo03.gif" align="center" border="0">
118 </div>
119 </p>
120 </td>
121 </tr>
122 <tr valign="top">
123 <td bgcolor="#f3f4f5">
124 <p><span class="string">'FPS'</span></p>
125 </td>
126 <td bgcolor="#f3f4f5">
127 <p>
128 Five Point Stencil is a generalized method to calculate zero, first and second
129 order discrete derivative of a given time series. Derivative approximation,
130 at a given time <i>t = kT</i> (<i>k</i> being an integer and <i>T</i>
131 being the sampling time), is calculated by means of finite differences
132 between the element at <i>t</i> with its four neighbors:
133 <div align="center">
134 <IMG src="images/sigproc_diff_algo04.gif" align="center" border="0">
135 </div>
136 </p>
137 <p>
138 It can be demonstrated that the coefficients of the expansion can be
139 expressed as a function of one of them [1]. This allows the construction
140 of a family of discrete derivative estimators characterized by a
141 good low frequency accuracy and a smoothing behavior at high frequencies
142 (near the nyquist frequency). <br/>
143 Non-trivial values for the <span class="string">'COEFF'</span> parameter are:
144 <ul>
145 <li> Parabolic fit approximation <br/>
146 These coefficients can be obtained by a parabolic fit procedure on
147 a generic set of data [1].
148 <ul>
149 <li> Zeroth order -3/35
150 <li> First order -1/5
151 <li> Second order 2/7
152 </ul>
153 <li> Taylor series expansion <br/>
154 These coefficients can be obtained by a series expansion of a generic set of data [1 - 3].
155 <ul>
156 <li> First order 1/12
157 <li> Second order -1/12
158 </ul>
159 <li> PI <br/>
160 This coefficient allows to define a second derivative estimator with
161 a notch feature at the nyquist frequency [1].
162 <ul>
163 <li> Second order 1/4
164 </ul>
165 </ul>
166 </p>
167 </td>
168 </tr>
169 </tbody>
170 </table>
171 </p>
172
173 <h2><a name="examples"></a>Examples</h2>
174
175 Consider <tt>a</tt> as a time series analysis object. First and second
176 derivative of <tt>a</tt> can be easily obtained with a call to
177 <a href="matlab:doc('ao/diff')">diff</a>. Please refer to
178 <a href="matlab:doc('ao/diff')">ao/diff</a> documantation page for the
179 meaning of any parameter.
180 <p>
181 Frequency response of first and second order estimators is reported in
182 figures 1 and 2 respectively.
183 </p>
184
185 <h3>First derivative</h3>
186
187 <div class="fragment"><pre>
188
189 pl = plist(...
190 <span class="string">'method'</span>, <span class="string">'2POINT'</span>);
191 b = diff(a, pl);
192
193 pl = plist(...
194 <span class="string">'method'</span>, <span class="string">'ORDER2SMOOTH'</span>);
195 c = diff(a, pl);
196
197 pl = plist(...
198 <span class="string">'method'</span>, <span class="string">'3POINT'</span>);
199 d = diff(a, pl);
200
201 pl = plist(...
202 <span class="string">'method'</span>, <span class="string">'5POINT'</span>);
203 e = diff(a, pl);
204
205 pl = plist(...
206 <span class="string">'method'</span>, <span class="string">'FPS'</span>, ...
207 <span class="string">'ORDER'</span>, <span class="string">'FIRST'</span>, ...
208 <span class="string">'COEFF'</span>, -1/5);
209 f = diff(a, pl);
210
211 </pre></div>
212
213 <h3>Second derivative</h3>
214
215 <div class="fragment"><pre>
216
217 pl = plist(...
218 <span class="string">'method'</span>, <span class="string">'FPS'</span>, ...
219 <span class="string">'ORDER'</span>, <span class="string">'SECOND'</span>, ...
220 <span class="string">'COEFF'</span>, 2/7);
221 b = diff(a, pl);
222
223 pl = plist(...
224 <span class="string">'method'</span>, <span class="string">'FPS'</span>, ...
225 <span class="string">'ORDER'</span>, <span class="string">'SECOND'</span>, ...
226 <span class="string">'COEFF'</span>, -1/12);
227 c = diff(a, pl);
228
229 pl = plist(...
230 <span class="string">'method'</span>, <span class="string">'FPS'</span>, ...
231 <span class="string">'ORDER'</span>, <span class="string">'SECOND'</span>, ...
232 <span class="string">'COEFF'</span>, 1/4);
233 d = diff(a, pl);
234
235 </pre></div>
236
237
238 <div align="center">
239 <p>
240 <IMG src="images/sigproc_diff_algo05.png" align="center" border="0">
241 </p>
242 <p>
243 <b> Figure 1:</b> Frequency response of first derivative estimators.
244 </p>
245
246 </div>
247 <div align="center">
248 <p>
249 </p>
250 <IMG src="images/sigproc_diff_algo06.png" align="center" border="0">
251 <p>
252 <b> Figure 2:</b> Frequency response of second derivative estimators.
253 </p>
254 </div>
255
256
257 <h2><a name="references">References</a></h2>
258
259 <ol>
260 <li> L. Ferraioli, M. Hueller and S. Vitale, Discrete derivative
261 estimation in LISA Pathfinder data reduction,
262 <a href="matlab:web('http://www.iop.org/EJ/abstract/0264-9381/26/9/094013/','-browser')">Class. Quantum Grav. 26 (2009) 094013.</a>. <br/>
263 L. Ferraioli, M. Hueller and S. Vitale, Discrete derivative
264 estimation in LISA Pathfinder data reduction
265 <a href="matlab:web('http://arxiv.org/abs/0903.0324v1','-browser')">arXiv:0903.0324v1</a>
266 <li> Steven E. Koonin and Dawn C. Meredith, Computational Physics, Westview Press (1990).
267 <li> John H. Mathews, Computer derivations of numerical differentiation formulae,
268 <i>Int. J. Math. Educ. Sci. Technol.<i>, 34:2, 280 - 287.
269 </ol>
270
271
272
273
274
275
276
277