Built with
doc-gen4, running Lean4.
Bubbles (
) indicate interactive fragments: hover for details, tap to reveal contents.
Use
Ctrl+↑Ctrl+↓to navigate,
Ctrl+🖱️to focus.
On Mac, use
Cmdinstead of
Ctrl.
/-
Copyright (c) 2021 Yury Kudryashov. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Yury Kudryashov
! This file was ported from Lean 3 source module data.ulift
! leanprover-community/mathlib commit 41cf0cc2f528dd40a8f2db167ea4fb37b8fde7f3
! Please do not edit these lines, except to modify the commit id
! if you have ported upstream changes.
-/
import Mathlib.Logic.Equiv.Basic
/-!
# Extra lemmas about `ULift` and `PLift`
In this file we provide `Subsingleton`, `Unique`, `DecidableEq`, and `isEmpty` instances for
`ULift α` and `PLift α`. We also prove `ULift.forall`, `ULift.exists`, `PLift.forall`, and
`PLift.exists`.
-/
universe u v
open Function
namespace PLift
variable {α : Sort u} {β : Sort v}
instance [Subsingleton α] : Subsingleton (PLift α) :=
Equiv.plift.subsingleton
instance [Nonempty α] : Nonempty (PLift α) :=
Equiv.plift.nonempty
instance [Unique α] : Unique (PLift α) :=
Equiv.plift.unique
instance [DecidableEq: Sort ?u.212 → Sort (max1?u.212)
DecidableEq α] : DecidableEq: Sort ?u.221 → Sort (max1?u.221)
DecidableEq (PLift α) :=
Equiv.plift.decidableEq
instance [IsEmpty α] : IsEmpty (PLift α) :=
Equiv.plift.isEmpty
theorem up_injective : Injective: {α : Sort ?u.477} → {β : Sort ?u.476} → (α → β) → Prop
Injective (@up α) :=
Equiv.plift.symm: {α : Sort ?u.488} → {β : Sort ?u.487} → α ≃ β → β ≃ α
symm.injective
#align plift.up_injective PLift.up_injective
theorem up_surjective : Surjective: {α : Sort ?u.516} → {β : Sort ?u.515} → (α → β) → Prop
Surjective (@up α) :=
Equiv.plift.symm: {α : Sort ?u.528} → {β : Sort ?u.527} → α ≃ β → β ≃ α
symm.surjective
#align plift.up_surjective PLift.up_surjective
theorem up_bijective : Bijective: {α : Sort ?u.555} → {β : Sort ?u.554} → (α → β) → Prop
Bijective (@up α) :=
Equiv.plift.symm: {α : Sort ?u.566} → {β : Sort ?u.565} → α ≃ β → β ≃ α
symm.bijective
#align plift.up_bijective PLift.up_bijective
@[simp]
theorem up_inj: ∀ {α : Sort u} {x y : α}, { down := x } = { down := y } ↔ x = y
up_inj {x y : α} : up x = up y ↔ x = y :=
up_injective.eq_iff: ∀ {α : Sort ?u.608} {β : Sort ?u.609} {f : α → β}, Injective f → ∀ {a b : α}, f a = f b ↔ a = b
eq_iff
#align plift.up_inj PLift.up_inj: ∀ {α : Sort u} {x y : α}, { down := x } = { down := y } ↔ x = y
PLift.up_inj
theorem down_surjective : Surjective: {α : Sort ?u.664} → {β : Sort ?u.663} → (α → β) → Prop
Surjective (@down α) :=
Equiv.plift.surjective
#align plift.down_surjective PLift.down_surjective
theorem down_bijective : Bijective: {α : Sort ?u.700} → {β : Sort ?u.699} → (α → β) → Prop
Bijective (@down α) :=
Equiv.plift.bijective
#align plift.down_bijective PLift.down_bijective
@[simp]
theorem «forall»: ∀ {α : Sort u} {p : PLift α → Prop}, (∀ (x : PLift α), p x) ↔ ∀ (x : α), p { down := x }
«forall» {p : PLift α → Prop} : (∀ x, p x) ↔ ∀ x : α, p (PLift.up x) :=
up_surjective.forall: ∀ {α : Sort ?u.753} {β : Sort ?u.754} {f : α → β},
Surjective f → ∀ {p : β → Prop}, (∀ (y : β), p y) ↔ ∀ (x : α), p (f x)
forall
#align plift.forall PLift.forall: ∀ {α : Sort u} {p : PLift α → Prop}, (∀ (x : PLift α), p x) ↔ ∀ (x : α), p { down := x }
PLift.forall
@[simp]
theorem «exists»: ∀ {α : Sort u} {p : PLift α → Prop}, (∃ x, p x) ↔ ∃ x, p { down := x }
«exists» {p : PLift α → Prop} : (∃ x, p x) ↔ ∃ x : α, p (PLift.up x) :=
up_surjective.exists: ∀ {α : Sort ?u.822} {β : Sort ?u.823} {f : α → β}, Surjective f → ∀ {p : β → Prop}, (∃ y, p y) ↔ ∃ x, p (f x)
exists
#align plift.exists PLift.exists: ∀ {α : Sort u} {p : PLift α → Prop}, (∃ x, p x) ↔ ∃ x, p { down := x }
PLift.exists
end PLift
namespace ULift
variable {α : Type u} {β : Type v}
instance [Subsingleton α] : Subsingleton (ULift: Type ?u.881 → Type (max?u.881?u.882)
ULift α) :=
Equiv.ulift.subsingleton
instance [Nonempty α] : Nonempty (ULift: Type ?u.951 → Type (max?u.951?u.952)
ULift α) :=
Equiv.ulift.nonempty
instance [Unique: Sort ?u.1018 → Sort (max1?u.1018)
Unique α] : Unique: Sort ?u.1021 → Sort (max1?u.1021)
Unique (ULift: Type ?u.1022 → Type (max?u.1022?u.1023)
ULift α) :=
Equiv.ulift.unique
instance [DecidableEq: Sort ?u.1091 → Sort (max1?u.1091)
DecidableEq α] : DecidableEq: Sort ?u.1100 → Sort (max1?u.1100)
DecidableEq (ULift: Type ?u.1101 → Type (max?u.1101?u.1102)
ULift α) :=
Equiv.ulift.decidableEq
instance [IsEmpty α] : IsEmpty (ULift: Type ?u.1298 → Type (max?u.1298?u.1299)
ULift α) :=
Equiv.ulift.isEmpty
theorem up_injective : Injective: {α : Sort ?u.1363} → {β : Sort ?u.1362} → (α → β) → Prop
Injective (@up α) :=
Equiv.ulift.symm: {α : Sort ?u.1376} → {β : Sort ?u.1375} → α ≃ β → β ≃ α
symm.injective
#align ulift.up_injective ULift.up_injective
theorem up_surjective : Surjective: {α : Sort ?u.1406} → {β : Sort ?u.1405} → (α → β) → Prop
Surjective (@up α) :=
Equiv.ulift.symm: {α : Sort ?u.1420} → {β : Sort ?u.1419} → α ≃ β → β ≃ α
symm.surjective
#align ulift.up_surjective ULift.up_surjective
theorem up_bijective : Bijective: {α : Sort ?u.1449} → {β : Sort ?u.1448} → (α → β) → Prop
Bijective (@up α) :=
Equiv.ulift.symm: {α : Sort ?u.1462} → {β : Sort ?u.1461} → α ≃ β → β ≃ α
symm.bijective
#align ulift.up_bijective ULift.up_bijective
@[simp]
theorem up_inj: ∀ {α : Type u} {x y : α}, { down := x } = { down := y } ↔ x = y
up_inj {x y : α} : up x = up y ↔ x = y :=
up_injective.eq_iff: ∀ {α : Sort ?u.1529} {β : Sort ?u.1530} {f : α → β}, Injective f → ∀ {a b : α}, f a = f b ↔ a = b
eq_iff
#align ulift.up_inj ULift.up_inj: ∀ {α : Type u} {x y : α}, { down := x } = { down := y } ↔ x = y
ULift.up_inj
theorem down_surjective : Surjective: {α : Sort ?u.1586} → {β : Sort ?u.1585} → (α → β) → Prop
Surjective (@down α) :=
Equiv.ulift.surjective
#align ulift.down_surjective ULift.down_surjective
theorem down_bijective : Bijective: {α : Sort ?u.1625} → {β : Sort ?u.1624} → (α → β) → Prop
Bijective (@down α) :=
Equiv.ulift.bijective
#align ulift.down_bijective ULift.down_bijective
@[simp]
theorem «forall»: ∀ {α : Type u} {p : ULift α → Prop}, (∀ (x : ULift α), p x) ↔ ∀ (x : α), p { down := x }
«forall» {p : ULift: Type ?u.1661 → Type (max?u.1661?u.1662)
ULift α → Prop} : (∀ x, p x) ↔ ∀ x : α, p (ULift.up x) :=
up_surjective.forall: ∀ {α : Sort ?u.1685} {β : Sort ?u.1686} {f : α → β},
Surjective f → ∀ {p : β → Prop}, (∀ (y : β), p y) ↔ ∀ (x : α), p (f x)
forall
#align ulift.forall ULift.forall: ∀ {α : Type u} {p : ULift α → Prop}, (∀ (x : ULift α), p x) ↔ ∀ (x : α), p { down := x }
ULift.forall
@[simp]
theorem «exists»: ∀ {α : Type u} {p : ULift α → Prop}, (∃ x, p x) ↔ ∃ x, p { down := x }
«exists» {p : ULift: Type ?u.1731 → Type (max?u.1731?u.1732)
ULift α → Prop} : (∃ x, p x) ↔ ∃ x : α, p (ULift.up x) :=
up_surjective.exists: ∀ {α : Sort ?u.1759} {β : Sort ?u.1760} {f : α → β}, Surjective f → ∀ {p : β → Prop}, (∃ y, p y) ↔ ∃ x, p (f x)
exists
#align ulift.exists ULift.exists: ∀ {α : Type u} {p : ULift α → Prop}, (∃ x, p x) ↔ ∃ x, p { down := x }
ULift.exists
@[ext]
theorem ext: ∀ (x y : ULift α), x.down = y.down → x = y
ext (x y : ULift: Type ?u.1815 → Type (max?u.1815?u.1816)
ULift α) (h : x.down = y.down) : x = y :=
congrArg: ∀ {α : Sort ?u.1859} {β : Sort ?u.1858} {a₁ a₂ : α} (f : α → β), a₁ = a₂ → f a₁ = f a₂
congrArg up h
#align ulift.ext ULift.ext: ∀ {α : Type u} (x y : ULift α), x.down = y.down → x = y
ULift.ext
theorem ext_iff: ∀ {α : Type u_1} (x y : ULift α), x = y ↔ x.down = y.down
ext_iff {α : Type _} (x y : ULift: Type ?u.1894 → Type (max?u.1894?u.1895)
ULift α) : x = y ↔ x.down = y.down :=
⟨congrArg: ∀ {α : Sort ?u.1947} {β : Sort ?u.1946} {a₁ a₂ : α} (f : α → β), a₁ = a₂ → f a₁ = f a₂
congrArg _, ULift.ext: ∀ {α : Type ?u.1963} (x y : ULift α), x.down = y.down → x = y
ULift.ext _ _⟩
#align ulift.ext_iff ULift.ext_iff: ∀ {α : Type u_1} (x y : ULift α), x = y ↔ x.down = y.down
ULift.ext_iff
end ULift