Karim Belabas on Sat, 12 Oct 2024 18:05:24 +0200


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

Re: computing all square root modulo a composite


* Max Alekseyev [2024-10-12 17:56]:
> As for the name, maybe sqrtall() ?

sqrtmod rather. Also note that function gives you all roots of any
monic quadratic polynomial, not only square roots.

And it has a weird output format, which makes perfect sense if you
think of it (you get the most precise mathematical information). It
does not give you all solutions mod N but modulo M | N, whose
lifts + k (N/M) mod N, 0 <= k < M are the solutions mod N.

I don't think we want that as a GP function.

Cheers,

    K.B.
-- 
Pr. Karim Belabas, U. Bordeaux, Vice-président en charge du Numérique
Institut de Mathématiques de Bordeaux UMR 5251 - (+33) 05 40 00 29 77
http://www.math.u-bordeaux.fr/~kbelabas/