Chinese Remainder Theorem #
This file provides definitions and theorems for the Chinese Remainder Theorem. These are used in GΓΆdel's Beta function, which is used in proving GΓΆdel's incompleteness theorems.
Main result #
chineseRemainderOfList: Definition of the Chinese remainder of a list
Tags #
Chinese Remainder Theorem, GΓΆdel, beta function
theorem
Nat.modEq_list_map_prod_iff
{ΞΉ : Type u_1}
{a b : β}
{s : ΞΉ β β}
{l : List ΞΉ}
(co : List.Pairwise (Function.onFun Coprime s) l)
:
def
Nat.chineseRemainderOfList
{ΞΉ : Type u_1}
(a s : ΞΉ β β)
(l : List ΞΉ)
:
List.Pairwise (Function.onFun Coprime s) l β { k : β // β i β l, k β‘ a i [MOD s i] }
The natural number less than (l.map s).prod congruent to
a i mod s i for all i β l.
Instances For
@[simp]
theorem
Nat.chineseRemainderOfList_nil
{ΞΉ : Type u_1}
(a s : ΞΉ β β)
:
β(chineseRemainderOfList a s [] β―) = 0
theorem
Nat.chineseRemainderOfList_lt_prod
{ΞΉ : Type u_1}
(a s : ΞΉ β β)
(l : List ΞΉ)
(co : List.Pairwise (Function.onFun Coprime s) l)
(hs : β i β l, s i β 0)
:
theorem
Nat.chineseRemainderOfList_modEq_unique
{ΞΉ : Type u_1}
(a s : ΞΉ β β)
(l : List ΞΉ)
(co : List.Pairwise (Function.onFun Coprime s) l)
{z : β}
(hz : β i β l, z β‘ a i [MOD s i])
:
theorem
Nat.chineseRemainderOfList_perm
{ΞΉ : Type u_1}
(a s : ΞΉ β β)
{l l' : List ΞΉ}
(hl : l.Perm l')
(hs : β i β l, s i β 0)
(co : List.Pairwise (Function.onFun Coprime s) l)
:
β(chineseRemainderOfList a s l co) = β(chineseRemainderOfList a s l' β―)
The natural number less than (m.map s).prod congruent to
a i mod s i for all i β m.
Instances For
theorem
Nat.chineseRemainderOfMultiset_lt_prod
{ΞΉ : Type u_1}
(a s : ΞΉ β β)
{m : Multiset ΞΉ}
(nod : m.Nodup)
(hs : β i β m, s i β 0)
(pp : {x : ΞΉ | x β m}.Pairwise (Function.onFun Coprime s))
:
def
Nat.chineseRemainderOfFinset
{ΞΉ : Type u_1}
(a s : ΞΉ β β)
(t : Finset ΞΉ)
(hs : β i β t, s i β 0)
(pp : (βt).Pairwise (Function.onFun Coprime s))
:
The natural number less than β i β t, s i congruent to
a i mod s i for all i β t.
Instances For
theorem
Nat.chineseRemainderOfFinset_lt_prod
{ΞΉ : Type u_1}
(a s : ΞΉ β β)
{t : Finset ΞΉ}
(hs : β i β t, s i β 0)
(pp : (βt).Pairwise (Function.onFun Coprime s))
: