File: .lake/packages/lean4/src/lean/Init/PropLemmas.lean

full_name: eq_mp_eq_cast
code: @[simp] theorem eq_mp_eq_cast  (h : α = β) : Eq.mp  h = cast h 
goal: h.mp = cast h

full_name: eq_mpr_eq_cast
code: @[simp] theorem eq_mpr_eq_cast (h : α = β) : Eq.mpr h = cast h.symm 
goal: h.mpr = cast ⋯

full_name: cast_cast
code: @[simp] theorem cast_cast : ∀ (ha : α = β) (hb : β = γ) (a : α),
    cast hb (cast ha a) = cast (ha.trans hb) a
  
goal: cast hb (cast ha a) = cast ⋯ a

full_name: eq_true_eq_id
code: @[simp] theorem eq_true_eq_id : Eq True = id 
goal: Eq True = id

full_name: proof_irrel_heq
code: theorem proof_irrel_heq {p q : Prop} (hp : p) (hq : q) : HEq hp hq 
goal: HEq hp hq

full_name: not_not_em
code: theorem not_not_em (a : Prop) : ¬¬(a ∨ ¬a) 
goal: ¬¬(a ∨ ¬a)

full_name: and_self_iff
code: theorem and_self_iff : a ∧ a ↔ a 
goal: a ∧ a ↔ a

full_name: and_not_self_iff
code: theorem and_not_self_iff (a : Prop) : a ∧ ¬a ↔ False 
goal: a ∧ ¬a ↔ False

full_name: not_and_self_iff
code: theorem not_and_self_iff (a : Prop) : ¬a ∧ a ↔ False 
goal: ¬a ∧ a ↔ False

full_name: And.imp
code: theorem And.imp (f : a → c) (g : b → d) (h : a ∧ b) : c ∧ d 
goal: c ∧ d

full_name: And.imp_left
code: theorem And.imp_left (h : a → b) : a ∧ c → b ∧ c 
goal: a ∧ c → b ∧ c

full_name: And.imp_right
code: theorem And.imp_right (h : a → b) : c ∧ a → c ∧ b 
goal: c ∧ a → c ∧ b

full_name: and_congr
code: theorem and_congr (h₁ : a ↔ c) (h₂ : b ↔ d) : a ∧ b ↔ c ∧ d 
goal: a ∧ b ↔ c ∧ d

full_name: and_congr_left'
code: theorem and_congr_left' (h : a ↔ b) : a ∧ c ↔ b ∧ c 
goal: a ∧ c ↔ b ∧ c

full_name: and_congr_right'
code: theorem and_congr_right' (h : b ↔ c) : a ∧ b ↔ a ∧ c 
goal: a ∧ b ↔ a ∧ c

full_name: not_and_of_not_left
code: theorem not_and_of_not_left (b : Prop) : ¬a → ¬(a ∧ b) 
goal: ¬a → ¬(a ∧ b)

full_name: not_and_of_not_right
code: theorem not_and_of_not_right (a : Prop) {b : Prop} : ¬b → ¬(a ∧ b) 
goal: ¬b → ¬(a ∧ b)

full_name: and_congr_right_eq
code: theorem and_congr_right_eq (h : a → b = c) : (a ∧ b) = (a ∧ c) 
goal: (a ∧ b) = (a ∧ c)

full_name: and_congr_left_eq
code: theorem and_congr_left_eq  (h : c → a = b) : (a ∧ c) = (b ∧ c) 
goal: (a ∧ c) = (b ∧ c)

full_name: and_left_comm
code: theorem and_left_comm : a ∧ b ∧ c ↔ b ∧ a ∧ c 
goal: a ∧ b ∧ c ↔ b ∧ a ∧ c

full_name: and_right_comm
code: theorem and_right_comm : (a ∧ b) ∧ c ↔ (a ∧ c) ∧ b 
goal: (a ∧ b) ∧ c ↔ (a ∧ c) ∧ b

full_name: and_rotate
code: theorem and_rotate : a ∧ b ∧ c ↔ b ∧ c ∧ a 
goal: a ∧ b ∧ c ↔ b ∧ c ∧ a

full_name: and_and_and_comm
code: theorem and_and_and_comm : (a ∧ b) ∧ c ∧ d ↔ (a ∧ c) ∧ b ∧ d 
goal: (a ∧ b) ∧ c ∧ d ↔ (a ∧ c) ∧ b ∧ d

full_name: and_and_left
code: theorem and_and_left  : a ∧ (b ∧ c) ↔ (a ∧ b) ∧ a ∧ c 
goal: a ∧ b ∧ c ↔ (a ∧ b) ∧ a ∧ c

full_name: and_and_right
code: theorem and_and_right : (a ∧ b) ∧ c ↔ (a ∧ c) ∧ b ∧ c 
goal: (a ∧ b) ∧ c ↔ (a ∧ c) ∧ b ∧ c

full_name: and_iff_left
code: theorem and_iff_left  (hb : b) : a ∧ b ↔ a 
goal: a ∧ b ↔ a

full_name: and_iff_right
code: theorem and_iff_right (ha : a) : a ∧ b ↔ b 
goal: a ∧ b ↔ b

full_name: or_self_iff
code: theorem or_self_iff : a ∨ a ↔ a 
goal: a ∨ a ↔ a

full_name: not_or_intro
code: theorem not_or_intro {a b : Prop} (ha : ¬a) (hb : ¬b) : ¬(a ∨ b) 
goal: ¬(a ∨ b)

full_name: or_congr
code: theorem or_congr (h₁ : a ↔ c) (h₂ : b ↔ d) : (a ∨ b) ↔ (c ∨ d) 
goal: a ∨ b ↔ c ∨ d

full_name: or_congr_left
code: theorem or_congr_left (h : a ↔ b) : a ∨ c ↔ b ∨ c 
goal: a ∨ c ↔ b ∨ c

full_name: or_congr_right
code: theorem or_congr_right (h : b ↔ c) : a ∨ b ↔ a ∨ c 
goal: a ∨ b ↔ a ∨ c

full_name: or_left_comm
code: theorem or_left_comm  : a ∨ (b ∨ c) ↔ b ∨ (a ∨ c) 
goal: a ∨ b ∨ c ↔ b ∨ a ∨ c

full_name: or_right_comm
code: theorem or_right_comm : (a ∨ b) ∨ c ↔ (a ∨ c) ∨ b 
goal: (a ∨ b) ∨ c ↔ (a ∨ c) ∨ b

full_name: or_or_or_comm
code: theorem or_or_or_comm : (a ∨ b) ∨ c ∨ d ↔ (a ∨ c) ∨ b ∨ d 
goal: (a ∨ b) ∨ c ∨ d ↔ (a ∨ c) ∨ b ∨ d

full_name: or_or_distrib_left
code: theorem or_or_distrib_left : a ∨ b ∨ c ↔ (a ∨ b) ∨ a ∨ c 
goal: a ∨ b ∨ c ↔ (a ∨ b) ∨ a ∨ c

full_name: or_or_distrib_right
code: theorem or_or_distrib_right : (a ∨ b) ∨ c ↔ (a ∨ c) ∨ b ∨ c 
goal: (a ∨ b) ∨ c ↔ (a ∨ c) ∨ b ∨ c

full_name: or_rotate
code: theorem or_rotate : a ∨ b ∨ c ↔ b ∨ c ∨ a 
goal: a ∨ b ∨ c ↔ b ∨ c ∨ a

full_name: or_iff_left
code: theorem or_iff_left  (hb : ¬b) : a ∨ b ↔ a 
goal: a ∨ b ↔ a

full_name: or_iff_right
code: theorem or_iff_right (ha : ¬a) : a ∨ b ↔ b 
goal: a ∨ b ↔ b

full_name: not_imp_of_and_not
code: theorem not_imp_of_and_not : a ∧ ¬b → ¬(a → b)
  
goal: a ∧ ¬b → ¬(a → b)

full_name: imp_and
code: theorem imp_and {α} : (α → b ∧ c) ↔ (α → b) ∧ (α → c) 
goal: α → b ∧ c ↔ (α → b) ∧ (α → c)

full_name: not_and'
code: theorem not_and' : ¬(a ∧ b) ↔ b → ¬a 
goal: ¬(a ∧ b) ↔ b → ¬a

full_name: and_or_left
code: /-- `∧` distributes over `∨` (on the left). -/
theorem and_or_left : a ∧ (b ∨ c) ↔ (a ∧ b) ∨ (a ∧ c) 
goal: a ∧ (b ∨ c) ↔ a ∧ b ∨ a ∧ c

full_name: or_and_right
code: /-- `∧` distributes over `∨` (on the right). -/
theorem or_and_right : (a ∨ b) ∧ c ↔ (a ∧ c) ∨ (b ∧ c) 
goal: (a ∨ b) ∧ c ↔ a ∧ c ∨ b ∧ c

full_name: or_and_left
code: /-- `∨` distributes over `∧` (on the left). -/
theorem or_and_left : a ∨ (b ∧ c) ↔ (a ∨ b) ∧ (a ∨ c) 
goal: a ∨ b ∧ c ↔ (a ∨ b) ∧ (a ∨ c)

full_name: and_or_right
code: /-- `∨` distributes over `∧` (on the right). -/
theorem and_or_right : (a ∧ b) ∨ c ↔ (a ∨ c) ∧ (b ∨ c) 
goal: a ∧ b ∨ c ↔ (a ∨ c) ∧ (b ∨ c)

full_name: or_imp
code: theorem or_imp : (a ∨ b → c) ↔ (a → c) ∧ (b → c) 
goal: a ∨ b → c ↔ (a → c) ∧ (b → c)

full_name: not_or
code: @[simp] theorem not_or : ¬(p ∨ q) ↔ ¬p ∧ ¬q 
goal: ¬(p ∨ q) ↔ ¬p ∧ ¬q

full_name: not_and_of_not_or_not
code: theorem not_and_of_not_or_not (h : ¬a ∨ ¬b) : ¬(a ∧ b) 
goal: ¬(a ∧ b)

full_name: if_false_left
code: @[simp]
theorem if_false_left [h : Decidable p] :
    ite p False q ↔ ¬p ∧ q 
goal: (if p then False else q) ↔ ¬p ∧ q

full_name: if_false_right
code: @[simp]
theorem if_false_right [h : Decidable p] :
    ite p q False ↔ p ∧ q 
goal: (if p then q else False) ↔ p ∧ q

full_name: if_true_left
code: @[simp low]
theorem if_true_left [h : Decidable p] :
    ite p True q ↔ ¬p → q 
goal: (if p then True else q) ↔ ¬p → q

full_name: if_true_right
code: @[simp low]
theorem if_true_right [h : Decidable p] :
    ite p q True ↔ p → q 
goal: (if p then q else True) ↔ p → q

full_name: dite_not
code: /-- Negation of the condition `P : Prop` in a `dite` is the same as swapping the branches. -/
@[simp] theorem dite_not [hn : Decidable (¬p)] [h : Decidable p]  (x : ¬p → α) (y : ¬¬p → α) :
    dite (¬p) x y = dite p (fun h => y (not_not_intro h)) x 
goal: dite (¬p) x y = dite p (fun h => y ⋯) x

full_name: ite_not
code: /-- Negation of the condition `P : Prop` in a `ite` is the same as swapping the branches. -/
@[simp] theorem ite_not (p : Prop) [Decidable p] (x y : α) : ite (¬p) x y = ite p y x 
goal: (if ¬p then x else y) = if p then y else x

full_name: ite_true_same
code: @[simp] theorem ite_true_same (p q : Prop) [h : Decidable p] : (if p then p else q) = (¬p → q) 
goal: (if p then p else q) = (¬p → q)

full_name: ite_false_same
code: @[simp] theorem ite_false_same (p q : Prop) [h : Decidable p] : (if p then q else p) = (p ∧ q) 
goal: (if p then q else p) = (p ∧ q)

full_name: forall_imp
code: theorem forall_imp (h : ∀ a, p a → q a) : (∀ a, p a) → ∀ a, q a 
goal: (∀ (a : α), p a) → ∀ (a : α), q a

full_name: forall_exists_index
code: /--
As `simp` does not index foralls, this `@[simp]` lemma is tried on every `forall` expression.
This is not ideal, and likely a performance issue, but it is difficult to remove this attribute at this time.
-/
@[simp] theorem forall_exists_index {q : (∃ x, p x) → Prop} :
    (∀ h, q h) ↔ ∀ x (h : p x), q ⟨x, h⟩ 
goal: (∀ (h : ∃ x, p x), q h) ↔ ∀ (x : α) (h : p x), q ⋯

full_name: Exists.imp
code: theorem Exists.imp (h : ∀ a, p a → q a) : (∃ a, p a) → ∃ a, q a
  
goal: (∃ a, p a) → ∃ a, q a

full_name: Exists.imp'
code: theorem Exists.imp' {β} {q : β → Prop} (f : α → β) (hpq : ∀ a, p a → q (f a)) :
    (∃ a, p a) → ∃ b, q b
  
goal: (∃ a, p a) → ∃ b, q b

full_name: exists_imp
code: theorem exists_imp : ((∃ x, p x) → b) ↔ ∀ x, p x → b 
goal: (∃ x, p x) → b ↔ ∀ (x : α), p x → b

full_name: exists_const
code: @[simp] theorem exists_const (α) [i : Nonempty α] : (∃ _ : α, b) ↔ b 
goal: (∃ x, b) ↔ b

full_name: forall_congr'
code: theorem forall_congr' (h : ∀ a, p a ↔ q a) : (∀ a, p a) ↔ ∀ a, q a 
goal: (∀ (a : α), p a) ↔ ∀ (a : α), q a

full_name: exists_congr
code: theorem exists_congr (h : ∀ a, p a ↔ q a) : (∃ a, p a) ↔ ∃ a, q a 
goal: (∃ a, p a) ↔ ∃ a, q a

full_name: forall₂_congr
code: theorem forall₂_congr {p q : ∀ a, β a → Prop} (h : ∀ a b, p a b ↔ q a b) :
    (∀ a b, p a b) ↔ ∀ a b, q a b 
goal: (∀ (a : α) (b : β a), p a b) ↔ ∀ (a : α) (b : β a), q a b

full_name: exists₂_congr
code: theorem exists₂_congr {p q : ∀ a, β a → Prop} (h : ∀ a b, p a b ↔ q a b) :
    (∃ a b, p a b) ↔ ∃ a b, q a b 
goal: (∃ a b, p a b) ↔ ∃ a b, q a b

full_name: forall₃_congr
code: theorem forall₃_congr {p q : ∀ a b, γ a b → Prop} (h : ∀ a b c, p a b c ↔ q a b c) :
    (∀ a b c, p a b c) ↔ ∀ a b c, q a b c 
goal: (∀ (a : α) (b : β a) (c : γ a b), p a b c) ↔ ∀ (a : α) (b : β a) (c : γ a b), q a b c

full_name: exists₃_congr
code: theorem exists₃_congr {p q : ∀ a b, γ a b → Prop} (h : ∀ a b c, p a b c ↔ q a b c) :
    (∃ a b c, p a b c) ↔ ∃ a b c, q a b c 
goal: (∃ a b c, p a b c) ↔ ∃ a b c, q a b c

full_name: forall₄_congr
code: theorem forall₄_congr {p q : ∀ a b c, δ a b c → Prop} (h : ∀ a b c d, p a b c d ↔ q a b c d) :
    (∀ a b c d, p a b c d) ↔ ∀ a b c d, q a b c d 
goal: (∀ (a : α) (b : β a) (c : γ a b) (d : δ a b c), p a b c d) ↔ ∀ (a : α) (b : β a) (c : γ a b) (d : δ a b c), q a b c d

full_name: exists₄_congr
code: theorem exists₄_congr {p q : ∀ a b c, δ a b c → Prop} (h : ∀ a b c d, p a b c d ↔ q a b c d) :
    (∃ a b c d, p a b c d) ↔ ∃ a b c d, q a b c d 
goal: (∃ a b c d, p a b c d) ↔ ∃ a b c d, q a b c d

full_name: forall₅_congr
code: theorem forall₅_congr {p q : ∀ a b c d, ε a b c d → Prop}
    (h : ∀ a b c d e, p a b c d e ↔ q a b c d e) :
    (∀ a b c d e, p a b c d e) ↔ ∀ a b c d e, q a b c d e 
goal: (∀ (a : α) (b : β a) (c : γ a b) (d : δ a b c) (e : ε a b c d), p a b c d e) ↔
  ∀ (a : α) (b : β a) (c : γ a b) (d : δ a b c) (e : ε a b c d), q a b c d e

full_name: exists₅_congr
code: theorem exists₅_congr {p q : ∀ a b c d, ε a b c d → Prop}
    (h : ∀ a b c d e, p a b c d e ↔ q a b c d e) :
    (∃ a b c d e, p a b c d e) ↔ ∃ a b c d e, q a b c d e 
goal: (∃ a b c d e, p a b c d e) ↔ ∃ a b c d e, q a b c d e

full_name: not_exists
code: @[simp] theorem not_exists : (¬∃ x, p x) ↔ ∀ x, ¬p x 
goal: (¬∃ x, p x) ↔ ∀ (x : α), ¬p x

full_name: forall_and
code: theorem forall_and : (∀ x, p x ∧ q x) ↔ (∀ x, p x) ∧ (∀ x, q x) 
goal: (∀ (x : α), p x ∧ q x) ↔ (∀ (x : α), p x) ∧ ∀ (x : α), q x

full_name: exists_or
code: theorem exists_or : (∃ x, p x ∨ q x) ↔ (∃ x, p x) ∨ ∃ x, q x 
goal: (∃ x, p x ∨ q x) ↔ (∃ x, p x) ∨ ∃ x, q x

full_name: exists_false
code: @[simp] theorem exists_false : ¬(∃ _a : α, False) 
goal: ¬∃ _a, False

full_name: forall_const
code: @[simp] theorem forall_const (α : Sort _) [i : Nonempty α] : (α → b) ↔ b 
goal: α → b ↔ b

full_name: Exists.nonempty
code: theorem Exists.nonempty : (∃ x, p x) → Nonempty α 
goal: (∃ x, p x) → Nonempty α

full_name: not_forall_of_exists_not
code: theorem not_forall_of_exists_not {p : α → Prop} : (∃ x, ¬p x) → ¬∀ x, p x
  
goal: (∃ x, ¬p x) → ¬∀ (x : α), p x

full_name: forall_eq
code: @[simp] theorem forall_eq {p : α → Prop} {a' : α} : (∀ a, a = a' → p a) ↔ p a' 
goal: (∀ (a : α), a = a' → p a) ↔ p a'

full_name: forall_eq'
code: @[simp] theorem forall_eq' {a' : α} : (∀ a, a' = a → p a) ↔ p a' 
goal: (∀ (a : α), a' = a → p a) ↔ p a'

full_name: exists_eq
code: @[simp] theorem exists_eq : ∃ a, a = a' 
goal: ∀ {α : Sort u_1} {a' : α}, ∃ a, a = a'

full_name: exists_eq'
code: @[simp] theorem exists_eq' : ∃ a, a' = a 
goal: ∀ {α : Sort u_1} {a' : α}, ∃ a, a' = a

full_name: exists_eq_left
code: @[simp] theorem exists_eq_left : (∃ a, a = a' ∧ p a) ↔ p a' 
goal: (∃ a, a = a' ∧ p a) ↔ p a'

full_name: exists_eq_right
code: @[simp] theorem exists_eq_right : (∃ a, p a ∧ a = a') ↔ p a' 
goal: (∃ a, p a ∧ a = a') ↔ p a'

full_name: exists_and_left
code: @[simp] theorem exists_and_left : (∃ x, b ∧ p x) ↔ b ∧ (∃ x, p x) 
goal: (∃ x, b ∧ p x) ↔ b ∧ ∃ x, p x

full_name: exists_and_right
code: @[simp] theorem exists_and_right : (∃ x, p x ∧ b) ↔ (∃ x, p x) ∧ b 
goal: (∃ x, p x ∧ b) ↔ (∃ x, p x) ∧ b

full_name: exists_eq_left'
code: @[simp] theorem exists_eq_left' : (∃ a, a' = a ∧ p a) ↔ p a' 
goal: (∃ a, a' = a ∧ p a) ↔ p a'

full_name: forall_eq_or_imp
code: @[simp] theorem forall_eq_or_imp : (∀ a, a = a' ∨ q a → p a) ↔ p a' ∧ ∀ a, q a → p a 
goal: (∀ (a : α), a = a' ∨ q a → p a) ↔ p a' ∧ ∀ (a : α), q a → p a

full_name: exists_eq_or_imp
code: @[simp] theorem exists_eq_or_imp : (∃ a, (a = a' ∨ q a) ∧ p a) ↔ p a' ∨ ∃ a, q a ∧ p a 
goal: (∃ a, (a = a' ∨ q a) ∧ p a) ↔ p a' ∨ ∃ a, q a ∧ p a

full_name: exists_eq_right_right
code: @[simp] theorem exists_eq_right_right : (∃ (a : α), p a ∧ q a ∧ a = a') ↔ p a' ∧ q a' 
goal: (∃ a, p a ∧ q a ∧ a = a') ↔ p a' ∧ q a'

full_name: exists_eq_right_right'
code: @[simp] theorem exists_eq_right_right' : (∃ (a : α), p a ∧ q a ∧ a' = a) ↔ p a' ∧ q a' 
goal: (∃ a, p a ∧ q a ∧ a' = a) ↔ p a' ∧ q a'

full_name: exists_prop
code: @[simp] theorem exists_prop : (∃ _h : a, b) ↔ a ∧ b 
goal: (∃ _h, b) ↔ a ∧ b

full_name: exists_apply_eq_apply
code: @[simp] theorem exists_apply_eq_apply (f : α → β) (a' : α) : ∃ a, f a = f a' 
goal: ∃ a, f a = f a'

full_name: forall_prop_of_true
code: theorem forall_prop_of_true {p : Prop} {q : p → Prop} (h : p) : (∀ h' : p, q h') ↔ q h 
goal: (∀ (h' : p), q h') ↔ q h

full_name: forall_comm
code: theorem forall_comm {p : α → β → Prop} : (∀ a b, p a b) ↔ (∀ b a, p a b) 
goal: (∀ (a : α) (b : β), p a b) ↔ ∀ (b : β) (a : α), p a b

full_name: exists_comm
code: theorem exists_comm {p : α → β → Prop} : (∃ a b, p a b) ↔ (∃ b a, p a b) 
goal: (∃ a b, p a b) ↔ ∃ b a, p a b

full_name: forall_apply_eq_imp_iff
code: @[simp] theorem forall_apply_eq_imp_iff {f : α → β} {p : β → Prop} :
    (∀ b a, f a = b → p b) ↔ ∀ a, p (f a) 
goal: (∀ (b : β) (a : α), f a = b → p b) ↔ ∀ (a : α), p (f a)

full_name: forall_eq_apply_imp_iff
code: @[simp] theorem forall_eq_apply_imp_iff {f : α → β} {p : β → Prop} :
    (∀ b a, b = f a → p b) ↔ ∀ a, p (f a) 
goal: (∀ (b : β) (a : α), b = f a → p b) ↔ ∀ (a : α), p (f a)

full_name: forall_apply_eq_imp_iff₂
code: @[simp] theorem forall_apply_eq_imp_iff₂ {f : α → β} {p : α → Prop} {q : β → Prop} :
    (∀ b a, p a → f a = b → q b) ↔ ∀ a, p a → q (f a) 
goal: (∀ (b : β) (a : α), p a → f a = b → q b) ↔ ∀ (a : α), p a → q (f a)

full_name: forall_prop_of_false
code: theorem forall_prop_of_false {p : Prop} {q : p → Prop} (hn : ¬p) : (∀ h' : p, q h') ↔ True 
goal: (∀ (h' : p), q h') ↔ True

full_name: Decidable.not_not
code: @[simp] theorem Decidable.not_not [Decidable p] : ¬¬p ↔ p 
goal: ¬¬p ↔ p

full_name: Decidable.or_not_self
code: /-- Excluded middle.  Added as alias for Decidable.em -/
abbrev Decidable.or_not_self 
goal: p ∨ ¬p

full_name: Decidable.not_or_self
code: /-- Excluded middle commuted.  Added as alias for Decidable.em -/
theorem Decidable.not_or_self (p : Prop) [h : Decidable p] : ¬p ∨ p 
goal: ¬p ∨ p

full_name: Decidable.by_contra
code: theorem Decidable.by_contra [Decidable p] : (¬p → False) → p 
goal: (¬p → False) → p

full_name: Or.by_cases
code: /-- Construct a non-Prop by cases on an `Or`, when the left conjunct is decidable. -/
protected def Or.by_cases [Decidable p] {α : Sort u} (h : p ∨ q) (h₁ : p → α) (h₂ : q → α) : α 
goal: α

full_name: Or.by_cases'
code: /-- Construct a non-Prop by cases on an `Or`, when the right conjunct is decidable. -/
protected def Or.by_cases' [Decidable q] {α : Sort u} (h : p ∨ q) (h₁ : p → α) (h₂ : q → α) : α 
goal: α

full_name: exists_prop_decidable
code: instance exists_prop_decidable {p} (P : p → Prop)
  [Decidable p] [∀ h, Decidable (P h)] : Decidable (∃ h, P h) 
goal: Decidable (∃ h, P h)

full_name: forall_prop_decidable
code: instance forall_prop_decidable {p} (P : p → Prop)
  [Decidable p] [∀ h, Decidable (P h)] : Decidable (∀ h, P h) 
goal: Decidable (∀ (h : p), P h)

full_name: decide_eq_true_iff
code: theorem decide_eq_true_iff (p : Prop) [Decidable p] : (decide p = true) ↔ p 
goal: decide p = true ↔ p

full_name: decide_eq_false_iff_not
code: @[simp] theorem decide_eq_false_iff_not (p : Prop) {_ : Decidable p} : (decide p = false) ↔ ¬p 
goal: ∀ {x : Decidable p}, decide p = false ↔ ¬p

full_name: decide_eq_decide
code: @[simp] theorem decide_eq_decide {p q : Prop} {_ : Decidable p} {_ : Decidable q} :
    decide p = decide q ↔ (p ↔ q) 
goal: ∀ {x : Decidable p} {x_1 : Decidable q}, decide p = decide q ↔ (p ↔ q)

full_name: Decidable.of_not_imp
code: theorem Decidable.of_not_imp [Decidable a] (h : ¬(a → b)) : a 
goal: a

full_name: Decidable.not_imp_symm
code: theorem Decidable.not_imp_symm [Decidable a] (h : ¬a → b) (hb : ¬b) : a 
goal: a

full_name: Decidable.not_imp_comm
code: theorem Decidable.not_imp_comm [Decidable a] [Decidable b] : (¬a → b) ↔ (¬b → a) 
goal: ¬a → b ↔ ¬b → a

full_name: Decidable.not_imp_self
code: @[simp] theorem Decidable.not_imp_self [Decidable a] : (¬a → a) ↔ a 
goal: ¬a → a ↔ a

full_name: Decidable.or_iff_not_imp_left
code: theorem Decidable.or_iff_not_imp_left [Decidable a] : a ∨ b ↔ (¬a → b) 
goal: a ∨ b ↔ ¬a → b

full_name: Decidable.or_iff_not_imp_right
code: theorem Decidable.or_iff_not_imp_right [Decidable b] : a ∨ b ↔ (¬b → a) 
goal: a ∨ b ↔ ¬b → a

full_name: Decidable.not_imp_not
code: theorem Decidable.not_imp_not [Decidable a] : (¬a → ¬b) ↔ (b → a) 
goal: ¬a → ¬b ↔ b → a

full_name: Decidable.not_or_of_imp
code: theorem Decidable.not_or_of_imp [Decidable a] (h : a → b) : ¬a ∨ b 
goal: ¬a ∨ b

full_name: Decidable.imp_iff_not_or
code: theorem Decidable.imp_iff_not_or [Decidable a] : (a → b) ↔ (¬a ∨ b) 
goal: a → b ↔ ¬a ∨ b

full_name: Decidable.imp_iff_or_not
code: theorem Decidable.imp_iff_or_not [Decidable b] : b → a ↔ a ∨ ¬b 
goal: b → a ↔ a ∨ ¬b

full_name: Decidable.imp_or
code: theorem Decidable.imp_or [h : Decidable a] : (a → b ∨ c) ↔ (a → b) ∨ (a → c) 
goal: a → b ∨ c ↔ (a → b) ∨ (a → c)

full_name: Decidable.imp_or'
code: theorem Decidable.imp_or' [Decidable b] : (a → b ∨ c) ↔ (a → b) ∨ (a → c) 
goal: a → b ∨ c ↔ (a → b) ∨ (a → c)

full_name: Decidable.not_imp_iff_and_not
code: theorem Decidable.not_imp_iff_and_not [Decidable a] : ¬(a → b) ↔ a ∧ ¬b 
goal: ¬(a → b) ↔ a ∧ ¬b

full_name: Decidable.peirce
code: theorem Decidable.peirce (a b : Prop) [Decidable a] : ((a → b) → a) → a 
goal: ((a → b) → a) → a

full_name: peirce'
code: theorem peirce' {a : Prop} (H : ∀ b : Prop, (a → b) → a) : a 
goal: a

full_name: Decidable.not_iff_not
code: theorem Decidable.not_iff_not [Decidable a] [Decidable b] : (¬a ↔ ¬b) ↔ (a ↔ b) 
goal: (¬a ↔ ¬b) ↔ (a ↔ b)

full_name: Decidable.not_iff_comm
code: theorem Decidable.not_iff_comm [Decidable a] [Decidable b] : (¬a ↔ b) ↔ (¬b ↔ a) 
goal: (¬a ↔ b) ↔ (¬b ↔ a)

full_name: Decidable.not_iff
code: theorem Decidable.not_iff [Decidable b] : ¬(a ↔ b) ↔ (¬a ↔ b) 
goal: ¬(a ↔ b) ↔ (¬a ↔ b)

full_name: Decidable.iff_not_comm
code: theorem Decidable.iff_not_comm [Decidable a] [Decidable b] : (a ↔ ¬b) ↔ (b ↔ ¬a) 
goal: (a ↔ ¬b) ↔ (b ↔ ¬a)

full_name: Decidable.iff_iff_and_or_not_and_not
code: theorem Decidable.iff_iff_and_or_not_and_not {a b : Prop} [Decidable b] :
    (a ↔ b) ↔ (a ∧ b) ∨ (¬a ∧ ¬b) 
goal: (a ↔ b) ↔ a ∧ b ∨ ¬a ∧ ¬b

full_name: Decidable.iff_iff_not_or_and_or_not
code: theorem Decidable.iff_iff_not_or_and_or_not [Decidable a] [Decidable b] :
    (a ↔ b) ↔ (¬a ∨ b) ∧ (a ∨ ¬b) 
goal: (a ↔ b) ↔ (¬a ∨ b) ∧ (a ∨ ¬b)

full_name: Decidable.not_and_not_right
code: theorem Decidable.not_and_not_right [Decidable b] : ¬(a ∧ ¬b) ↔ (a → b) 
goal: ¬(a ∧ ¬b) ↔ a → b

full_name: Decidable.not_and_iff_or_not_not
code: theorem Decidable.not_and_iff_or_not_not [Decidable a] : ¬(a ∧ b) ↔ ¬a ∨ ¬b 
goal: ¬(a ∧ b) ↔ ¬a ∨ ¬b

full_name: Decidable.not_and_iff_or_not_not'
code: theorem Decidable.not_and_iff_or_not_not' [Decidable b] : ¬(a ∧ b) ↔ ¬a ∨ ¬b 
goal: ¬(a ∧ b) ↔ ¬a ∨ ¬b

full_name: Decidable.or_iff_not_and_not
code: theorem Decidable.or_iff_not_and_not [Decidable a] [Decidable b] : a ∨ b ↔ ¬(¬a ∧ ¬b) 
goal: a ∨ b ↔ ¬(¬a ∧ ¬b)

full_name: Decidable.and_iff_not_or_not
code: theorem Decidable.and_iff_not_or_not [Decidable a] [Decidable b] : a ∧ b ↔ ¬(¬a ∨ ¬b) 
goal: a ∧ b ↔ ¬(¬a ∨ ¬b)

full_name: Decidable.imp_iff_right_iff
code: theorem Decidable.imp_iff_right_iff [Decidable a] : (a → b ↔ b) ↔ a ∨ b 
goal: (a → b ↔ b) ↔ a ∨ b

full_name: Decidable.imp_iff_left_iff
code: theorem Decidable.imp_iff_left_iff  [Decidable a] : (b ↔ a → b) ↔ a ∨ b 
goal: (b ↔ a → b) ↔ a ∨ b

full_name: Decidable.and_or_imp
code: theorem Decidable.and_or_imp [Decidable a] : a ∧ b ∨ (a → c) ↔ a → b ∨ c 
goal: a ∧ b ∨ (a → c) ↔ a → b ∨ c

full_name: Decidable.or_congr_left'
code: theorem Decidable.or_congr_left' [Decidable c] (h : ¬c → (a ↔ b)) : a ∨ c ↔ b ∨ c 
goal: a ∨ c ↔ b ∨ c

full_name: Decidable.or_congr_right'
code: theorem Decidable.or_congr_right' [Decidable a] (h : ¬a → (b ↔ c)) : a ∨ b ↔ a ∨ c 
goal: a ∨ b ↔ a ∨ c

full_name: decidable_of_iff
code: /-- Transfer decidability of `a` to decidability of `b`, if the propositions are equivalent.
**Important**: this function should be used instead of `rw` on `Decidable b`, because the
kernel will get stuck reducing the usage of `propext` otherwise,
and `decide` will not work. -/
@[inline] def decidable_of_iff (a : Prop) (h : a ↔ b) [Decidable a] : Decidable b 
goal: Decidable b

full_name: decidable_of_iff'
code: /-- Transfer decidability of `b` to decidability of `a`, if the propositions are equivalent.
This is the same as `decidable_of_iff` but the iff is flipped. -/
@[inline] def decidable_of_iff' (b : Prop) (h : a ↔ b) [Decidable b] : Decidable a 
goal: Decidable a

full_name: Decidable.predToBool
code: instance Decidable.predToBool (p : α → Prop) [DecidablePred p] :
    CoeDep (α → Prop) p (α → Bool) 
goal: CoeDep (α → Prop) p (α → Bool)

full_name: decidable_of_bool
code: /-- Prove that `a` is decidable by constructing a boolean `b` and a proof that `b ↔ a`.
(This is sometimes taken as an alternate definition of decidability.) -/
def decidable_of_bool : ∀ (b : Bool), (b ↔ a) → Decidable a
  
goal: (b = true ↔ a) → Decidable a

full_name: Decidable.not_forall
code: protected theorem Decidable.not_forall {p : α → Prop} [Decidable (∃ x, ¬p x)]
    [∀ x, Decidable (p x)] : (¬∀ x, p x) ↔ ∃ x, ¬p x 
goal: (¬∀ (x : α), p x) ↔ ∃ x, ¬p x

full_name: Decidable.not_forall_not
code: protected theorem Decidable.not_forall_not {p : α → Prop} [Decidable (∃ x, p x)] :
    (¬∀ x, ¬p x) ↔ ∃ x, p x 
goal: (¬∀ (x : α), ¬p x) ↔ ∃ x, p x

full_name: Decidable.not_exists_not
code: protected theorem Decidable.not_exists_not {p : α → Prop} [∀ x, Decidable (p x)] :
    (¬∃ x, ¬p x) ↔ ∀ x, p x 
goal: (¬∃ x, ¬p x) ↔ ∀ (x : α), p x

full_name: decide_implies
code: @[simp]
theorem decide_implies (u v : Prop)
    [duv : Decidable (u → v)] [du : Decidable u] {dv : u → Decidable v}
  : decide (u → v) = dite u (fun h => @decide v (dv h)) (fun _ => true) 
goal: decide (u → v) = if h : u then decide v else true

full_name: decide_ite
code: @[simp]
theorem decide_ite (u : Prop) [du : Decidable u] (p q : Prop)
      [dpq : Decidable (ite u p q)] [dp : Decidable p] [dq : Decidable q] :
    decide (ite u p q) = ite u (decide p) (decide q) 
goal: decide (if u then p else q) = if u then decide p else decide q

full_name: ite_true_decide_same
code: @[simp] theorem ite_true_decide_same (p : Prop) [h : Decidable p] (b : Bool) :
  (if p then decide p else b) = (decide p || b) 
goal: (if p then decide p else b) = (decide p || b)

full_name: ite_false_decide_same
code: @[simp] theorem ite_false_decide_same (p : Prop) [h : Decidable p] (b : Bool) :
  (if p then b else decide p) = (decide p && b) 
goal: (if p then b else decide p) = (decide p && b)