|Martin Larsen on Sat, 13 Oct 2007 01:27:44 +0200|
[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]
> On Thu, Oct 11, 2007 at 05:24:43PM +0200, Martin Larsen wrote:|
> > Hi
> > I have a suggestion for a new feature, but first I will mention a few problems with GP/PARI CALCULATOR Version 2.4.1 (alpha) on Windows.
> > * a script loaded at startup will not have it's local()'s recognized (they become global)
> Could you give an example ? local() are only supported inside functions
> in GP 2.4.1.
Let's say you have loaded this function from a script at start:
then try this
k: user defined variable
Now you can't do this
*** unused characters: k(m)=m++
> > * a script with syntax error loaded with \r will prevent any new attempt of loading it.
Let's say a ";" was forgotten in the above function, then you can't load it again when you have corrected it. I have not experienced this in older versions.
> > * flag==4 in vecsort produces an error
> A GP 2.4.1 specific bug which was a pretty buggy development release,
> alas! Try out GP 2.3.2 which is much more solid.
> > And now a little funny example:
> > > k=1;vector(6,i,[k,k=k*10%7])
> > %1 = [32, 3, 32, 6, 32, 5]
> This is a well-know bug with the memory handling: GP forget to copy
> the first k in the vector. This is fixed in the forthcoming GP 2.4.2
> I recorded it as bug #686.
> > > k=1;vector(6,i,[k*1,k=k*10%7])
> > %2 = [1, 3, 2, 6, 4, 5]
> > I think this is a nice way if you don't want the result from the last _expression_(?)
> > Only 2. example works as expected, but is the method safe?
> Actually yes, but you could just do
> which is safe.
Yes but "ad hoc" variables are ugly.
> > I think it would be nice to be allowed to exclude unused locals in vector and matrix.
> This would clash with the current interface design: there is no
> > And last - Wouldn't it be nice if we had a standard-script that
> > followed Pari with lots of extra functions, where functions could be
> > loaded as last resort on demand?
> What we need is standardised way to write and publish library of GP
> functions. Would you like to try ?
I think the old and experienced guys should lay out the principles.
But what did you think of the concept of loading functions from a standard script? eg: if I want partitions, then Pari don't know what that is and start looking in this script and find it there without loading other things from that script.
Få Messenger og Hotmail på mobilen. Windows Live Mobile