| Unknown on Tue Jun 10 22:09:47 2008 |
[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]
| [no subject] |
A more meaningful check would be to verify that the distance from the point
to the curve is small.
Karim.
Index: src/modules/elliptic.c
===================================================================
RCS file: /home/megrez/cvsroot/pari/src/modules/elliptic.c,v
retrieving revision 1.9
diff -c -r1.9 elliptic.c
*** src/modules/elliptic.c 1999/10/18 13:14:23 1.9
--- src/modules/elliptic.c 1999/10/18 15:00:40
***************
*** 447,464 ****
tetpil=avma; return gerepile(av,tetpil,gcopy(y));
}
- static long
- ellexpo(GEN e)
- {
- long i,k2, k = gexpo((GEN)e[1]);
- for (i=2; i<6; i++)
- {
- k2 = gexpo((GEN)e[i]);
- if (k<k2) k = k2;
- }
- return k;
- }
-
/* Exactness of lhs and rhs in the following depends in non-obvious ways
on the coeffs of the curve as well as on the components of the point z.
Thus if e is exact, with a1==0, and z has exact y coordinate only, the
--- 447,452 ----
***************
*** 477,484 ****
q = precision(p2);
if (!p && !q) { avma=av; return 0; } /* both of p1, p2 are exact */
if (!q || (p && p < q)) q = p; /* min among nonzero elts of {p,q} */
! /* the constant 0.93 is arbitrary */
! q = (gexpo(x)-ellexpo(e) < - bit_accuracy(q) * 0.93);
avma = av; return q;
}
--- 465,471 ----
q = precision(p2);
if (!p && !q) { avma=av; return 0; } /* both of p1, p2 are exact */
if (!q || (p && p < q)) q = p; /* min among nonzero elts of {p,q} */
! q = (gexpo(x) < gexpo(p1) - bit_accuracy(q) + 15);
avma = av; return q;
}
__
Karim Belabas email: Karim.Belabas@math.u-psud.fr
Dep. de Mathematiques, Bat. 425
Universite Paris-Sud Tel: (00 33) 1 69 15 57 48
F-91405 Orsay (France) Fax: (00 33) 1 69 15 60 19
--
PARI/GP Home Page: http://hasse.mathematik.tu-muenchen.de/ntsw/pari/