Theorem: AlgebraicGeometry.PresheafedSpace.GlueData.snd_invApp_t_app'
File: Mathlib/Geometry/RingedSpace/PresheafedSpace/Gluing.lean

tactic: fconstructor
state_before: C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ ∃ (eq :
    (Opens.map (D.t k i).base).op.obj { unop := (opensFunctor pullback.snd).obj U } =
      {
        unop :=
          (opensFunctor pullback.fst).obj
            { unop := { carrier := ⇑(D.t' k i j).base ⁻¹' ↑{ unop := U }.unop, is_open' := ⋯ } }.unop }),
    invApp pullback.snd U ≫
        (D.t k i).c.app { unop := (opensFunctor pullback.snd).obj U } ≫ (D.V (k, i)).presheaf.map (eqToHom eq) =
      (D.t' k i j).c.app { unop := U } ≫
        invApp pullback.fst { unop := { carrier := ⇑(D.t' k i j).base ⁻¹' ↑{ unop := U }.unop, is_open' := ⋯ } }.unop
state_after: case w
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ (Opens.map (D.t k i).base).op.obj { unop := (opensFunctor pullback.snd).obj U } =
    {
      unop :=
        (opensFunctor pullback.fst).obj
          { unop := { carrier := ⇑(D.t' k i j).base ⁻¹' ↑{ unop := U }.unop, is_open' := ⋯ } }.unop }

case h
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ invApp pullback.snd U ≫
      (D.t k i).c.app { unop := (opensFunctor pullback.snd).obj U } ≫ (D.V (k, i)).presheaf.map (eqToHom ?w) =
    (D.t' k i j).c.app { unop := U } ≫
      invApp pullback.fst { unop := { carrier := ⇑(D.t' k i j).base ⁻¹' ↑{ unop := U }.unop, is_open' := ⋯ } }.unop

tactic: delta IsOpenImmersion.opensFunctor
state_before: case w
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ (Opens.map (D.t k i).base).op.obj { unop := (opensFunctor pullback.snd).obj U } =
    {
      unop :=
        (opensFunctor pullback.fst).obj
          { unop := { carrier := ⇑(D.t' k i j).base ⁻¹' ↑{ unop := U }.unop, is_open' := ⋯ } }.unop }
state_after: case w
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ (Opens.map (D.t k i).base).op.obj { unop := ⋯.functor.obj U } =
    { unop := ⋯.functor.obj { unop := { carrier := ⇑(D.t' k i j).base ⁻¹' ↑{ unop := U }.unop, is_open' := ⋯ } }.unop }

tactic: dsimp only [Functor.op, Opens.map, IsOpenMap.functor, unop_op, Opens.coe_mk]
state_before: case w
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ (Opens.map (D.t k i).base).op.obj { unop := ⋯.functor.obj U } =
    { unop := ⋯.functor.obj { unop := { carrier := ⇑(D.t' k i j).base ⁻¹' ↑{ unop := U }.unop, is_open' := ⋯ } }.unop }
state_after: case w
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ { unop := { carrier := ⇑(D.t k i).base ⁻¹' (⇑pullback.snd.base '' ↑U), is_open' := ⋯ } } =
    { unop := { carrier := ⇑pullback.fst.base '' (⇑(D.t' k i j).base ⁻¹' ↑U), is_open' := ⋯ } }

tactic: congr
state_before: case w
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ { unop := { carrier := ⇑(D.t k i).base ⁻¹' (⇑pullback.snd.base '' ↑U), is_open' := ⋯ } } =
    { unop := { carrier := ⇑pullback.fst.base '' (⇑(D.t' k i j).base ⁻¹' ↑U), is_open' := ⋯ } }
state_after: case w.e_unop.e_carrier
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ ⇑(D.t k i).base ⁻¹' (⇑pullback.snd.base '' ↑U) = ⇑pullback.fst.base '' (⇑(D.t' k i j).base ⁻¹' ↑U)

tactic: have := (𝖣.t_fac k i j).symm
state_before: case w.e_unop.e_carrier
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ ⇑(D.t k i).base ⁻¹' (⇑pullback.snd.base '' ↑U) = ⇑pullback.fst.base '' (⇑(D.t' k i j).base ⁻¹' ↑U)
state_after: case w.e_unop.e_carrier
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : pullback.fst ≫ D.t k i = D.t' k i j ≫ pullback.snd
⊢ ⇑(D.t k i).base ⁻¹' (⇑pullback.snd.base '' ↑U) = ⇑pullback.fst.base '' (⇑(D.t' k i j).base ⁻¹' ↑U)

tactic: rw [← IsIso.inv_comp_eq] at this
state_before: case w.e_unop.e_carrier
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : pullback.fst ≫ D.t k i = D.t' k i j ≫ pullback.snd
⊢ ⇑(D.t k i).base ⁻¹' (⇑pullback.snd.base '' ↑U) = ⇑pullback.fst.base '' (⇑(D.t' k i j).base ⁻¹' ↑U)
state_after: case w.e_unop.e_carrier
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : inv (D.t' k i j) ≫ pullback.fst ≫ D.t k i = pullback.snd
⊢ ⇑(D.t k i).base ⁻¹' (⇑pullback.snd.base '' ↑U) = ⇑pullback.fst.base '' (⇑(D.t' k i j).base ⁻¹' ↑U)

tactic: dsimp at this
state_before: case w.e_unop.e_carrier
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : (fun x => x.toFun) pullback.snd.base = (fun x => x.toFun) (inv (D.t' k i j) ≫ pullback.fst ≫ D.t k i).base
⊢ ⇑(D.t k i).base ⁻¹' (⇑pullback.snd.base '' ↑U) = ⇑pullback.fst.base '' (⇑(D.t' k i j).base ⁻¹' ↑U)
state_after: case w.e_unop.e_carrier
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : ⇑pullback.snd.base = ⇑((inv (D.t' k i j)).base ≫ pullback.fst.base ≫ (D.t k i).base)
⊢ ⇑(D.t k i).base ⁻¹' (⇑pullback.snd.base '' ↑U) = ⇑pullback.fst.base '' (⇑(D.t' k i j).base ⁻¹' ↑U)

tactic: erw [coe_comp, coe_comp] at this
state_before: case w.e_unop.e_carrier
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : ⇑pullback.snd.base = ⇑((inv (D.t' k i j)).base ≫ pullback.fst.base ≫ (D.t k i).base)
⊢ ⇑(D.t k i).base ⁻¹' (⇑pullback.snd.base '' ↑U) = ⇑pullback.fst.base '' (⇑(D.t' k i j).base ⁻¹' ↑U)
state_after: case w.e_unop.e_carrier
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : ⇑pullback.snd.base = (⇑(D.t k i).base ∘ ⇑pullback.fst.base) ∘ ⇑(inv (D.t' k i j)).base
⊢ ⇑(D.t k i).base ⁻¹' (⇑pullback.snd.base '' ↑U) = ⇑pullback.fst.base '' (⇑(D.t' k i j).base ⁻¹' ↑U)

tactic: erw [this, Set.image_comp, Set.image_comp, Set.preimage_image_eq]
state_before: case w.e_unop.e_carrier
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : ⇑pullback.snd.base = (⇑(D.t k i).base ∘ ⇑pullback.fst.base) ∘ ⇑(inv (D.t' k i j)).base
⊢ ⇑(D.t k i).base ⁻¹' (⇑pullback.snd.base '' ↑U) = ⇑pullback.fst.base '' (⇑(D.t' k i j).base ⁻¹' ↑U)
state_after: case w.e_unop.e_carrier
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : ⇑pullback.snd.base = (⇑(D.t k i).base ∘ ⇑pullback.fst.base) ∘ ⇑(inv (D.t' k i j)).base
⊢ ⇑pullback.fst.base '' (⇑(inv (D.t' k i j)).base '' ↑U) = ⇑pullback.fst.base '' (⇑(D.t' k i j).base ⁻¹' ↑U)

case w.e_unop.e_carrier.h
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : ⇑pullback.snd.base = (⇑(D.t k i).base ∘ ⇑pullback.fst.base) ∘ ⇑(inv (D.t' k i j)).base
⊢ Function.Injective ⇑(D.t k i).base

tactic: swap
state_before: case w.e_unop.e_carrier
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : ⇑pullback.snd.base = (⇑(D.t k i).base ∘ ⇑pullback.fst.base) ∘ ⇑(inv (D.t' k i j)).base
⊢ ⇑pullback.fst.base '' (⇑(inv (D.t' k i j)).base '' ↑U) = ⇑pullback.fst.base '' (⇑(D.t' k i j).base ⁻¹' ↑U)

case w.e_unop.e_carrier.h
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : ⇑pullback.snd.base = (⇑(D.t k i).base ∘ ⇑pullback.fst.base) ∘ ⇑(inv (D.t' k i j)).base
⊢ Function.Injective ⇑(D.t k i).base
state_after: case w.e_unop.e_carrier.h
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : ⇑pullback.snd.base = (⇑(D.t k i).base ∘ ⇑pullback.fst.base) ∘ ⇑(inv (D.t' k i j)).base
⊢ Function.Injective ⇑(D.t k i).base

case w.e_unop.e_carrier
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : ⇑pullback.snd.base = (⇑(D.t k i).base ∘ ⇑pullback.fst.base) ∘ ⇑(inv (D.t' k i j)).base
⊢ ⇑pullback.fst.base '' (⇑(inv (D.t' k i j)).base '' ↑U) = ⇑pullback.fst.base '' (⇑(D.t' k i j).base ⁻¹' ↑U)

tactic: refine congr_fun ?_ _
state_before: case w.e_unop.e_carrier
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : ⇑pullback.snd.base = (⇑(D.t k i).base ∘ ⇑pullback.fst.base) ∘ ⇑(inv (D.t' k i j)).base
⊢ ⇑(inv (D.t' k i j)).base '' ↑U = ⇑(D.t' k i j).base ⁻¹' ↑U
state_after: case w.e_unop.e_carrier
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : ⇑pullback.snd.base = (⇑(D.t k i).base ∘ ⇑pullback.fst.base) ∘ ⇑(inv (D.t' k i j)).base
⊢ Set.image ⇑(inv (D.t' k i j)).base = Set.preimage ⇑(D.t' k i j).base

tactic: refine Set.image_eq_preimage_of_inverse ?_ ?_
state_before: case w.e_unop.e_carrier
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : ⇑pullback.snd.base = (⇑(D.t k i).base ∘ ⇑pullback.fst.base) ∘ ⇑(inv (D.t' k i j)).base
⊢ Set.image ⇑(inv (D.t' k i j)).base = Set.preimage ⇑(D.t' k i j).base
state_after: case w.e_unop.e_carrier.refine_1
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : ⇑pullback.snd.base = (⇑(D.t k i).base ∘ ⇑pullback.fst.base) ∘ ⇑(inv (D.t' k i j)).base
⊢ Function.LeftInverse ⇑(D.t' k i j).base ⇑(inv (D.t' k i j)).base

case w.e_unop.e_carrier.refine_2
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : ⇑pullback.snd.base = (⇑(D.t k i).base ∘ ⇑pullback.fst.base) ∘ ⇑(inv (D.t' k i j)).base
⊢ Function.RightInverse ⇑(D.t' k i j).base ⇑(inv (D.t' k i j)).base

tactic: refine Function.HasLeftInverse.injective ⟨(D.t i k).base, fun x => ?_⟩
state_before: case w.e_unop.e_carrier.h
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : ⇑pullback.snd.base = (⇑(D.t k i).base ∘ ⇑pullback.fst.base) ∘ ⇑(inv (D.t' k i j)).base
⊢ Function.Injective ⇑(D.t k i).base
state_after: case w.e_unop.e_carrier.h
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : ⇑pullback.snd.base = (⇑(D.t k i).base ∘ ⇑pullback.fst.base) ∘ ⇑(inv (D.t' k i j)).base
x : ↑↑(D.V (k, i))
⊢ (D.t i k).base ((D.t k i).base x) = x

tactic: erw [← comp_apply, ← comp_base, D.t_inv, id_base, id_apply]
state_before: case w.e_unop.e_carrier.h
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : ⇑pullback.snd.base = (⇑(D.t k i).base ∘ ⇑pullback.fst.base) ∘ ⇑(inv (D.t' k i j)).base
x : ↑↑(D.V (k, i))
⊢ (D.t i k).base ((D.t k i).base x) = x
state_after: no goals

tactic: intro x
state_before: case w.e_unop.e_carrier.refine_1
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : ⇑pullback.snd.base = (⇑(D.t k i).base ∘ ⇑pullback.fst.base) ∘ ⇑(inv (D.t' k i j)).base
⊢ Function.LeftInverse ⇑(D.t' k i j).base ⇑(inv (D.t' k i j)).base
state_after: case w.e_unop.e_carrier.refine_1
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : ⇑pullback.snd.base = (⇑(D.t k i).base ∘ ⇑pullback.fst.base) ∘ ⇑(inv (D.t' k i j)).base
x : ↑↑(pullback (D.f i j) (D.f i k))
⊢ (D.t' k i j).base ((inv (D.t' k i j)).base x) = x

tactic: erw [← comp_apply, ← comp_base, IsIso.inv_hom_id, id_base, id_apply]
state_before: case w.e_unop.e_carrier.refine_1
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : ⇑pullback.snd.base = (⇑(D.t k i).base ∘ ⇑pullback.fst.base) ∘ ⇑(inv (D.t' k i j)).base
x : ↑↑(pullback (D.f i j) (D.f i k))
⊢ (D.t' k i j).base ((inv (D.t' k i j)).base x) = x
state_after: no goals

tactic: intro x
state_before: case w.e_unop.e_carrier.refine_2
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : ⇑pullback.snd.base = (⇑(D.t k i).base ∘ ⇑pullback.fst.base) ∘ ⇑(inv (D.t' k i j)).base
⊢ Function.RightInverse ⇑(D.t' k i j).base ⇑(inv (D.t' k i j)).base
state_after: case w.e_unop.e_carrier.refine_2
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : ⇑pullback.snd.base = (⇑(D.t k i).base ∘ ⇑pullback.fst.base) ∘ ⇑(inv (D.t' k i j)).base
x : (CategoryTheory.forget TopCat).obj ↑(pullback (D.f k i) (D.f k j))
⊢ (inv (D.t' k i j)).base ((D.t' k i j).base x) = x

tactic: erw [← comp_apply, ← comp_base, IsIso.hom_inv_id, id_base, id_apply]
state_before: case w.e_unop.e_carrier.refine_2
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
this : ⇑pullback.snd.base = (⇑(D.t k i).base ∘ ⇑pullback.fst.base) ∘ ⇑(inv (D.t' k i j)).base
x : (CategoryTheory.forget TopCat).obj ↑(pullback (D.f k i) (D.f k j))
⊢ (inv (D.t' k i j)).base ((D.t' k i j).base x) = x
state_after: no goals

tactic: rw [← IsIso.eq_inv_comp, IsOpenImmersion.inv_invApp, Category.assoc,
  (D.t' k i j).c.naturality_assoc]
state_before: case h
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ invApp pullback.snd U ≫
      (D.t k i).c.app { unop := (opensFunctor pullback.snd).obj U } ≫ (D.V (k, i)).presheaf.map (eqToHom ⋯) =
    (D.t' k i j).c.app { unop := U } ≫
      invApp pullback.fst { unop := { carrier := ⇑(D.t' k i j).base ⁻¹' ↑{ unop := U }.unop, is_open' := ⋯ } }.unop
state_after: case h
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ (D.t k i).c.app { unop := (opensFunctor pullback.snd).obj U } ≫ (D.V (k, i)).presheaf.map (eqToHom ⋯) =
    pullback.snd.c.app { unop := (opensFunctor pullback.snd).obj U } ≫
      (D.t' k i j).c.app ((Opens.map pullback.snd.base).op.obj { unop := (opensFunctor pullback.snd).obj U }) ≫
        ((D.t' k i j).base _* (pullback (D.f k i) (D.f k j)).presheaf).map (eqToHom ⋯) ≫
          invApp pullback.fst { unop := { carrier := ⇑(D.t' k i j).base ⁻¹' ↑{ unop := U }.unop, is_open' := ⋯ } }.unop

tactic: simp_rw [← Category.assoc]
state_before: case h
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ (D.t k i).c.app { unop := (opensFunctor pullback.snd).obj U } ≫ (D.V (k, i)).presheaf.map (eqToHom ⋯) =
    pullback.snd.c.app { unop := (opensFunctor pullback.snd).obj U } ≫
      (D.t' k i j).c.app ((Opens.map pullback.snd.base).op.obj { unop := (opensFunctor pullback.snd).obj U }) ≫
        ((D.t' k i j).base _* (pullback (D.f k i) (D.f k j)).presheaf).map (eqToHom ⋯) ≫
          invApp pullback.fst { unop := { carrier := ⇑(D.t' k i j).base ⁻¹' ↑{ unop := U }.unop, is_open' := ⋯ } }.unop
state_after: case h
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ (D.t k i).c.app { unop := (opensFunctor pullback.snd).obj U } ≫ (D.V (k, i)).presheaf.map (eqToHom ⋯) =
    ((pullback.snd.c.app { unop := (opensFunctor pullback.snd).obj U } ≫
          (D.t' k i j).c.app ((Opens.map pullback.snd.base).op.obj { unop := (opensFunctor pullback.snd).obj U })) ≫
        ((D.t' k i j).base _* (pullback (D.f k i) (D.f k j)).presheaf).map (eqToHom ⋯)) ≫
      invApp pullback.fst { carrier := ⇑(D.t' k i j).base ⁻¹' ↑U, is_open' := ⋯ }

tactic: erw [← comp_c_app]
state_before: case h
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ (D.t k i).c.app { unop := (opensFunctor pullback.snd).obj U } ≫ (D.V (k, i)).presheaf.map (eqToHom ⋯) =
    ((pullback.snd.c.app { unop := (opensFunctor pullback.snd).obj U } ≫
          (D.t' k i j).c.app ((Opens.map pullback.snd.base).op.obj { unop := (opensFunctor pullback.snd).obj U })) ≫
        ((D.t' k i j).base _* (pullback (D.f k i) (D.f k j)).presheaf).map (eqToHom ⋯)) ≫
      invApp pullback.fst { carrier := ⇑(D.t' k i j).base ⁻¹' ↑U, is_open' := ⋯ }
state_after: case h
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ (D.t k i).c.app { unop := (opensFunctor pullback.snd).obj U } ≫ (D.V (k, i)).presheaf.map (eqToHom ⋯) =
    ((D.t' k i j ≫ pullback.snd).c.app { unop := (opensFunctor pullback.snd).obj U } ≫
        ((D.t' k i j).base _* (pullback (D.f k i) (D.f k j)).presheaf).map (eqToHom ⋯)) ≫
      invApp pullback.fst { carrier := ⇑(D.t' k i j).base ⁻¹' ↑U, is_open' := ⋯ }

tactic: rw [congr_app (D.t_fac k i j), comp_c_app]
state_before: case h
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ (D.t k i).c.app { unop := (opensFunctor pullback.snd).obj U } ≫ (D.V (k, i)).presheaf.map (eqToHom ⋯) =
    ((D.t' k i j ≫ pullback.snd).c.app { unop := (opensFunctor pullback.snd).obj U } ≫
        ((D.t' k i j).base _* (pullback (D.f k i) (D.f k j)).presheaf).map (eqToHom ⋯)) ≫
      invApp pullback.fst { carrier := ⇑(D.t' k i j).base ⁻¹' ↑U, is_open' := ⋯ }
state_after: case h
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ (D.t k i).c.app { unop := (opensFunctor pullback.snd).obj U } ≫ (D.V (k, i)).presheaf.map (eqToHom ⋯) =
    ((((D.t k i).c.app { unop := (opensFunctor pullback.snd).obj U } ≫
            pullback.fst.c.app
              { unop := (Opens.map (D.t k i).base).obj { unop := (opensFunctor pullback.snd).obj U }.unop }) ≫
          (pullback (D.f k i) (D.f k j)).presheaf.map (eqToHom ⋯)) ≫
        ((D.t' k i j).base _* (pullback (D.f k i) (D.f k j)).presheaf).map (eqToHom ⋯)) ≫
      invApp pullback.fst { carrier := ⇑(D.t' k i j).base ⁻¹' ↑U, is_open' := ⋯ }

tactic: simp_rw [Category.assoc]
state_before: case h
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ (D.t k i).c.app { unop := (opensFunctor pullback.snd).obj U } ≫ (D.V (k, i)).presheaf.map (eqToHom ⋯) =
    ((((D.t k i).c.app { unop := (opensFunctor pullback.snd).obj U } ≫
            pullback.fst.c.app
              { unop := (Opens.map (D.t k i).base).obj { unop := (opensFunctor pullback.snd).obj U }.unop }) ≫
          (pullback (D.f k i) (D.f k j)).presheaf.map (eqToHom ⋯)) ≫
        ((D.t' k i j).base _* (pullback (D.f k i) (D.f k j)).presheaf).map (eqToHom ⋯)) ≫
      invApp pullback.fst { carrier := ⇑(D.t' k i j).base ⁻¹' ↑U, is_open' := ⋯ }
state_after: case h
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ (D.t k i).c.app { unop := (opensFunctor pullback.snd).obj U } ≫ (D.V (k, i)).presheaf.map (eqToHom ⋯) =
    (D.t k i).c.app { unop := (opensFunctor pullback.snd).obj U } ≫
      pullback.fst.c.app { unop := (Opens.map (D.t k i).base).obj ((opensFunctor pullback.snd).obj U) } ≫
        (pullback (D.f k i) (D.f k j)).presheaf.map (eqToHom ⋯) ≫
          ((D.t' k i j).base _* (pullback (D.f k i) (D.f k j)).presheaf).map (eqToHom ⋯) ≫
            invApp pullback.fst { carrier := ⇑(D.t' k i j).base ⁻¹' ↑U, is_open' := ⋯ }

tactic: erw [IsOpenImmersion.inv_naturality, IsOpenImmersion.inv_naturality_assoc,
  IsOpenImmersion.app_inv_app'_assoc]
state_before: case h
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ (D.t k i).c.app { unop := (opensFunctor pullback.snd).obj U } ≫ (D.V (k, i)).presheaf.map (eqToHom ⋯) =
    (D.t k i).c.app { unop := (opensFunctor pullback.snd).obj U } ≫
      pullback.fst.c.app { unop := (Opens.map (D.t k i).base).obj ((opensFunctor pullback.snd).obj U) } ≫
        (pullback (D.f k i) (D.f k j)).presheaf.map (eqToHom ⋯) ≫
          ((D.t' k i j).base _* (pullback (D.f k i) (D.f k j)).presheaf).map (eqToHom ⋯) ≫
            invApp pullback.fst { carrier := ⇑(D.t' k i j).base ⁻¹' ↑U, is_open' := ⋯ }
state_after: case h
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ (D.t k i).c.app { unop := (opensFunctor pullback.snd).obj U } ≫ (D.V (k, i)).presheaf.map (eqToHom ⋯) =
    (D.t k i).c.app { unop := (opensFunctor pullback.snd).obj U } ≫
      (D.V (k, i)).presheaf.map (eqToHom ⋯).op ≫
        (D.V (k, i)).presheaf.map ((opensFunctor pullback.fst).op.map (eqToHom ⋯)) ≫
          (D.V (k, i)).presheaf.map
            ((opensFunctor pullback.fst).op.map ((Opens.map (D.t' k i j).base).op.map (eqToHom ⋯)))

case h.hU
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ ↑((Opens.map (D.t k i).base).obj ((opensFunctor pullback.snd).obj U)) ⊆ Set.range ⇑pullback.fst.base

tactic: rintro x ⟨y, -, eq⟩
state_before: case h.hU
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ ↑((Opens.map (D.t k i).base).obj ((opensFunctor pullback.snd).obj U)) ⊆ Set.range ⇑pullback.fst.base
state_after: case h.hU.intro.intro
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
x : ↑↑(D.V (k, i))
y : ↑↑(pullback (D.f i j) (D.f i k))
eq : pullback.snd.base y = (D.t k i).base x
⊢ x ∈ Set.range ⇑pullback.fst.base

tactic: replace eq := ConcreteCategory.congr_arg (𝖣.t i k).base eq
state_before: case h.hU.intro.intro
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
x : ↑↑(D.V (k, i))
y : ↑↑(pullback (D.f i j) (D.f i k))
eq : pullback.snd.base y = (D.t k i).base x
⊢ x ∈ Set.range ⇑pullback.fst.base
state_after: case h.hU.intro.intro
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
x : ↑↑(D.V (k, i))
y : ↑↑(pullback (D.f i j) (D.f i k))
eq : (D.t i k).base (pullback.snd.base y) = (D.t i k).base ((D.t k i).base x)
⊢ x ∈ Set.range ⇑pullback.fst.base

tactic: change ((π₂ i, j, k) ≫ D.t i k).base y = (D.t k i ≫ D.t i k).base x at eq
state_before: case h.hU.intro.intro
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
x : ↑↑(D.V (k, i))
y : ↑↑(pullback (D.f i j) (D.f i k))
eq : (D.t i k).base (pullback.snd.base y) = (D.t i k).base ((D.t k i).base x)
⊢ x ∈ Set.range ⇑pullback.fst.base
state_after: case h.hU.intro.intro
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
x : ↑↑(D.V (k, i))
y : ↑↑(pullback (D.f i j) (D.f i k))
eq : (pullback.snd ≫ D.t i k).base y = (D.t k i ≫ D.t i k).base x
⊢ x ∈ Set.range ⇑pullback.fst.base

tactic: rw [𝖣.t_inv, id_base, TopCat.id_app] at eq
state_before: case h.hU.intro.intro
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
x : ↑↑(D.V (k, i))
y : ↑↑(pullback (D.f i j) (D.f i k))
eq : (pullback.snd ≫ D.t i k).base y = (D.t k i ≫ D.t i k).base x
⊢ x ∈ Set.range ⇑pullback.fst.base
state_after: case h.hU.intro.intro
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
x : ↑↑(D.V (k, i))
y : ↑↑(pullback (D.f i j) (D.f i k))
eq : (pullback.snd ≫ D.t i k).base y = x
⊢ x ∈ Set.range ⇑pullback.fst.base

tactic: subst eq
state_before: case h.hU.intro.intro
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
x : ↑↑(D.V (k, i))
y : ↑↑(pullback (D.f i j) (D.f i k))
eq : (pullback.snd ≫ D.t i k).base y = x
⊢ x ∈ Set.range ⇑pullback.fst.base
state_after: case h.hU.intro.intro
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
y : ↑↑(pullback (D.f i j) (D.f i k))
⊢ (pullback.snd ≫ D.t i k).base y ∈ Set.range ⇑pullback.fst.base

tactic: use (inv (D.t' k i j)).base y
state_before: case h.hU.intro.intro
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
y : ↑↑(pullback (D.f i j) (D.f i k))
⊢ (pullback.snd ≫ D.t i k).base y ∈ Set.range ⇑pullback.fst.base
state_after: case h
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
y : ↑↑(pullback (D.f i j) (D.f i k))
⊢ pullback.fst.base ((inv (D.t' k i j)).base y) = (pullback.snd ≫ D.t i k).base y

tactic: change (inv (D.t' k i j) ≫ π₁ k, i, j).base y = _
state_before: case h
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
y : ↑↑(pullback (D.f i j) (D.f i k))
⊢ pullback.fst.base ((inv (D.t' k i j)).base y) = (pullback.snd ≫ D.t i k).base y
state_after: case h
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
y : ↑↑(pullback (D.f i j) (D.f i k))
⊢ (inv (D.t' k i j) ≫ pullback.fst).base y = (pullback.snd ≫ D.t i k).base y

tactic: congr 2
state_before: case h
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
y : ↑↑(pullback (D.f i j) (D.f i k))
⊢ (inv (D.t' k i j) ≫ pullback.fst).base y = (pullback.snd ≫ D.t i k).base y
state_after: case h.e_a.e_self
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
y : ↑↑(pullback (D.f i j) (D.f i k))
⊢ inv (D.t' k i j) ≫ pullback.fst = pullback.snd ≫ D.t i k

tactic: rw [IsIso.inv_comp_eq, 𝖣.t_fac_assoc, 𝖣.t_inv, Category.comp_id]
state_before: case h.e_a.e_self
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
y : ↑↑(pullback (D.f i j) (D.f i k))
⊢ inv (D.t' k i j) ≫ pullback.fst = pullback.snd ≫ D.t i k
state_after: no goals

tactic: simp_rw [← (𝖣.V (k, i)).presheaf.map_comp]
state_before: case h
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ (D.t k i).c.app { unop := (opensFunctor pullback.snd).obj U } ≫ (D.V (k, i)).presheaf.map (eqToHom ⋯) =
    (D.t k i).c.app { unop := (opensFunctor pullback.snd).obj U } ≫
      (D.V (k, i)).presheaf.map (eqToHom ⋯).op ≫
        (D.V (k, i)).presheaf.map ((opensFunctor pullback.fst).op.map (eqToHom ⋯)) ≫
          (D.V (k, i)).presheaf.map
            ((opensFunctor pullback.fst).op.map ((Opens.map (D.t' k i j).base).op.map (eqToHom ⋯)))
state_after: case h
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ (D.t k i).c.app { unop := (opensFunctor pullback.snd).obj U } ≫ (D.V (k, i)).presheaf.map (eqToHom ⋯) =
    (D.t k i).c.app { unop := (opensFunctor pullback.snd).obj U } ≫
      (D.V (k, i)).presheaf.map
        ((eqToHom ⋯).op ≫
          (opensFunctor pullback.fst).op.map (eqToHom ⋯) ≫
            (opensFunctor pullback.fst).op.map ((Opens.map (D.t' k i j).base).op.map (eqToHom ⋯)))

tactic: rfl
state_before: case h
C : Type u
inst✝ : Category.{v, u} C
D : GlueData C
i j k : D.J
U : Opens ↑↑(pullback (D.f i j) (D.f i k))
⊢ (D.t k i).c.app { unop := (opensFunctor pullback.snd).obj U } ≫ (D.V (k, i)).presheaf.map (eqToHom ⋯) =
    (D.t k i).c.app { unop := (opensFunctor pullback.snd).obj U } ≫
      (D.V (k, i)).presheaf.map
        ((eqToHom ⋯).op ≫
          (opensFunctor pullback.fst).op.map (eqToHom ⋯) ≫
            (opensFunctor pullback.fst).op.map ((Opens.map (D.t' k i j).base).op.map (eqToHom ⋯)))
state_after: no goals