A classification of ECM-friendly families using modular curves

Razvan Barbulescu and Sudarshan Shinde

The main object in our work is the image of Galois : if E/Q is an elliptic curve and m is an integer, and a basis P,Q of E[m], we have the following embedding

where a,b,c,d are such that Pσ=aP+bQ and Qσ=cP+dQ. By Serre's open image theorem, ρE,m is surjective for all integers not divisible by a finite set of primes LE. Moreover, for all LE, there exists an integer k1 such that Im(ρE,k) has the same index as ρE,k for all kk.

Mazur's program B consists in classifying the elliptic curves E which correspond to a given congruence subgrop of GL2(Z). In our paper (available here), we solve the case of subgroups H whose levels are not prime-powers and which occur for infinitely many j-invariants.


A complete list of the 1525 ECM-friendly families is available in

We also provide this list in the form of two sage scripts:


We pre-computed α (resp. αK for K=Q(ζ3), Q(i) and Q(ζ5)) for each family n Theorem 4.1 following the method in Sections 5.2 and 5.4 of our article. One can do so for any set corresponding to a subgroup of GL2(Z) without even knowing if the set is empty, finite or infinite. Given any elliptic curve E with rational coefficients, one tests if its j-invariant is coordinate on the modular curve of each subgroup which can occur as Galois image and hence obtains α(E).


The following script allows to do the verifications in Appendix B, which proves the equality among various families in the literature and the families in Theorem 4.1.

Several scripts allow to verify the results of Theorem 4.1: