Documentation

Mathlib.RingTheory.WittVector.Truncated

Truncated Witt vectors #

The ring of truncated Witt vectors (of length n) is a quotient of the ring of Witt vectors. It retains the first n coefficients of each Witt vector. In this file, we set up the basic quotient API for this ring.

The ring of Witt vectors is the projective limit of all the rings of truncated Witt vectors.

Main declarations #

References #

def TruncatedWittVector :
(n : ) → (R : Type u_2) → Type u_2

A truncated Witt vector over R is a vector of elements of R, i.e., the first n coefficients of a Witt vector. We will define operations on this type that are compatible with the (untruncated) Witt vector operations.

TruncatedWittVector p n R takes a parameter p : ℕ that is not used in the definition. In practice, this number p is assumed to be a prime number, and under this assumption we construct a ring structure on TruncatedWittVector p n R. (TruncatedWittVector p₁ n R and TruncatedWittVector p₂ n R are definitionally equal as types but will have different ring operations.)

Instances For
    @[implicit_reducible]
    instance instInhabitedTruncatedWittVector (p n : ) (R : Type u_2) [Inhabited R] :
    Inhabited (TruncatedWittVector p n R)
    def TruncatedWittVector.mk (p : ) {n : } {R : Type u_1} (x : Fin nR) :

    Create a TruncatedWittVector from a vector x.

    Instances For
      def TruncatedWittVector.coeff {p n : } {R : Type u_1} (i : Fin n) (x : TruncatedWittVector p n R) :
      R

      x.coeff i is the ith entry of x.

      Instances For
        theorem TruncatedWittVector.ext {p n : } {R : Type u_1} {x y : TruncatedWittVector p n R} (h : ∀ (i : Fin n), coeff i x = coeff i y) :
        x = y
        theorem TruncatedWittVector.ext_iff {p n : } {R : Type u_1} {x y : TruncatedWittVector p n R} :
        x = y ∀ (i : Fin n), coeff i x = coeff i y
        @[simp]
        theorem TruncatedWittVector.coeff_mk {p n : } {R : Type u_1} (x : Fin nR) (i : Fin n) :
        coeff i (mk p x) = x i
        @[simp]
        theorem TruncatedWittVector.mk_coeff {p n : } {R : Type u_1} (x : TruncatedWittVector p n R) :
        (mk p fun (i : Fin n) => coeff i x) = x
        def TruncatedWittVector.out {p n : } {R : Type u_1} [CommRing R] (x : TruncatedWittVector p n R) :

        We can turn a truncated Witt vector x into a Witt vector by setting all coefficients after x to be 0.

        Instances For
          @[simp]
          theorem TruncatedWittVector.coeff_out {p n : } {R : Type u_1} [CommRing R] (x : TruncatedWittVector p n R) (i : Fin n) :
          x.out.coeff i = coeff i x
          theorem TruncatedWittVector.out_injective {p n : } {R : Type u_1} [CommRing R] :
          Function.Injective out
          def WittVector.truncateFun {p : } (n : ) {R : Type u_1} (x : WittVector p R) :

          truncateFun n x uses the first n entries of x to construct a TruncatedWittVector, which has the same base p as x. This function is bundled into a ring homomorphism in WittVector.truncate

          Instances For
            @[simp]
            theorem WittVector.coeff_truncateFun {p n : } {R : Type u_1} (x : WittVector p R) (i : Fin n) :
            @[simp]
            theorem WittVector.out_truncateFun {p n : } {R : Type u_1} [CommRing R] (x : WittVector p R) :
            (truncateFun n x).out = init n x
            @[implicit_reducible]
            noncomputable instance TruncatedWittVector.instZero (p n : ) (R : Type u_1) [CommRing R] [Fact (Nat.Prime p)] :
            Zero (TruncatedWittVector p n R)
            @[implicit_reducible]
            noncomputable instance TruncatedWittVector.instOne (p n : ) (R : Type u_1) [CommRing R] [Fact (Nat.Prime p)] :
            @[implicit_reducible]
            noncomputable instance TruncatedWittVector.instNatCast (p n : ) (R : Type u_1) [CommRing R] [Fact (Nat.Prime p)] :
            NatCast (TruncatedWittVector p n R)
            @[implicit_reducible]
            noncomputable instance TruncatedWittVector.instIntCast (p n : ) (R : Type u_1) [CommRing R] [Fact (Nat.Prime p)] :
            IntCast (TruncatedWittVector p n R)
            @[implicit_reducible]
            noncomputable instance TruncatedWittVector.instAdd (p n : ) (R : Type u_1) [CommRing R] [Fact (Nat.Prime p)] :
            @[implicit_reducible]
            noncomputable instance TruncatedWittVector.instMul (p n : ) (R : Type u_1) [CommRing R] [Fact (Nat.Prime p)] :
            @[implicit_reducible]
            noncomputable instance TruncatedWittVector.instNeg (p n : ) (R : Type u_1) [CommRing R] [Fact (Nat.Prime p)] :
            @[implicit_reducible]
            noncomputable instance TruncatedWittVector.instSub (p n : ) (R : Type u_1) [CommRing R] [Fact (Nat.Prime p)] :
            @[implicit_reducible]
            noncomputable instance TruncatedWittVector.hasNatScalar (p n : ) (R : Type u_1) [CommRing R] [Fact (Nat.Prime p)] :
            SMul (TruncatedWittVector p n R)
            @[implicit_reducible]
            noncomputable instance TruncatedWittVector.hasIntScalar (p n : ) (R : Type u_1) [CommRing R] [Fact (Nat.Prime p)] :
            SMul (TruncatedWittVector p n R)
            @[implicit_reducible]
            noncomputable instance TruncatedWittVector.hasNatPow (p n : ) (R : Type u_1) [CommRing R] [Fact (Nat.Prime p)] :
            Pow (TruncatedWittVector p n R)
            @[simp]
            theorem TruncatedWittVector.coeff_zero (p n : ) (R : Type u_1) [CommRing R] [Fact (Nat.Prime p)] (i : Fin n) :
            coeff i 0 = 0
            def witt_truncateFun_tac :
            Lean.ParserDescr

            A macro tactic used to prove that truncateFun respects ring operations.

            Instances For
              theorem WittVector.truncateFun_surjective (p n : ) (R : Type u_1) [CommRing R] :
              Function.Surjective (truncateFun n)
              @[simp]
              theorem WittVector.truncateFun_zero (p n : ) (R : Type u_1) [CommRing R] [Fact (Nat.Prime p)] :
              truncateFun n 0 = 0
              @[simp]
              theorem WittVector.truncateFun_one (p n : ) (R : Type u_1) [CommRing R] [Fact (Nat.Prime p)] :
              truncateFun n 1 = 1
              @[simp]
              theorem WittVector.truncateFun_add {p : } (n : ) {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] (x y : WittVector p R) :
              truncateFun n (x + y) = truncateFun n x + truncateFun n y
              @[simp]
              theorem WittVector.truncateFun_mul {p : } (n : ) {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] (x y : WittVector p R) :
              truncateFun n (x * y) = truncateFun n x * truncateFun n y
              theorem WittVector.truncateFun_neg {p : } (n : ) {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] (x : WittVector p R) :
              theorem WittVector.truncateFun_sub {p : } (n : ) {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] (x y : WittVector p R) :
              truncateFun n (x - y) = truncateFun n x - truncateFun n y
              theorem WittVector.truncateFun_nsmul {p : } (n : ) {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] (m : ) (x : WittVector p R) :
              truncateFun n (m x) = m truncateFun n x
              theorem WittVector.truncateFun_zsmul {p : } (n : ) {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] (m : ) (x : WittVector p R) :
              truncateFun n (m x) = m truncateFun n x
              theorem WittVector.truncateFun_pow {p : } (n : ) {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] (x : WittVector p R) (m : ) :
              truncateFun n (x ^ m) = truncateFun n x ^ m
              theorem WittVector.truncateFun_natCast {p : } (n : ) {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] (m : ) :
              truncateFun n m = m
              theorem WittVector.truncateFun_intCast {p : } (n : ) {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] (m : ) :
              truncateFun n m = m
              @[implicit_reducible]
              noncomputable instance TruncatedWittVector.instCommRing (p n : ) (R : Type u_1) [CommRing R] [Fact (Nat.Prime p)] :
              noncomputable def WittVector.truncate {p : } (n : ) {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] :

              truncate n is a ring homomorphism that truncates x to its first n entries to obtain a TruncatedWittVector, which has the same base p as x.

              Instances For
                theorem WittVector.truncate_surjective (p n : ) (R : Type u_1) [CommRing R] [Fact (Nat.Prime p)] :
                Function.Surjective (truncate n)
                @[simp]
                theorem WittVector.coeff_truncate {p n : } {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] (x : WittVector p R) (i : Fin n) :
                theorem WittVector.mem_ker_truncate {p : } (n : ) {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] (x : WittVector p R) :
                x RingHom.ker (truncate n) i < n, x.coeff i = 0
                @[simp]
                theorem WittVector.truncate_mk' (p n : ) {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] (f : R) :
                (truncate n) { coeff := f } = TruncatedWittVector.mk p fun (k : Fin n) => f k
                noncomputable def TruncatedWittVector.truncate {p n : } {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] {m : } (hm : n m) :

                A ring homomorphism that truncates a truncated Witt vector of length m to a truncated Witt vector of length n, for n ≤ m.

                Instances For
                  @[simp]
                  theorem TruncatedWittVector.truncate_wittVector_truncate {p n : } {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] {m : } (hm : n m) (x : WittVector p R) :
                  @[simp]
                  theorem TruncatedWittVector.truncate_truncate {p : } {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] {n₁ n₂ n₃ : } (h1 : n₁ n₂) (h2 : n₂ n₃) (x : TruncatedWittVector p n₃ R) :
                  (truncate h1) ((truncate h2) x) = (truncate ) x
                  @[simp]
                  theorem TruncatedWittVector.truncate_comp {p : } {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] {n₁ n₂ n₃ : } (h1 : n₁ n₂) (h2 : n₂ n₃) :
                  (truncate h1).comp (truncate h2) = truncate
                  theorem TruncatedWittVector.truncate_surjective {p n : } {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] {m : } (hm : n m) :
                  Function.Surjective (truncate hm)
                  @[simp]
                  theorem TruncatedWittVector.coeff_truncate {p n : } {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] {m : } (hm : n m) (i : Fin n) (x : TruncatedWittVector p m R) :
                  coeff i ((truncate hm) x) = coeff (Fin.castLE hm i) x
                  @[implicit_reducible]
                  instance TruncatedWittVector.instFintype {p n : } {R : Type u_2} [Fintype R] :
                  noncomputable def WittVector.liftFun {p : } {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] {S : Type u_2} [Semiring S] (f : (k : ) → S →+* TruncatedWittVector p k R) (s : S) :

                  Given a family fₖ : S → TruncatedWittVector p k R and s : S, we produce a Witt vector by defining the kth entry to be the final entry of fₖ s.

                  Instances For
                    @[simp]
                    theorem WittVector.truncate_liftFun {p : } (n : ) {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] {S : Type u_2} [Semiring S] {f : (k : ) → S →+* TruncatedWittVector p k R} (f_compat : ∀ (k₁ k₂ : ) (hk : k₁ k₂), (TruncatedWittVector.truncate hk).comp (f k₂) = f k₁) (s : S) :
                    (truncate n) (liftFun f s) = (f n) s
                    noncomputable def WittVector.lift {p : } {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] {S : Type u_2} [Semiring S] (f : (k : ) → S →+* TruncatedWittVector p k R) (f_compat : ∀ (k₁ k₂ : ) (hk : k₁ k₂), (TruncatedWittVector.truncate hk).comp (f k₂) = f k₁) :

                    Given compatible ring homs from S into TruncatedWittVector n for each n, we can lift these to a ring hom S → 𝕎 R.

                    lift defines the universal property of 𝕎 R as the inverse limit of TruncatedWittVector n.

                    Instances For
                      @[simp]
                      theorem WittVector.truncate_lift {p : } (n : ) {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] {S : Type u_2} [Semiring S] {f : (k : ) → S →+* TruncatedWittVector p k R} (f_compat : ∀ (k₁ k₂ : ) (hk : k₁ k₂), (TruncatedWittVector.truncate hk).comp (f k₂) = f k₁) (s : S) :
                      (truncate n) ((lift f f_compat) s) = (f n) s
                      @[simp]
                      theorem WittVector.truncate_comp_lift {p : } (n : ) {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] {S : Type u_2} [Semiring S] {f : (k : ) → S →+* TruncatedWittVector p k R} (f_compat : ∀ (k₁ k₂ : ) (hk : k₁ k₂), (TruncatedWittVector.truncate hk).comp (f k₂) = f k₁) :
                      (truncate n).comp (lift f f_compat) = f n
                      theorem WittVector.lift_unique {p : } {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] {S : Type u_2} [Semiring S] {f : (k : ) → S →+* TruncatedWittVector p k R} (f_compat : ∀ (k₁ k₂ : ) (hk : k₁ k₂), (TruncatedWittVector.truncate hk).comp (f k₂) = f k₁) (g : S →+* WittVector p R) (g_compat : ∀ (k : ), (truncate k).comp g = f k) :
                      lift f f_compat = g

                      The uniqueness part of the universal property of 𝕎 R.

                      noncomputable def WittVector.liftEquiv {p : } {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] {S : Type u_2} [Semiring S] :
                      { f : (k : ) → S →+* TruncatedWittVector p k R // ∀ (k₁ k₂ : ) (hk : k₁ k₂), (TruncatedWittVector.truncate hk).comp (f k₂) = f k₁ } (S →+* WittVector p R)

                      The universal property of 𝕎 R as projective limit of truncated Witt vector rings.

                      Instances For
                        @[simp]
                        theorem WittVector.liftEquiv_apply {p : } {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] {S : Type u_2} [Semiring S] (f : { f : (k : ) → S →+* TruncatedWittVector p k R // ∀ (k₁ k₂ : ) (hk : k₁ k₂), (TruncatedWittVector.truncate hk).comp (f k₂) = f k₁ }) :
                        liftEquiv f = lift f
                        @[simp]
                        theorem WittVector.liftEquiv_symm_apply_coe {p : } {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] {S : Type u_2} [Semiring S] (g : S →+* WittVector p R) (k : ) :
                        (liftEquiv.symm g) k = (truncate k).comp g
                        theorem WittVector.hom_ext {p : } {R : Type u_1} [CommRing R] [Fact (Nat.Prime p)] {S : Type u_2} [Semiring S] (g₁ g₂ : S →+* WittVector p R) (h : ∀ (k : ), (truncate k).comp g₁ = (truncate k).comp g₂) :
                        g₁ = g₂