# Ticket #10832: trac_10872.patch

File trac_10872.patch, 1.6 KB (added by gagansekhon, 2 years ago)
• ## sage/schemes/elliptic_curves/ell_rational_field.py

```# HG changeset patch
# User John Cremona <john.cremona@gmail.com>
# Date 1298432065 0
# Node ID f1d8c07018e8eac8ee705b562029dcbe1a093a2c
# Parent  ec11b62f0270b890da3b9b2021aed9b30ed718ee
trac_10832 error in processing output from simon_two_descent

diff -r ec11b62f0270 -r f1d8c07018e8 sage/schemes/elliptic_curves/ell_rational_field.py```
 a sage: set_random_seed(0) sage: r, s, G = E.simon_two_descent(); r,s (8, 8) Example from trac 10832:: sage: E = EllipticCurve([1,0,0,-6664,86543]) sage: E.simon_two_descent() (2, 3, [(173 : 1943 : 1), (-73 : -394 : 1), (323/4 : 1891/8 : 1)]) sage: E.rank() 2 sage: E.gens() [(-73 : -394 : 1), (323/4 : 1891/8 : 1)] """ t = simon_two_descent(self, verbose=verbose, lim1=lim1, lim3=lim3, limtriv=limtriv, maxprob=maxprob, limbigprime=limbigprime) two_selmer_rank = rings.Integer(t[1]) gens_mod_two = [self(P) for P in t[2]] if rank_low_bd == two_selmer_rank - self.two_torsion_rank(): gens = [P for P in gens_mod_two if P.additive_order() != 2] gens = [P for P in gens_mod_two if P.has_infinite_order()] gens = self.saturation(gens)[0] self.__gens[True] = gens self.__gens[True].sort() self.__rank[True] = len(self.__gens[True])