Documentation

Mathlib.Data.Nat.Factorization.Induction

Induction principles involving factorizations #

Definitions #

def Nat.recOnPrimePow {motive : Sort u_1} (zero : motive 0) (one : motive 1) (prime_pow_mul : (a p n : ) → Prime p¬p a0 < nmotive amotive (p ^ n * a)) (a : ) :
motive a

Given P 0, P 1 and a way to extend P a to P (p ^ n * a) for prime p not dividing a, we can define P for all natural numbers.

Equations
  • One or more equations did not get rendered due to their size.
Instances For
    def Nat.recOnPosPrimePosCoprime {motive : Sort u_1} (prime_pow : (p n : ) → Prime p0 < nmotive (p ^ n)) (zero : motive 0) (one : motive 1) (coprime : (a b : ) → 1 < a1 < ba.Coprime bmotive amotive bmotive (a * b)) (a : ) :
    motive a

    Given P 0, P 1, and P (p ^ n) for positive prime powers, and a way to extend P a and P b to P (a * b) when a, b are positive coprime, we can define P for all natural numbers.

    Equations
    • One or more equations did not get rendered due to their size.
    Instances For
      def Nat.recOnPrimeCoprime {motive : Sort u_1} (zero : motive 0) (prime_pow : (p n : ) → Prime pmotive (p ^ n)) (coprime : (a b : ) → 1 < a1 < ba.Coprime bmotive amotive bmotive (a * b)) (a : ) :
      motive a

      Given P 0, P (p ^ n) for all prime powers, and a way to extend P a and P b to P (a * b) when a, b are positive coprime, we can define P for all natural numbers.

      Equations
      Instances For
        def Nat.recOnMul {motive : Sort u_1} (zero : motive 0) (one : motive 1) (prime : (p : ) → Prime pmotive p) (mul : (a b : ) → motive amotive bmotive (a * b)) (a : ) :
        motive a

        Given P 0, P 1, P p for all primes, and a way to extend P a and P b to P (a * b), we can define P for all natural numbers.

        Equations
        • One or more equations did not get rendered due to their size.
        Instances For
          theorem induction_on_primes {motive : Prop} (zero : motive 0) (one : motive 1) (prime_mul : ∀ (p a : ), Nat.Prime pmotive amotive (p * a)) (n : ) :
          motive n
          theorem Nat.prime_composite_induction {motive : Prop} (zero : motive 0) (one : motive 1) (prime : ∀ (p : ), Prime pmotive p) (composite : ∀ (a : ), 2 amotive a∀ (b : ), 2 bmotive bmotive (a * b)) (n : ) :
          motive n

          Lemmas on multiplicative functions #

          theorem Nat.multiplicative_factorization {β : Type u_1} [CommMonoid β] (f : β) (h_mult : ∀ (x y : ), x.Coprime yf (x * y) = f x * f y) (hf : f 1 = 1) {n : } :
          n 0f n = n.factorization.prod fun (p k : ) => f (p ^ k)

          For any multiplicative function f with f 1 = 1 and any n ≠ 0, we can evaluate f n by evaluating f at p ^ k over the factorization of n

          theorem Nat.multiplicative_factorization' {n : } {β : Type u_1} [CommMonoid β] (f : β) (h_mult : ∀ (x y : ), x.Coprime yf (x * y) = f x * f y) (hf0 : f 0 = 1) (hf1 : f 1 = 1) :
          f n = n.factorization.prod fun (p k : ) => f (p ^ k)

          For any multiplicative function f with f 1 = 1 and f 0 = 1, we can evaluate f n by evaluating f at p ^ k over the factorization of n