From 5125e2d9711ffd6904384159829673155cab683d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andreas=20M=C3=BCller?= Date: Tue, 2 Feb 2021 21:31:33 +0100 Subject: new stuff --- buch/chapters/90-crypto/rechnungen/elliptic.maxima | 42 ++++++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100644 buch/chapters/90-crypto/rechnungen/elliptic.maxima (limited to 'buch/chapters/90-crypto/rechnungen/elliptic.maxima') diff --git a/buch/chapters/90-crypto/rechnungen/elliptic.maxima b/buch/chapters/90-crypto/rechnungen/elliptic.maxima new file mode 100644 index 0000000..8c43e6c --- /dev/null +++ b/buch/chapters/90-crypto/rechnungen/elliptic.maxima @@ -0,0 +1,42 @@ +/* + * elliptic.maxima + * + * (c) 2021 Prof Dr Andreas Müller, OST Ostschweizer Fachhochschule + */ + +p: Y^2+X*Y - X^3 - a*X -b; + +x: x1*t+(1-t)*x2; +y: y1*t+(1-t)*y2; + +q: subst(x,X,p); +q: subst(y,Y,q); +q: ratsimp(expand(q)); +tex(q); + +qr: divide(q,t*(t-1),t); +r: qr[2]; +q: qr[1]; +tex(q); + +subst(0,t,r); +subst(1,t,r); + +tex(r); + +polydecomp(qr[2], t); + +s: solve(q = 0, t); +tex(s); + +x3: ratsimp(expand(subst(s, x))); +y3: ratsimp(expand(subst(s, y))); + +tex(x3); +tex(y3); + +Y3: expand(y3 * (x2-x1)^3 - (y2-y1)^3 - (x2-x1)*(y2-y1)^2 ); +Y3: factor(expand(Y3)); +tex(Y3); + + -- cgit v1.2.1