1
votes

Consider the following definitions in Isabelle:

definition "e_aff = {(x, y). e' x y = 0}"
definition "e_circ = {(x,y). x ≠ 0 ∧ y ≠ 0 ∧ (x,y) ∈ e_aff}"
definition gluing :: "(((real × real) × bit) × ((real × real) × bit)) set" where
  "gluing = {(((x0,y0),l),((x1,y1),j)). 
               ((x0,y0) ∈ e_aff ∧ (x1,y1) ∈ e_aff) ∧
               (((x0,y0) ∈ e_circ ∧ (x1,y1) = τ (x0,y0) ∧ j = l+1) ∨
                ((x0,y0) ∈ e_aff ∧ x0 = x1 ∧ y0 = y1 ∧ l = j))}"
definition "Bits = range Bit"
definition e_aff_bit :: "((real × real) × bit) set" where
 "e_aff_bit = e_aff × Bits"
definition e_proj where "e_proj = e_aff_bit // gluing"

fun ρ :: "real × real ⇒ real × real" where 
  "ρ (x,y) = (-y,x)"
fun τ :: "real × real ⇒ real × real" where 
  "τ (x,y) = (1/(t*x),1/(t*y))"
definition symmetries where 
  "symmetries = {τ,τ ∘ ρ,τ ∘ ρ ∘ ρ,τ ∘ ρ ∘ ρ ∘ ρ}"

I want to define the action of the group of symmetries on the projective points of the underlying elliptic curve. The action is specified as follows:

τ [P,i] = [P,i+1]
ρ [P,i] = [ρ (P),i]

the action of the remaining symmetries can be deduced from the rule:

s1 ∘ s2 [P,i] = s2 (s1 [P,i]))

The notation specifies how does one element of the group act on a representant of a class.

How could I formalize this in Isabelle?

Here is a related question: Refining a definition in Isabelle

And here the full code:https://github.com/rjraya/Isabelle/blob/master/curves/Hales.thy

First question would be how to treat symmetries as a type, since they depend on fixed variable d.

1

1 Answers

0
votes

A plausible option for the solution could be the use of an inductive predicate. The definition below is merely a template/idea: I have not verified that it is, indeed, the definition that you are trying to obtain.

inductive φ where
    "φ τ s (the_elem ({(P, i + 1) | P i. (P, i) ∈ s } // gluing))"
    if "s ∈ E" 
  | "φ ρ s (the_elem ({(ρ P, i) | P i. (P, i) ∈ s } // gluing))"
    if "s ∈ E" 
  | "φ (g1 ∘ g2) s s''" 
    if "g1 ∈ G" and "g2 ∈ G" and "s ∈ E" and "φ g1 s s'" and "φ g2 s' s''"

definition Φ where 
  "Φ g s = (if g ∈ G ∧ s ∈ E then (THE s'. φ g s s') else {})"

As a side note, it may also be possible to use the function infrastructure instead of the inductive predicate.