Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Merged by Bors] - feat(AlgebraicGeometry/EllipticCurve/DivisionPolynomial/Basic): add maps for division polynomials #13399

Closed
wants to merge 68 commits into from
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
68 commits
Select commit Hold shift + click to select a range
4ee67ce
Add Ring.divide
Multramate Jul 15, 2023
eab1469
Add IsUnit.divide_eq_mul_inverse
Multramate Jul 18, 2023
50f07f5
Remove redundant assumption
Multramate Jul 18, 2023
7cd0323
Replace NeZero with Nontrivial
Multramate Aug 8, 2023
4dc082e
Merge branch 'master' into Ring.divide
Multramate Aug 21, 2023
bd2f111
Define division polynomials
Multramate Aug 21, 2023
3d63eed
Merge branch 'master' into division_polynomial
Multramate Nov 27, 2023
24f6d6e
Remove divisibility changes
Multramate Nov 27, 2023
dec8062
Merge branch 'master' into division_polynomial
Multramate Dec 29, 2023
04200b4
Define elliptic divisibility sequences
Multramate Jan 1, 2024
09adefb
Merge branch 'EllipticDivisibilitySequence' into division_polynomial
Multramate Jan 1, 2024
ba72afb
Use elliptic divisibility sequences
Multramate Jan 1, 2024
bb1bf7e
Implement Jacobian coordinates
Multramate Jan 2, 2024
906e858
Implement equations and nonsingularity for Jacobian coordinates
Multramate Jan 4, 2024
b9e60a1
Implement group operation polynomials for Jacobian coordinates
Multramate Jan 4, 2024
d42c841
Implement group operations on point representatives for Jacobian coor…
Multramate Jan 4, 2024
59a7cf4
Implement group operations on nonsingular rational points for Jacobia…
Multramate Jan 4, 2024
4449702
Merge branch 'EllipticCurve.Jacobian.Point' into EllipticCurve.Jacobian
Multramate Jan 4, 2024
18e2fd4
Remove extraneous factor in addition
Multramate Jan 5, 2024
04c8b01
Merge branch 'EllipticCurve.Jacobian.Polynomial' into EllipticCurve.J…
Multramate Jan 5, 2024
44f37d6
Fix merge error
Multramate Jan 5, 2024
2fdd995
Merge branch 'EllipticCurve.Jacobian.Representative' into EllipticCur…
Multramate Jan 5, 2024
8b3cc83
Fix merge error
Multramate Jan 5, 2024
640f3a4
Merge branch 'EllipticCurve.Jacobian.Point' into EllipticCurve.Jacobian
Multramate Jan 5, 2024
aebed9b
Merge branch 'EllipticCurve.Jacobian' into DivisionPolynomial
Multramate Jan 6, 2024
595eee8
Merge remote-tracking branch 'origin/master' into division_polynomial
Multramate Feb 3, 2024
d67fb6a
Expose the auxiliary sequence
Multramate Feb 21, 2024
9abf5de
Define recursion principle for normalised EDS
Multramate Feb 22, 2024
21fd348
Merge branch 'EllipticDivisibilitySequence' into division_polynomial
Multramate Feb 22, 2024
59b7909
Redefine division polynomials
Multramate Feb 22, 2024
9f4fb43
Fix dependencies
Multramate Feb 22, 2024
750cb47
Merge branch 'EDSRec' into DivisionPolynomial
Multramate Feb 22, 2024
2e23f41
Compute degrees of division polynomials
Multramate Feb 23, 2024
e774105
Merge remote-tracking branch 'origin/master' into DivisionPolynomial
Multramate May 22, 2024
863e697
Fix merge
Multramate May 22, 2024
6a76f32
Fix upstream
Multramate May 23, 2024
343fc96
Rename division polynomials and add further documentation
Multramate May 27, 2024
087072f
Add further map lemmas
Multramate May 29, 2024
f38bd5e
Fix Group
Multramate May 29, 2024
092eeab
Fix names
Multramate May 30, 2024
de9d170
Fix sentence
Multramate May 30, 2024
f5feacc
Merge branch 'division_polynomial' into DivisionPolynomial.Map
Multramate May 30, 2024
6495e45
Fix docstring
Multramate May 30, 2024
4c05448
Add maps for division polynomials
Multramate May 30, 2024
0eeb05e
Golf odd/even lemmas
Multramate May 31, 2024
18a53a3
Rename variable
Multramate May 31, 2024
0c4dcaa
Merge remote-tracking branch 'origin/master' into EllipticCurve.Affin…
Multramate Jun 1, 2024
c71e42e
Fix merge
Multramate Jun 1, 2024
7717581
Add sections
Multramate Jun 1, 2024
ba56b6a
Merge branch 'EllipticCurve.Affine.Map' into DivisionPolynomial.Map
Multramate Jun 1, 2024
d21d346
Add base changes
Multramate Jun 1, 2024
0d3e52e
Merge branch 'division_polynomial' into DivisionPolynomial.Map
Multramate Jun 1, 2024
3176ddb
Merge remote-tracking branch 'origin/master' into division_polynomial
Multramate Jun 8, 2024
fa64986
Fix merge
Multramate Jun 8, 2024
7190e5e
Move DivisionPolynomial to DivisionPolynomial.Basic
Multramate Jun 8, 2024
d97a437
Fix names
Multramate Jun 8, 2024
aa51ca4
Merge branch 'division_polynomial' into DivisionPolynomial.Map
Multramate Jun 8, 2024
572d359
Fix merge
Multramate Jun 8, 2024
83ca5ba
Remove protection
Multramate Jun 9, 2024
6dfda98
Merge branch 'division_polynomial' into DivisionPolynomial.Map
Multramate Jun 9, 2024
98bbd5f
Fix merge
Multramate Jun 9, 2024
a1ef8e9
Prove congruences in coordinate ring
Multramate Jun 9, 2024
c24d5e2
Merge branch 'master' into DivisionPolynomial.Map
Multramate Jun 9, 2024
f75eba2
Improve docstrings
Multramate Jun 10, 2024
6667911
Add dots
Multramate Jun 10, 2024
854c757
Fix English
Multramate Jun 10, 2024
fd29797
Fix English
Multramate Jun 10, 2024
541bb1d
Change order
Multramate Jun 10, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,13 @@ import Mathlib.NumberTheory.EllipticDivisibilitySequence
# Division polynomials of Weierstrass curves

This file defines certain polynomials associated to division polynomials of Weierstrass curves.
These are defined in terms of the auxiliary sequences of normalised elliptic divisibility sequences
defined in `Mathlib.NumberTheory.EllipticDivisibilitySequence`.
These are defined in terms of the auxiliary sequences for normalised elliptic divisibility sequences
(EDS) as defined in `Mathlib.NumberTheory.EllipticDivisibilitySequence`.

## Mathematical background

Let $W$ be a Weierstrass curve over a commutative ring $R$. The sequence of $n$-division polynomials
$\psi_n \in R[X, Y]$ of $W$ is the normalised elliptic divisibility sequence with initial values
$\psi_n \in R[X, Y]$ of $W$ is the normalised EDS with initial values
* $\psi_0 := 0$,
* $\psi_1 := 1$,
* $\psi_2 := 2Y + a_1X + a_3$,
Expand All @@ -28,8 +28,8 @@ Furthermore, define the associated sequences $\phi_n, \omega_n \in R[X, Y]$ by
* $\phi_n := X\psi_n^2 - \psi_{n + 1}\psi_{n - 1}$, and
* $\omega_n := \tfrac{1}{2} \cdot (\psi_{2n} / \psi_n - \psi_n(a_1\phi_n + a_3\psi_n^2))$.

Note that $\omega_n$ is always well-defined as a polynomial. As a start, it can be shown by
induction that $\psi_n$ always divides $\psi_{2n}$, so that $\psi_{2n} / \psi_n$ is always
Note that $\omega_n$ is always well-defined as a polynomial in $R[X, Y]$. As a start, it can be
shown by induction that $\psi_n$ always divides $\psi_{2n}$, so that $\psi_{2n} / \psi_n$ is always
well-defined as a polynomial, while division by 2 is well-defined when $R$ has characteristic
different from 2. In general, it can be shown that 2 always divides the polynomial
$\psi_{2n} / \psi_n - \psi_n(a_1\phi_n + a_3\psi_n^2)$ in the characteristic zero universal ring
Expand All @@ -38,16 +38,16 @@ defined as its image under the associated universal morphism $\mathbb{Z}[A_i][X,

Now, in the coordinate ring $R[W]$, note that $\psi_2^2$ is congruent to the polynomial
$\Psi_2^{[2]} := 4X^3 + b_2X^2 + 2b_4X + b_6 \in R[X]$. As such, in $R[W]$, the recurrences
associated to a normalised elliptic divisibility sequence show that $\psi_n / \psi_2$ are congruent
to certain polynomials in $R[X]$. In particular, define $\tilde{\Psi}_n \in R[X]$ as the auxiliary
sequence for a normalised elliptic divisibility sequence with initial values
associated to a normalised EDS show that $\psi_n / \psi_2$ are congruent to certain polynomials in
$R[X]$. In particular, define $\tilde{\Psi}_n \in R[X]$ as the auxiliary sequence for a normalised
EDS with extraneous parameter $\Psi_2^{[2]}$ and initial values
* $\tilde{\Psi}_0 := 0$,
* $\tilde{\Psi}_1 := 1$,
* $\tilde{\Psi}_2 := 1$,
* $\tilde{\Psi}_3 := \psi_3$, and
* $\tilde{\Psi}_4 := \psi_4 / \psi_2$.

The corresponding normalised elliptic divisibility sequence $\Psi_n \in R[X, Y]$ is then given by
The corresponding normalised EDS $\Psi_n \in R[X, Y]$ is then given by
* $\Psi_n := \tilde{\Psi}_n\psi_2$ if $n$ is even, and
* $\Psi_n := \tilde{\Psi}_n$ if $n$ is odd.

Expand Down
20 changes: 10 additions & 10 deletions Mathlib/NumberTheory/EllipticDivisibilitySequence.lean
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,10 @@ Some examples of EDSs include
## Implementation notes

The normalised EDS `normEDS b c d n` is defined in terms of the auxiliary sequence
`preNormEDS (b ^ 4) c d n`, which are equal when `n` is odd, and which differ by a factor of `b`
when `n` is even. This coincides with the definition in the references since both agree for
`normEDS b c d 2` and for `normEDS b c d 4`, and the correct factors of `b` are removed in
`normEDS b c d (2 * (m + 2) + 1)` and in `normEDS b c d (2 * (m + 3))`.
`preNormEDS (b ^ 4) c d n`, which are equal when `n` is odd, and which differ by a factor of an
extraneous parameter `b` when `n` is even. This coincides with the definition in the references
since both agree for `normEDS b c d 2` and for `normEDS b c d 4`, and the correct factors of `b` are
removed in `normEDS b c d (2 * (m + 2) + 1)` and in `normEDS b c d (2 * (m + 3))`.

One reason is to avoid the necessity for ring division by `b` in the inductive definition of
`normEDS b c d (2 * (m + 3))`. The idea is that, it can be shown that `normEDS b c d (2 * (m + 3))`
Expand Down Expand Up @@ -102,8 +102,8 @@ lemma IsDivSequence.smul (h : IsDivSequence W) (x : R) : IsDivSequence (x • W)
lemma IsEllDivSequence.smul (h : IsEllDivSequence W) (x : R) : IsEllDivSequence (x • W) :=
⟨h.left.smul x, h.right.smul x⟩

/-- The auxiliary sequence for a normalised EDS `W : ℕ → R`,
with initial values `W(0) = 0`, `W(1) = 1`, `W(2) = 1`, `W(3) = c`, and `W(4) = d`. -/
/-- The auxiliary sequence for a normalised EDS `W : ℕ → R`, with extraneous parameter `b` and
initial values `W(0) = 0`, `W(1) = 1`, `W(2) = 1`, `W(3) = c`, and `W(4) = d`. -/
def preNormEDS' (b c d : R) : ℕ → R
| 0 => 0
| 1 => 1
Expand Down Expand Up @@ -159,8 +159,8 @@ lemma preNormEDS'_even (m : ℕ) : preNormEDS' b c d (2 * (m + 3)) =
simp only [Nat.mul_add_div two_pos]
rfl

/-- The auxiliary sequence for a normalised EDS `W : ℤ → R`,
with initial values `W(0) = 0`, `W(1) = 1`, `W(2) = 1`, `W(3) = c`, and `W(4) = d`.
/-- The auxiliary sequence for a normalised EDS `W : ℤ → R`, with extraneous parameter `b` and
initial values `W(0) = 0`, `W(1) = 1`, `W(2) = 1`, `W(3) = c`, and `W(4) = d`.

This extends `preNormEDS'` by defining its values at negative integers. -/
def preNormEDS (n : ℤ) : R :=
Expand Down Expand Up @@ -208,8 +208,8 @@ lemma preNormEDS_even (m : ℕ) : preNormEDS b c d (2 * (m + 3)) =
lemma preNormEDS_neg (n : ℤ) : preNormEDS b c d (-n) = -preNormEDS b c d n := by
rw [preNormEDS, Int.sign_neg, Int.cast_neg, neg_mul, Int.natAbs_neg, preNormEDS]

/-- The canonical example of a normalised EDS `W : ℤ → R`,
with initial values `W(0) = 0`, `W(1) = 1`, `W(2) = b`, `W(3) = c`, and `W(4) = d * b`.
/-- The canonical example of a normalised EDS `W : ℤ → R`, with initial values
`W(0) = 0`, `W(1) = 1`, `W(2) = b`, `W(3) = c`, and `W(4) = d * b`.

This is defined in terms of `preNormEDS` whose even terms differ by a factor of `b`. -/
def normEDS (n : ℤ) : R :=
Expand Down
Loading