Remy José Cano on Thu, 01 Mar 2018 03:40:03 +0100


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

Re: forprime in arithmetic progressions?


 At purpose of forprime and its internal iterator(s):

 By giving a review to http://oeis.org/A005117, and the usage of
forprime made there.

While roughly coding for:
 https://oeis.org/w/images/1/13/RJCano_AlwaysSquarefree_problem_motivation_.txt

 I asked that time for N>0, why not? to offer the possibility of
"browsing" through those primes pre-computed by PARI like if we were
performing a binary search ranging from 2 and the next prime close to
sqrt(N).

In principle, I think (and it's just imho), it would be useful in
squarefree detection...

Cheers

Remy Cano



On 28/02/2018, Charles Greathouse <charles.greathouse@case.edu> wrote:
> The prime iterator (u_forprime_arith_init etc.) internally works in
> arithmetic progressions. Would it be possible to expose this to the user?
> (Perhaps "forprimestep", or maybe an optional final (INTMOD) argument to
> forprime like prod.)
>
> This would be useful, not very hard to implement, and can't be efficiently
> duplicated in gp.
>
> Charles Greathouse
> Case Western Reserve University
>


-- 
_____________________________

Remy José Cano Ramírez
1-43 Entrada principal a Santa Juana. Mérida, ME 5101, Venezuela
Phone: +58 412 077 6 077;
Page: https://www.oeis.org/wiki/User:R._J._Cano
Email: cano.remy.jose@gmail.com