On Fri, Oct 23, 2009 at 9:39 AM, Søren Hauberg <[email protected]> wrote:
> fre, 23 10 2009 kl. 10:43 +1100, skrev Pierre Lonchampt:
>> Thanks a lot Soren, apologies for my incomplete reporting;
>> Your patch works for my application indeed.
>>
>> an example being:
>>
>> octave:22> x=rand(1,60)
>> octave:23> y=xcorr(x,70,'coeff')
>> octave:24> size(y)
>> ans =
>>
>>      1   141
>>
>> which was giving previously an error...now giving a result similar to
>> Matlab
>
> Okay, thanks.
>
>> Pushing it a bit further, I just found some other minor discrepancies:
>>
>> Octave 3.0.1 (with the xcorr+your patch)
>> octave:14> xcorr(ones(1,2),ones(1,3),2)
>> ans =
>>
>>    1.0000e+00   2.0000e+00   2.0000e+00   1.0000e+00   1.3878e-17
>>
>> MAtlabR11:
>> » xcorr(ones(1,2),ones(1,3),2)
>>
>> ans =
>>
>>          0    1.0000    2.0000    2.0000    1.0000
>
> I'd like to fix this but I am unsure if I can. See below.
>
>> I attach the matlab xcorr.m file if that can help.
>
> NEVER EVER EVER do this! This code belongs to Mathworks and not to you,
> so you don't have the rights to distribute it. By distributing this file
> you are violating Mathworks copyright. While I did not look at the code
> you sent me off-list, I am unsure if I can look into the problem any
> more.

I think you're overreacting a bit, Soren. In fact, even if you did
look, no law does prohibit reading, only copying. If you inspect a
m-file from Matlab to learn just the trick, and don't actually
memorize and reproduce any code, it's technically still legal.
But in any case, you said you didn't look, so you didn't look and that
settles it. Innocent until proved guilty.

-- 
RNDr. Jaroslav Hajek
computing expert & GNU Octave developer
Aeronautical Research and Test Institute (VZLU)
Prague, Czech Republic
url: www.highegg.matfyz.cz

------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay 
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
Octave-dev mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/octave-dev

Reply via email to