Bill Allombert on Wed, 23 Oct 2013 23:17:10 +0200

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

parallel pari: parfirst

Hello PARI developers,

I am experimenting with a new parallel primitive which is a kind of
parapply with early return:

?? parfirst(f, x, {&b}):

   Return the smallest index i such that f(x[i]) is non zero, or 0 if none.  If
present, b is to f(x[i]).

One example program:


ellp(p) returns the smallest a>=1 such that the curve y^2=x^3+x+a has prime
order over F_p.

Suggestions for the name and/or the interface ?

The requirement of an explicit vector for x is a bit burdensome, since 
we might like x to be unbounded (i.e. infinite).