<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN">
<html><body style='font-family: Verdana,Geneva,sans-serif'>
<p>As written (with or without the commenting out) that code won't produce phase shifts. In technical terms it's a FIR filter that is symmetrical around zero delay, and such filters do not introduce phase shifts.</p>
<p> </p>
<p>On 2016-04-03 22:47, Claus Futtrup wrote:</p>
<blockquote type="cite" style="padding-left:5px; border-left:#1010ff 2px solid; margin-left:5px"><!-- html ignored --><!-- head ignored --><!-- meta ignored -->
<div class="moz-cite-prefix">Hi Buk<br /><br /> When data goes zig-zag like that, I'm sometimes successful with a Bartlett (triangular) smoothing window of only very few points (like 3 points).<span style="color: #64ae64; font-style: italic;"><br /><br /> // function [out]=bartlett3p(indata) // for smoothing (when plotting)</span><br /><span style="color: #64ae64; font-style: italic;"> // out = indata;</span><br /><span style="color: #64ae64; font-style: italic;"> // if length(indata)</span><span style="color: #64ae64; font-style: italic;">></span><span style="color: #64ae64; font-style: italic;">2 then</span><br /><span style="color: #64ae64; font-style: italic;"> // out(2:$-1) = 0.25*indata(1:$-2) + 0.5*indata(2:$-1) + 0.25*indata(3:$);</span><br /><span style="color: #64ae64; font-style: italic;"> // end // Bartlett Window = Triangular window</span><br /><span style="color: #64ae64; font-style: italic;">endfunction</span><br /><br /> Yes, it will affect your data, probably introduce phase shifts.<br /><br /> Best regards,<br /> Claus<br /><br /> On 03-04-2016 21:09, <a class="moz-txt-link-abbreviated" href="mailto:scilab.20.browseruk@xoxy.net">scilab.20.browseruk@xoxy.net</a> wrote:</div>
<blockquote type="cite" style="padding-left:5px; border-left:#1010ff 2px solid; margin-left:5px">
<pre>HI,
The data I'm dealing with is experimentally produced; and thus contains occasional, localised discontinuities (inflections), that I need to remove before that data is suitable for is use in FEM modeling software, which requires that it be strictly monotonic. The attachment shows the full curve plus a close up of a couple of examples of the type of discontinuity I need to deal with.
I haven't yet decided whether to simply omit points (thus connect A to F & G to J) or whether to retain the same number of points by interpolating new points onto that line as shown in red.
I've looked and played several of the smoothing, convolution and interpolation routines that scilab provides, but (besides that I don't understand the output some of them produce) they also seem to affect the data more than I would like. Some seem to introduce a 'phase shift'; others smooth out larger scale bumps in the curve that need to be retained; and others generate many extra points which I don't think is helpful, the FEM software is going to do its own interpolations anyway.
But the bit I'm asking about here is how to detect point A&F and G&J?
Any thoughts or pointers as to a) the algorithm to use; b) how to implement it in SciLab?
Cheers, Buk.
____________________________________________________________
Can't remember your password? Do you need a strong and secure password?
Use Password manager! It stores your passwords & protects your account.
Check it out at <a class="moz-txt-link-freetext" href="http://mysecurelogon.com/password-manager">http://mysecurelogon.com/password-manager</a>
</pre>
<br /><fieldset class="mimeAttachmentHeader"></fieldset><br />
<pre>_______________________________________________
users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:users@lists.scilab.org">users@lists.scilab.org</a>
<a class="moz-txt-link-freetext" href="http://lists.scilab.org/mailman/listinfo/users">http://lists.scilab.org/mailman/listinfo/users</a>
</pre>
</blockquote>
<br /><!-- html ignored --><br />
<pre>_______________________________________________
users mailing list
<a href="mailto:users@lists.scilab.org">users@lists.scilab.org</a>
<a href="http://lists.scilab.org/mailman/listinfo/users">http://lists.scilab.org/mailman/listinfo/users</a>
</pre>
</blockquote>
<p> </p>
<div> </div>
</body></html>