|Jeroen Demeyer on Wed, 16 Mar 2016 10:54:39 +0100|
[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]
|Re: Proposal to extend primes()|
On 2016-03-16 10:32, Karim Belabas wrote:
Well, I personally find primes([a,b]) more cryptic while primes(a,b) looks more natural for me. Also, I quite like the idea of being able to write primes(,n) for all primes <= n.To save two keystrokes (the [ and ]) at the expense of a (IMHO) more cryptic interface ?
But you are right that there no fundamental reason to prefer primes(a,b) over primes([a,b]).
Currently a single argument describes the interval (as in e.g. polrealroots), and I had thought about adding another optional one to specify an arithmetic progression, e.g. primes([a,b], Mod(c,q))
That would certainly be useful mathematically. But again, I would prefer to see primes(a, b, Mod(c,q)) instead of primes([a,b], Mod(c,q)).