<div dir="ltr">Thanks Mike! That was the final piece of the puzzle.<div><br></div><div class="gmail_extra">Cheers,<br clear="all"><div><div class="gmail_signature" data-smartmail="gmail_signature"><br>Conrado</div></div>
<br><div class="gmail_quote">On Tue, Mar 20, 2018 at 4:50 PM, Mike Hamburg <span dir="ltr"><<a href="mailto:mike@shiftleft.org" target="_blank">mike@shiftleft.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Conrado,<br>
<br>
This looks right to me. Note that if a and d are both square or both nonsquare, then ad = (A^2-4) is square. In that case, you can solve the quadratic x^2+Ax+1=0, so there are additional points on the Montgomery curve where y=0. These points have order 2, and so would be at infinity on the isomorphic Edwards curve. Therefore that Edwards curve can’t be complete. However, there might be an isogenous complete Edwards curve, using the same family of isogenies as Ed448-Goldilocks.<br>
<br>
Cheers,<br>
— Mike<br>
<br>
Sent from my phone. Please excuse brevity and typos.<br>
<div><div class="h5"><br>
> On Mar 20, 2018, at 12:35, Conrado P. L. Gouvêa <<a href="mailto:conradoplg@gmail.com">conradoplg@gmail.com</a>> wrote:<br>
><br>
> Hi,<br>
><br>
> I've been studying the process used to generate Montgomery and Edwards curves.<br>
><br>
> Generating Montgomery seems fairly straightforward. Pick B = 1 for speed and select a suitable A that generates a curve / twist curve with near-prime order. Only values such that (A-2) % 4 == 0 are considered, also for speed.<br>
><br>
> Now suppose you want to create an Edwards curve E(a,d) from a certain Montgomery M(A,B=1) curve found. The default mapping is to set a = (A + 2) and d = (A - 2).<br>
> The first problem is: from what I understand, in order for the formulas to be complete, "a" needs to be square and "d" needs to be nonsquare.<br>
> The second problem is: "a" is usually 1 or -1 for speed reasons.<br>
><br>
> Reading about it, I've kind of deduced that the following is the approach taken, but I'd like to verify if this is correct.<br>
><br>
> If "a" is square and "d" nonsquare, you're almost done. Use the mapping (x', y') -> (x*sqrt(a), y) and get the curve E(1,d/a) which is isomorphic (birationally equivalent?) to E(a,d). If your prime is 1 modulo 4 then -1 is square, so you can target "a" == -1 which is faster. Use the mapping (x', y') -> (-x*(sqrt(a)/sqrt(-1)), y) and get the curve E(-1, -d/a).<br>
> (This is how edwards25519 was generated)<br>
><br>
> If "a" is nonsquare and "d" square, you can use the mapping (x', y') -> (x, 1/y) and get the curve E(d, a). Then follow the previous procedure to get a new "a" = 1 or "a" = -1.<br>
> (This is how the second curve in the "Curve448" section of RFC 7748 was generated)<br>
><br>
> Now if "a" and "d" are both square or nonsquare, it seems you can't do anything, though I haven't seen this explicitly mentioned anywhere...<br>
><br>
> Is this reasoning right?<br>
><br>
> Thanks!<br>
><br>
> Conrado<br>
><br>
</div></div>> ______________________________<wbr>_________________<br>
> Curves mailing list<br>
> <a href="mailto:Curves@moderncrypto.org">Curves@moderncrypto.org</a><br>
> <a href="https://moderncrypto.org/mailman/listinfo/curves" rel="noreferrer" target="_blank">https://moderncrypto.org/<wbr>mailman/listinfo/curves</a><br>
<br>
</blockquote></div><br></div></div>