octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: polytrans & polyscale


From: Jaroslav Hajek
Subject: Re: polytrans & polyscale
Date: Fri, 10 Apr 2009 12:54:39 +0200

On Fri, Apr 10, 2009 at 12:19 PM, Thorsten Meyer <address@hidden> wrote:
> Jaroslav Hajek wrote:
>> hi,
>>
>> I recently added the functions polytrans (p(x) -> p(x+a)) and
>> polyscale (p(x) -> p(x*a)) to the scripts/polynomial, though they are
>> not yet added to the build process. Does anyone object to adding these
>> functions definitely? These are not in Matlab core, but then neither
>> is a number of other polynomial functions (polyint, polyout...).
>> Opinons wanted.
>>
> I like those functions. So I vote for adding them to octave.
>
> Still, I have a few remarks:
>  - there seems to be a bug in polytrans: try the example given in the help 
> text.
> It looks as if polytrans calculates f(-x - a)

Works for me. What's your tip? Be aware that I extended "pascal" for
this purpose to be able to return the standard pascal triangle without
unnecessary sign changes.

>  - polyval also contains an option to translate and scale. And it seems to me
> that it will translate into the other direction and scale with the inverse
> compare to polytrans and polyscale. Wouldn't it be better to make those
> functions consistent to avoid confusion?

Yes, that's a good point. I see polyval uses a single array to pass
both parameters, so maybe we should actually do "polytranscale" and
use the same form to be consistent.

>  - I notice that there are no tests included in the functions. Also, there is 
> no
> reference to polyval and polytrans in the manual yet. And the doc strings have
> not been fully translated to texinfo. Don't we have the general rule, that
> tests, manual entry and style compliance are required before adding a new 
> function?
>

As I explained, they're not truly added yet, because they're not
listed in makefiles, so they won't be installed if you install a
snapshot, and they won't go into the autogenerated docs (at least I
hope so). So they're only there if you test development builts "in
place" using run-octave, which is precisely what I wanted. If people
think this is still too bad of a practice, I'll wipe them out. The
benefit is that you can see the history and you won't miss essential
changes (such as the "pascal" extension) if you go via the normal
mercurial way.

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



reply via email to

[Prev in Thread] Current Thread [Next in Thread]