state stringlengths 0 159k | srcUpToTactic stringlengths 387 167k | nextTactic stringlengths 3 9k | declUpToTactic stringlengths 22 11.5k | declId stringlengths 38 95 | decl stringlengths 16 1.89k | file_tag stringlengths 17 73 |
|---|---|---|---|---|---|---|
k₂ : ℕ
c : Code
n x : ℕ
x✝ : 0 ≤ k₂
h : x ∈ evaln 0 c n
⊢ x ∈ evaln k₂ c n | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp [evaln] at h | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
k k₂ : ℕ
c : Code
n x : ℕ
hl : k + 1 ≤ k₂ + 1
h : x ∈ evaln (k + 1) c n
⊢ x ∈ evaln (k₂ + 1) c n | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | have hl' := Nat.le_of_succ_le_succ hl | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
| Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
k k₂ : ℕ
c : Code
n x : ℕ
hl : k + 1 ≤ k₂ + 1
h : x ∈ evaln (k + 1) c n
hl' : k ≤ k₂
⊢ x ∈ evaln (k₂ + 1) c n | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ do { guard (n ≤ k); o₁ } → x ∈ do { guard (n ≤ k₂); o₂ } := by
simp only [Option.mem_def, bind, Option.bind_eq_some, Option.guard_eq_some', exists_and_left,
exists_const, and_imp]
introv h h₁ h₂ h₃
... | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
| Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
k k₂ : ℕ
c : Code
n x : ℕ
hl : k + 1 ≤ k₂ + 1
h : x ∈ evaln (k + 1) c n
hl' : k ≤ k₂
⊢ ∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂ | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp only [Option.mem_def, bind, Option.bind_eq_some, Option.guard_eq_some', exists_and_left,
exists_const, and_imp] | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
k k₂ : ℕ
c : Code
n x : ℕ
hl : k + 1 ≤ k₂ + 1
h : x ∈ evaln (k + 1) c n
hl' : k ≤ k₂
⊢ ∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ}, k ≤ k₂ → (o₁ = some x → o₂ = some x) → n ≤ k → o₁ = some x → n ≤ k₂ ∧ o₂ = some x | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | introv h h₁ h₂ h₃ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
k✝ k₂✝ : ℕ
c : Code
n✝ x✝ : ℕ
hl : k✝ + 1 ≤ k₂✝ + 1
h✝ : x✝ ∈ evaln (k✝ + 1) c n✝
hl' : k✝ ≤ k₂✝
k k₂ n x : ℕ
o₁ o₂ : Option ℕ
h : k ≤ k₂
h₁ : o₁ = some x → o₂ = some x
h₂ : n ≤ k
h₃ : o₁ = some x
⊢ n ≤ k₂ ∧ o₂ = some x | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | exact ⟨le_trans h₂ h, h₁ h₃⟩ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
k k₂ : ℕ
c : Code
n x : ℕ
hl : k + 1 ≤ k₂ + 1
h : x ∈ evaln (k + 1) c n
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
⊢ x ∈ evaln (k₂ + 1) c n | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp? at h ⊢ says simp only [Option.mem_def] at h ⊢ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
k k₂ : ℕ
c : Code
n x : ℕ
hl : k + 1 ≤ k₂ + 1
h : x ∈ evaln (k + 1) c n
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
⊢ x ∈ evaln (k₂ + 1) c n | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp only [Option.mem_def] at h ⊢ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
k k₂ : ℕ
c : Code
n x : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
h : evaln (k + 1) c n = some x
⊢ evaln (k₂ + 1) c n = som... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case zero
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
n x : ℕ
h : evaln (k + 1) zero n = some x
⊢ evaln (k₂ + 1) zero ... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | rw [evaln] at h ⊢ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case succ
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
n x : ℕ
h : evaln (k + 1) succ n = some x
⊢ evaln (k₂ + 1) succ ... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | rw [evaln] at h ⊢ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case left
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
n x : ℕ
h : evaln (k + 1) left n = some x
⊢ evaln (k₂ + 1) left ... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | rw [evaln] at h ⊢ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case right
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
n x : ℕ
h : evaln (k + 1) right n = some x
⊢ evaln (k₂ + 1) rig... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | rw [evaln] at h ⊢ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case pair
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf cg : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x → eva... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | rw [evaln] at h ⊢ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case comp
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf cg : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x → eva... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | rw [evaln] at h ⊢ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case prec
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf cg : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x → eva... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | rw [evaln] at h ⊢ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case rfind'
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x → eval... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | rw [evaln] at h ⊢ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case zero
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
n x : ℕ
h :
(fun n => do
guard (n ≤ k)
pure 0)... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | refine' this hl' (fun h => _) h | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case succ
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
n x : ℕ
h :
(fun n => do
guard (n ≤ k)
pure (N... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | refine' this hl' (fun h => _) h | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case left
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
n x : ℕ
h :
(fun n => do
guard (n ≤ k)
pure (u... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | refine' this hl' (fun h => _) h | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case right
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
n x : ℕ
h :
(fun n => do
guard (n ≤ k)
pure (... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | refine' this hl' (fun h => _) h | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case pair
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf cg : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x → eva... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | refine' this hl' (fun h => _) h | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case comp
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf cg : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x → eva... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | refine' this hl' (fun h => _) h | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case prec
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf cg : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x → eva... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | refine' this hl' (fun h => _) h | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case rfind'
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x → eval... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | refine' this hl' (fun h => _) h | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case zero
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
n x : ℕ
h✝ :
(fun n => do
guard (n ≤ k)
pure 0... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | iterate 4 exact h | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case zero
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
n x : ℕ
h✝ :
(fun n => do
guard (n ≤ k)
pure 0... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | exact h | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case succ
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
n x : ℕ
h✝ :
(fun n => do
guard (n ≤ k)
pure (... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | exact h | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case left
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
n x : ℕ
h✝ :
(fun n => do
guard (n ≤ k)
pure (... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | exact h | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case right
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
n x : ℕ
h✝ :
(fun n => do
guard (n ≤ k)
pure ... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | exact h | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case pair
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf cg : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x → eva... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp? [Seq.seq] at h ⊢ says
simp only [Seq.seq, Option.map_eq_map, Option.mem_def, Option.bind_eq_some,
Option.map_eq_some', exists_exists_and_eq_and] at h ⊢ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case pair
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf cg : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x → eva... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp only [Seq.seq, Option.map_eq_map, Option.mem_def, Option.bind_eq_some,
Option.map_eq_some', exists_exists_and_eq_and] at h ⊢ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case pair
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf cg : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x → eva... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | exact h.imp fun a => And.imp (hf _ _) <| Exists.imp fun b => And.imp_left (hg _ _) | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case comp
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf cg : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x → eva... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp? [Bind.bind] at h ⊢ says simp only [bind, Option.mem_def, Option.bind_eq_some] at h ⊢ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case comp
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf cg : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x → eva... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp only [bind, Option.mem_def, Option.bind_eq_some] at h ⊢ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case comp
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf cg : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x → eva... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | exact h.imp fun a => And.imp (hg _ _) (hf _ _) | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case prec
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf cg : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x → eva... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | revert h | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case prec
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf cg : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x → eva... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp only [unpaired, bind, Option.mem_def] | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case prec
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf cg : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x → eva... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | induction n.unpair.2 | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case prec.zero
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf cg : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x ... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case prec.succ
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf cg : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x ... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case prec.zero
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf cg : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x ... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | apply hf | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case prec.succ
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf cg : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x ... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | exact fun y h₁ h₂ => ⟨y, evaln_mono hl' h₁, hg _ _ h₂⟩ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case rfind'
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x → eval... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp? [Bind.bind] at h ⊢ says
simp only [unpaired, bind, pair_unpair, Option.mem_def, Option.bind_eq_some] at h ⊢ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case rfind'
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x → eval... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp only [unpaired, bind, pair_unpair, Option.mem_def, Option.bind_eq_some] at h ⊢ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case rfind'
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x → eval... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | refine' h.imp fun x => And.imp (hf _ _) _ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case rfind'
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x → eval... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | by_cases x0 : x = 0 | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case pos
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x → evaln (... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp [x0] | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case neg
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x → evaln (... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp [x0] | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
case neg
k k₂ : ℕ
hl : k + 1 ≤ k₂ + 1
hl' : k ≤ k₂
this :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ →
(x ∈ o₁ → x ∈ o₂) →
(x ∈ do
guard (n ≤ k)
o₁) →
x ∈ do
guard (n ≤ k₂)
o₂
cf : Code
hf : ∀ (n x : ℕ), evaln (k + 1) cf n = some x → evaln (... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | exact evaln_mono hl' | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' := Nat.le_of_succ_le_succ hl
have :
∀ {k k₂ n x : ℕ} {o₁ o₂ : Option ℕ},
k ≤ k₂ → (x ∈ o₁ → x ∈ o₂) →
x ∈ ... | Mathlib.Computability.PartrecCode.783_0.A3c3Aev6SyIRjCJ | theorem evaln_mono : ∀ {k₁ k₂ c n x}, k₁ ≤ k₂ → x ∈ evaln k₁ c n → x ∈ evaln k₂ c n
| 0, k₂, c, n, x, _, h => by simp [evaln] at h
| k + 1, k₂ + 1, c, n, x, hl, h => by
have hl' | Mathlib_Computability_PartrecCode |
x✝ : Code
n x : ℕ
h : x ∈ evaln 0 x✝ n
⊢ x ∈ eval x✝ n | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp [evaln] at h | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
k : ℕ
c : Code
n x : ℕ
h : x ∈ evaln (k + 1) c n
⊢ x ∈ eval c n | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
| Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case zero
k n x : ℕ
h : x ∈ evaln (k + 1) zero n
⊢ x ∈ eval zero n | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
| Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case succ
k n x : ℕ
h : x ∈ evaln (k + 1) succ n
⊢ x ∈ eval succ n | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
| Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case left
k n x : ℕ
h : x ∈ evaln (k + 1) left n
⊢ x ∈ eval left n | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
| Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case right
k n x : ℕ
h : x ∈ evaln (k + 1) right n
⊢ x ∈ eval right n | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
| Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case pair
k : ℕ
cf cg : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
hg : ∀ (n x : ℕ), x ∈ evaln (k + 1) cg n → x ∈ eval cg n
n x : ℕ
h : x ∈ evaln (k + 1) (pair cf cg) n
⊢ x ∈ eval (pair cf cg) n | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
| Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case comp
k : ℕ
cf cg : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
hg : ∀ (n x : ℕ), x ∈ evaln (k + 1) cg n → x ∈ eval cg n
n x : ℕ
h : x ∈ evaln (k + 1) (comp cf cg) n
⊢ x ∈ eval (comp cf cg) n | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
| Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case prec
k : ℕ
cf cg : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
hg : ∀ (n x : ℕ), x ∈ evaln (k + 1) cg n → x ∈ eval cg n
n x : ℕ
h : x ∈ evaln (k + 1) (prec cf cg) n
⊢ x ∈ eval (prec cf cg) n | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
| Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case rfind'
k : ℕ
cf : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
n x : ℕ
h : x ∈ evaln (k + 1) (rfind' cf) n
⊢ x ∈ eval (rfind' cf) n | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
| Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case zero
k n x : ℕ
h : n ≤ k ∧ pure 0 = some x
⊢ x ∈ pure 0 n | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | cases' h with _ h | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
| Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case succ
k n x : ℕ
h : n ≤ k ∧ pure (Nat.succ n) = some x
⊢ x = Nat.succ n | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | cases' h with _ h | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
| Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case left
k n x : ℕ
h : n ≤ k ∧ pure (unpair n).1 = some x
⊢ x = (unpair n).1 | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | cases' h with _ h | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
| Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case right
k n x : ℕ
h : n ≤ k ∧ pure (unpair n).2 = some x
⊢ x = (unpair n).2 | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | cases' h with _ h | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
| Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case pair
k : ℕ
cf cg : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
hg : ∀ (n x : ℕ), x ∈ evaln (k + 1) cg n → x ∈ eval cg n
n x : ℕ
h : n ≤ k ∧ ∃ a, evaln (k + 1) cf n = some a ∧ ∃ a_1, evaln (k + 1) cg n = some a_1 ∧ Nat.pair a a_1 = x
⊢ ∃ a ∈ eval cf n, ∃ a_1 ∈ eval cg n, Nat.pair a a_1 = x | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | cases' h with _ h | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
| Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case comp
k : ℕ
cf cg : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
hg : ∀ (n x : ℕ), x ∈ evaln (k + 1) cg n → x ∈ eval cg n
n x : ℕ
h : n ≤ k ∧ ∃ a, evaln (k + 1) cg n = some a ∧ evaln (k + 1) cf a = some x
⊢ ∃ a ∈ eval cg n, x ∈ eval cf a | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | cases' h with _ h | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
| Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case prec
k : ℕ
cf cg : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
hg : ∀ (n x : ℕ), x ∈ evaln (k + 1) cg n → x ∈ eval cg n
n x : ℕ
h :
n ≤ k ∧
Nat.rec (evaln (k + 1) cf (unpair n).1)
(fun n_1 n_ih =>
Option.bind (evaln k (prec cf cg) (Nat.pair (unpair n).1 n_1)) fun i =>
... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | cases' h with _ h | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
| Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case rfind'
k : ℕ
cf : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
n x : ℕ
h :
n ≤ k ∧
∃ a,
evaln (k + 1) cf n = some a ∧
(if a = 0 then pure (unpair n).2 else evaln k (rfind' cf) (Nat.pair (unpair n).1 ((unpair n).2 + 1))) = some x
⊢ ∃ a,
(0 ∈ eval cf (Nat.pair (unpair n).1 (a... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | cases' h with _ h | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
| Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case zero.intro
k n x : ℕ
left✝ : n ≤ k
h : pure 0 = some x
⊢ x ∈ pure 0 n
case succ.intro
k n x : ℕ
left✝ : n ≤ k
h : pure (Nat.succ n) = some x
⊢ x = Nat.succ n
case left.intro
k n x : ℕ
left✝ : n ≤ k
h : pure (unpair n).1 = some x
⊢ x = (unpair n).1
case right.intro
k n x : ℕ
left✝ : n ≤ k
h : pure (unpair n).2 = so... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | iterate 4 simpa [pure, PFun.pure, eq_comm] using h | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
| Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case zero.intro
k n x : ℕ
left✝ : n ≤ k
h : pure 0 = some x
⊢ x ∈ pure 0 n
case succ.intro
k n x : ℕ
left✝ : n ≤ k
h : pure (Nat.succ n) = some x
⊢ x = Nat.succ n
case left.intro
k n x : ℕ
left✝ : n ≤ k
h : pure (unpair n).1 = some x
⊢ x = (unpair n).1
case right.intro
k n x : ℕ
left✝ : n ≤ k
h : pure (unpair n).2 = so... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simpa [pure, PFun.pure, eq_comm] using h | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case succ.intro
k n x : ℕ
left✝ : n ≤ k
h : pure (Nat.succ n) = some x
⊢ x = Nat.succ n
case left.intro
k n x : ℕ
left✝ : n ≤ k
h : pure (unpair n).1 = some x
⊢ x = (unpair n).1
case right.intro
k n x : ℕ
left✝ : n ≤ k
h : pure (unpair n).2 = some x
⊢ x = (unpair n).2
case pair.intro
k : ℕ
cf cg : Code
hf : ∀ (n x : ℕ)... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simpa [pure, PFun.pure, eq_comm] using h | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case left.intro
k n x : ℕ
left✝ : n ≤ k
h : pure (unpair n).1 = some x
⊢ x = (unpair n).1
case right.intro
k n x : ℕ
left✝ : n ≤ k
h : pure (unpair n).2 = some x
⊢ x = (unpair n).2
case pair.intro
k : ℕ
cf cg : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
hg : ∀ (n x : ℕ), x ∈ evaln (k + 1) cg n → x ∈ ... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simpa [pure, PFun.pure, eq_comm] using h | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case right.intro
k n x : ℕ
left✝ : n ≤ k
h : pure (unpair n).2 = some x
⊢ x = (unpair n).2
case pair.intro
k : ℕ
cf cg : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
hg : ∀ (n x : ℕ), x ∈ evaln (k + 1) cg n → x ∈ eval cg n
n x : ℕ
left✝ : n ≤ k
h : ∃ a, evaln (k + 1) cf n = some a ∧ ∃ a_1, evaln (k + 1... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simpa [pure, PFun.pure, eq_comm] using h | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case pair.intro
k : ℕ
cf cg : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
hg : ∀ (n x : ℕ), x ∈ evaln (k + 1) cg n → x ∈ eval cg n
n x : ℕ
left✝ : n ≤ k
h : ∃ a, evaln (k + 1) cf n = some a ∧ ∃ a_1, evaln (k + 1) cg n = some a_1 ∧ Nat.pair a a_1 = x
⊢ ∃ a ∈ eval cf n, ∃ a_1 ∈ eval cg n, Nat.pair a a_1... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | rcases h with ⟨y, ef, z, eg, rfl⟩ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case pair.intro.intro.intro.intro.intro
k : ℕ
cf cg : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
hg : ∀ (n x : ℕ), x ∈ evaln (k + 1) cg n → x ∈ eval cg n
n : ℕ
left✝ : n ≤ k
y : ℕ
ef : evaln (k + 1) cf n = some y
z : ℕ
eg : evaln (k + 1) cg n = some z
⊢ ∃ a ∈ eval cf n, ∃ a_1 ∈ eval cg n, Nat.pair a ... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | exact ⟨_, hf _ _ ef, _, hg _ _ eg, rfl⟩ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case comp.intro
k : ℕ
cf cg : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
hg : ∀ (n x : ℕ), x ∈ evaln (k + 1) cg n → x ∈ eval cg n
n x : ℕ
left✝ : n ≤ k
h : ∃ a, evaln (k + 1) cg n = some a ∧ evaln (k + 1) cf a = some x
⊢ ∃ a ∈ eval cg n, x ∈ eval cf a | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | rcases h with ⟨y, eg, ef⟩ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case comp.intro.intro.intro
k : ℕ
cf cg : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
hg : ∀ (n x : ℕ), x ∈ evaln (k + 1) cg n → x ∈ eval cg n
n x : ℕ
left✝ : n ≤ k
y : ℕ
eg : evaln (k + 1) cg n = some y
ef : evaln (k + 1) cf y = some x
⊢ ∃ a ∈ eval cg n, x ∈ eval cf a | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | exact ⟨_, hg _ _ eg, hf _ _ ef⟩ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case prec.intro
k : ℕ
cf cg : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
hg : ∀ (n x : ℕ), x ∈ evaln (k + 1) cg n → x ∈ eval cg n
n x : ℕ
left✝ : n ≤ k
h :
Nat.rec (evaln (k + 1) cf (unpair n).1)
(fun n_1 n_ih =>
Option.bind (evaln k (prec cf cg) (Nat.pair (unpair n).1 n_1)) fun i =>
... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | revert h | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case prec.intro
k : ℕ
cf cg : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
hg : ∀ (n x : ℕ), x ∈ evaln (k + 1) cg n → x ∈ eval cg n
n x : ℕ
left✝ : n ≤ k
⊢ Nat.rec (evaln (k + 1) cf (unpair n).1)
(fun n_1 n_ih =>
Option.bind (evaln k (prec cf cg) (Nat.pair (unpair n).1 n_1)) fun i =>
... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | induction' n.unpair.2 with m IH generalizing x | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case prec.intro.zero
k : ℕ
cf cg : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
hg : ∀ (n x : ℕ), x ∈ evaln (k + 1) cg n → x ∈ eval cg n
n : ℕ
left✝ : n ≤ k
x : ℕ
⊢ Nat.rec (evaln (k + 1) cf (unpair n).1)
(fun n_1 n_ih =>
Option.bind (evaln k (prec cf cg) (Nat.pair (unpair n).1 n_1)) ... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case prec.intro.succ
k : ℕ
cf cg : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
hg : ∀ (n x : ℕ), x ∈ evaln (k + 1) cg n → x ∈ eval cg n
n : ℕ
left✝ : n ≤ k
m : ℕ
IH :
∀ (x : ℕ),
Nat.rec (evaln (k + 1) cf (unpair n).1)
(fun n_1 n_ih =>
Option.bind (evaln k (prec cf cg) (Nat.... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case prec.intro.zero
k : ℕ
cf cg : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
hg : ∀ (n x : ℕ), x ∈ evaln (k + 1) cg n → x ∈ eval cg n
n : ℕ
left✝ : n ≤ k
x : ℕ
⊢ evaln (k + 1) cf (unpair n).1 = some x → x ∈ eval cf (unpair n).1 | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | apply hf | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case prec.intro.succ
k : ℕ
cf cg : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
hg : ∀ (n x : ℕ), x ∈ evaln (k + 1) cg n → x ∈ eval cg n
n : ℕ
left✝ : n ≤ k
m : ℕ
IH :
∀ (x : ℕ),
Nat.rec (evaln (k + 1) cf (unpair n).1)
(fun n_1 n_ih =>
Option.bind (evaln k (prec cf cg) (Nat.... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | refine' fun y h₁ h₂ => ⟨y, IH _ _, _⟩ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case prec.intro.succ.refine'_1
k : ℕ
cf cg : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
hg : ∀ (n x : ℕ), x ∈ evaln (k + 1) cg n → x ∈ eval cg n
n : ℕ
left✝ : n ≤ k
m : ℕ
IH :
∀ (x : ℕ),
Nat.rec (evaln (k + 1) cf (unpair n).1)
(fun n_1 n_ih =>
Option.bind (evaln k (prec cf... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | have := evaln_mono k.le_succ h₁ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case prec.intro.succ.refine'_1
k : ℕ
cf cg : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
hg : ∀ (n x : ℕ), x ∈ evaln (k + 1) cg n → x ∈ eval cg n
n : ℕ
left✝ : n ≤ k
m : ℕ
IH :
∀ (x : ℕ),
Nat.rec (evaln (k + 1) cf (unpair n).1)
(fun n_1 n_ih =>
Option.bind (evaln k (prec cf... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp [evaln, Bind.bind] at this | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case prec.intro.succ.refine'_1
k : ℕ
cf cg : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
hg : ∀ (n x : ℕ), x ∈ evaln (k + 1) cg n → x ∈ eval cg n
n : ℕ
left✝ : n ≤ k
m : ℕ
IH :
∀ (x : ℕ),
Nat.rec (evaln (k + 1) cf (unpair n).1)
(fun n_1 n_ih =>
Option.bind (evaln k (prec cf... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | exact this.2 | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case prec.intro.succ.refine'_2
k : ℕ
cf cg : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
hg : ∀ (n x : ℕ), x ∈ evaln (k + 1) cg n → x ∈ eval cg n
n : ℕ
left✝ : n ≤ k
m : ℕ
IH :
∀ (x : ℕ),
Nat.rec (evaln (k + 1) cf (unpair n).1)
(fun n_1 n_ih =>
Option.bind (evaln k (prec cf... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | exact hg _ _ h₂ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case rfind'.intro
k : ℕ
cf : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
n x : ℕ
left✝ : n ≤ k
h :
∃ a,
evaln (k + 1) cf n = some a ∧
(if a = 0 then pure (unpair n).2 else evaln k (rfind' cf) (Nat.pair (unpair n).1 ((unpair n).2 + 1))) = some x
⊢ ∃ a,
(0 ∈ eval cf (Nat.pair (unpair n).... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | rcases h with ⟨m, h₁, h₂⟩ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case rfind'.intro.intro.intro
k : ℕ
cf : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
n x : ℕ
left✝ : n ≤ k
m : ℕ
h₁ : evaln (k + 1) cf n = some m
h₂ : (if m = 0 then pure (unpair n).2 else evaln k (rfind' cf) (Nat.pair (unpair n).1 ((unpair n).2 + 1))) = some x
⊢ ∃ a,
(0 ∈ eval cf (Nat.pair (unpai... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | by_cases m0 : m = 0 | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case pos
k : ℕ
cf : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
n x : ℕ
left✝ : n ≤ k
m : ℕ
h₁ : evaln (k + 1) cf n = some m
h₂ : (if m = 0 then pure (unpair n).2 else evaln k (rfind' cf) (Nat.pair (unpair n).1 ((unpair n).2 + 1))) = some x
m0 : m = 0
⊢ ∃ a,
(0 ∈ eval cf (Nat.pair (unpair n).1 (a ... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp [m0] at h₂ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case neg
k : ℕ
cf : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
n x : ℕ
left✝ : n ≤ k
m : ℕ
h₁ : evaln (k + 1) cf n = some m
h₂ : (if m = 0 then pure (unpair n).2 else evaln k (rfind' cf) (Nat.pair (unpair n).1 ((unpair n).2 + 1))) = some x
m0 : ¬m = 0
⊢ ∃ a,
(0 ∈ eval cf (Nat.pair (unpair n).1 (a... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp [m0] at h₂ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case pos
k : ℕ
cf : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
n x : ℕ
left✝ : n ≤ k
m : ℕ
h₁ : evaln (k + 1) cf n = some m
m0 : m = 0
h₂ : pure (unpair n).2 = some x
⊢ ∃ a,
(0 ∈ eval cf (Nat.pair (unpair n).1 (a + (unpair n).2)) ∧
∀ {m : ℕ}, m < a → ∃ a ∈ eval cf (Nat.pair (unpair n).1 (... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | exact
⟨0, ⟨by simpa [m0] using hf _ _ h₁, fun {m} => (Nat.not_lt_zero _).elim⟩, by
injection h₂ with h₂; simp [h₂]⟩ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
k : ℕ
cf : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
n x : ℕ
left✝ : n ≤ k
m : ℕ
h₁ : evaln (k + 1) cf n = some m
m0 : m = 0
h₂ : pure (unpair n).2 = some x
⊢ 0 ∈ eval cf (Nat.pair (unpair n).1 (0 + (unpair n).2)) | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simpa [m0] using hf _ _ h₁ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
k : ℕ
cf : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
n x : ℕ
left✝ : n ≤ k
m : ℕ
h₁ : evaln (k + 1) cf n = some m
m0 : m = 0
h₂ : pure (unpair n).2 = some x
⊢ 0 + (unpair n).2 = x | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | injection h₂ with h₂ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
k : ℕ
cf : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
n x : ℕ
left✝ : n ≤ k
m : ℕ
h₁ : evaln (k + 1) cf n = some m
m0 : m = 0
h₂ : (unpair n).2 = x
⊢ 0 + (unpair n).2 = x | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp [h₂] | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case neg
k : ℕ
cf : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
n x : ℕ
left✝ : n ≤ k
m : ℕ
h₁ : evaln (k + 1) cf n = some m
m0 : ¬m = 0
h₂ : evaln k (rfind' cf) (Nat.pair (unpair n).1 ((unpair n).2 + 1)) = some x
⊢ ∃ a,
(0 ∈ eval cf (Nat.pair (unpair n).1 (a + (unpair n).2)) ∧
∀ {m : ℕ}, ... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | have := evaln_sound h₂ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case neg
k : ℕ
cf : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
n x : ℕ
left✝ : n ≤ k
m : ℕ
h₁ : evaln (k + 1) cf n = some m
m0 : ¬m = 0
h₂ : evaln k (rfind' cf) (Nat.pair (unpair n).1 ((unpair n).2 + 1)) = some x
this : x ∈ eval (rfind' cf) (Nat.pair (unpair n).1 ((unpair n).2 + 1))
⊢ ∃ a,
(0 ∈ e... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simp [eval] at this | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case neg
k : ℕ
cf : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
n x : ℕ
left✝ : n ≤ k
m : ℕ
h₁ : evaln (k + 1) cf n = some m
m0 : ¬m = 0
h₂ : evaln k (rfind' cf) (Nat.pair (unpair n).1 ((unpair n).2 + 1)) = some x
this :
∃ a,
(0 ∈ eval cf (Nat.pair (unpair n).1 (a + ((unpair n).2 + 1))) ∧
... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | rcases this with ⟨y, ⟨hy₁, hy₂⟩, rfl⟩ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
case neg.intro.intro.intro
k : ℕ
cf : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
n : ℕ
left✝ : n ≤ k
m : ℕ
h₁ : evaln (k + 1) cf n = some m
m0 : ¬m = 0
y : ℕ
hy₁ : 0 ∈ eval cf (Nat.pair (unpair n).1 (y + ((unpair n).2 + 1)))
hy₂ : ∀ {m : ℕ}, m < y → ∃ a ∈ eval cf (Nat.pair (unpair n).1 (m + ((unpair ... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | refine'
⟨y + 1, ⟨by simpa [add_comm, add_left_comm] using hy₁, fun {i} im => _⟩, by
simp [add_comm, add_left_comm]⟩ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
k : ℕ
cf : Code
hf : ∀ (n x : ℕ), x ∈ evaln (k + 1) cf n → x ∈ eval cf n
n : ℕ
left✝ : n ≤ k
m : ℕ
h₁ : evaln (k + 1) cf n = some m
m0 : ¬m = 0
y : ℕ
hy₁ : 0 ∈ eval cf (Nat.pair (unpair n).1 (y + ((unpair n).2 + 1)))
hy₂ : ∀ {m : ℕ}, m < y → ∃ a ∈ eval cf (Nat.pair (unpair n).1 (m + ((unpair n).2 + 1))), ¬a = 0
h₂ : ev... | /-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Computability.Partrec
#align_import computability.partrec_code from "leanprover-community/mathlib"@"6155d4351090a6fad236e3d2e4e0e4e7342668e8"
/-!
# G... | simpa [add_comm, add_left_comm] using hy₁ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib.Computability.PartrecCode.821_0.A3c3Aev6SyIRjCJ | theorem evaln_sound : ∀ {k c n x}, x ∈ evaln k c n → x ∈ eval c n
| 0, _, n, x, h => by simp [evaln] at h
| k + 1, c, n, x, h => by
induction' c with cf cg hf hg cf cg hf hg cf cg hf hg cf hf generalizing x n <;>
simp [eval, evaln, Bind.bind, Seq.seq] at h ⊢ <;>
cases' h with _ h
iterate 4 sim... | Mathlib_Computability_PartrecCode |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.