Bill Allombert on Sat, 12 Oct 2024 17:50:46 +0200
|
[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]
Re: computing all square root modulo a composite
|
- To: Pari Users <pari-users@pari.math.u-bordeaux.fr>
- Subject: Re: computing all square root modulo a composite
- From: Bill Allombert <Bill.Allombert@math.u-bordeaux.fr>
- Date: Sat, 12 Oct 2024 17:50:41 +0200
- Delivery-date: Sat, 12 Oct 2024 17:50:46 +0200
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/simple; d=math.u-bordeaux.fr; s=2022; t=1728748243; bh=yZIGh05DYjlN1Xv+K/SZW79xB041Q04h0csP/pcnHbk=; h=Date:From:To:References:In-Reply-To:From; b=LfAXVieGFf12m8hErt61iXR2h0rTuGV4TWA3fJiTAjEZkRlbudKHmGWJyfsPhJpSx 11djk/ytAWKWK3r+4iJoal/szU4lZJFwH/YW2nt1epIbTlb/uqpwONfYmdt7+tgISB Fh+sMrJgruVnYDpf5TGU2TOgigxVwx0b6c2QVXHeGZrA7eTAcVInDNR4584vq1S2Wy e3pWQoPcE1J7WqEUogPdZYmWKS+QCm/1vuzNqUowxJ9FP3kM0MBBte71WwzsvfXv05 QYHyqUpunxpbrE2ZQUXxPqQacTq8dMwTzACKJlJI2HC8sUkqDxyqnktdLSg/+XqRXj W1d5Rw/Gq28n1pXZE5Z/9DEzvMmxcNAvW1BZPd1iOGyzknP545rlzk5M7cWqy4FXqB 7LIPK9UsaTI55sDumgoCo11SWKkKgk1jf8yRnJj2RJC6cid34Dmegi1DSiYeCWy4gX 0uj5gX9lOseYqnPGIFzXCV8WpY8NvGjKeDNchG3Vq95DKNYdOcqC7P+nbVisHGc+mn weB3V/+zj8OhlYPfpxO0zhK3meBUpQ9Xi9fbT9cJWeDDavGwmP8/oU8vPtOrgVTCdE VHeuH/pb21jTI3HHGuvNk7iBo86lg6fopWflRuZxvGZqzMmgG8j8h223qa9ygxAyvV AS8U2HFyKKOOqWn2z1xNXXdE=
- In-reply-to: <ZwqYkqFSUNZekIwn@math.u-bordeaux.fr>
- Mail-followup-to: Pari Users <pari-users@pari.math.u-bordeaux.fr>
- References: <CAJkPp5PxxVZHXM02kNfJf1aV0CYdRoBgZ5YkKNvHbHF4yCXHqw@mail.gmail.com> <ZwqYkqFSUNZekIwn@math.u-bordeaux.fr>
On Sat, Oct 12, 2024 at 05:41:06PM +0200, Karim Belabas wrote:
> * Max Alekseyev [2024-10-12 16:50]:
> > On Tue, Oct 1, 2024 at 4:56 AM Bill Allombert <
> > Bill.Allombert@math.u-bordeaux.fr> wrote:
> >
> > >
> > > Internally, we have a function Zn_quad_roots that compute all the solution
> > > of x^2+b*x+c mod N
> > > for composite N.
> > > Maybe we could add it to GP if we find a GP interface to it.
> > >
> > >
> > Bill, I'd truly appreciate having such a function.
>
> You have it already:
>
> install(Zn_quad_roots, GGG)
> Zn_quad_roots([N, factor(N)], 0, -B)
>
> should output all square roots of B mod N. (Didn't test :-)
> Of course, [N, factor(N)] should be precomputed.
Indeed, but my question was:
Could you suggest a GP interface for it ?
(even the C interface is strange, N should be last).
Cheers,
Bill.