hi, I have finalized the new version of resample.m I proposed last week. the source is attached to this message. i have made the changes you suggested. in particular it includes several tests which can be performed with the "test" utility.
do I have the green light for replacing the current resample.m by this one? eric. > > hi, > > > > I have rewritten resample.m using a polyphase implementation. > > See codes attached to this message. > > > > With the test resample_test.m, I compare this code to the current version > > of resample.m in OctaveForge. The test consists in > > resampling sinusoids of various frequencies and evaluate the discrepancy > > between the result of the resampling algorithm and > > the exact waveform one expects. > > > > in (a), one sees that the RMS error of > > OctaveForge's resample.m is large and this is > > due to a spurious phase shift in the resampled > > time-series (see (c) red and blue). > > > > in (b), the rejection of OctaveForge's resample.m > > appears to be quite poor. > > > > I've checked that the polyphase version satisfies the > > specifications (rolloff width and rejection in the > > stopband) of the antialiasing filter (blue dash lines > > in (a) and (b)). > > > > I suggest to replace resample.m with my code. > Other people will have to comment the algorithm as I'm not qualified. I > do have a few comments: > > 1) Your implementation is not documented. I know this is the boring > part, but it really needs to be done. Otherwise people can only use the > program if they read the actual code. > > 2) You should add a version number to the GPL license. I would prefer if > you chose GPL version 3 (or later) as this is what Octave uses. > > 3) There is no need to add a semi-colon (;) after 'end*' keywords. So, > you don't have to write "endif;", you can just use "endif". The same > goes for "endwhile", "endfor", and so on. > > 4) I didn't read your test program, but it might be nice if this was > added as a test or demo in the actual implementation, using "%!test" or > "%!demo". > > Thanks, > Søren > >
resample.m
Description: Binary data
------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________ Octave-dev mailing list Octave-dev@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/octave-dev