Theorem: TopCat.Presheaf.compatible_iff_leftRes_eq_rightRes
File: Mathlib/Topology/Sheaves/SheafCondition/UniqueGluing.lean

tactic: constructor <;> intro h
state_before: C : Type u
inst✝¹ : Category C
inst✝ : ConcreteCategory C
X : TopCat
F : Presheaf (Type v) X
ι : Type v
U : ι → Opens ↑X
sf : piOpens F U
⊢ IsCompatible F U ((piOpensIsoSectionsFamily F U).hom sf) ↔ leftRes F U sf = rightRes F U sf

tactic: refine Types.limit_ext' _ _ _ fun ⟨i, j⟩ => ?_
state_before: case mp
C : Type u
inst✝¹ : Category C
inst✝ : ConcreteCategory C
X : TopCat
F : Presheaf (Type v) X
ι : Type v
U : ι → Opens ↑X
sf : piOpens F U
h : IsCompatible F U ((piOpensIsoSectionsFamily F U).hom sf)
⊢ leftRes F U sf = rightRes F U sf

tactic: rw [leftRes, Types.Limit.lift_π_apply', Fan.mk_π_app, rightRes, Types.Limit.lift_π_apply',
  Fan.mk_π_app]
state_before: case mp
C : Type u
inst✝¹ : Category C
inst✝ : ConcreteCategory C
X : TopCat
F : Presheaf (Type v) X
ι : Type v
U : ι → Opens ↑X
sf : piOpens F U
h : IsCompatible F U ((piOpensIsoSectionsFamily F U).hom sf)
x✝ : Discrete (ι × ι)
i j : ι
⊢ limit.π (Discrete.functor fun p => F.obj (U p.fst ⊓ U p.snd).op) { as := (i, j) } (leftRes F U sf) =
    limit.π (Discrete.functor fun p => F.obj (U p.fst ⊓ U p.snd).op) { as := (i, j) } (rightRes F U sf)

tactic: exact h i j
state_before: case mp
C : Type u
inst✝¹ : Category C
inst✝ : ConcreteCategory C
X : TopCat
F : Presheaf (Type v) X
ι : Type v
U : ι → Opens ↑X
sf : piOpens F U
h : IsCompatible F U ((piOpensIsoSectionsFamily F U).hom sf)
x✝ : Discrete (ι × ι)
i j : ι
⊢ (Pi.π (fun i => F.obj (U i).op) { as := (i, j) }.as.fst ≫
        F.map (infLELeft (U { as := (i, j) }.as.fst) (U { as := (i, j) }.as.snd)).op)
      sf =
    (Pi.π (fun i => F.obj (U i).op) { as := (i, j) }.as.snd ≫
        F.map (infLERight (U { as := (i, j) }.as.fst) (U { as := (i, j) }.as.snd)).op)
      sf

tactic: intro i j
state_before: case mpr
C : Type u
inst✝¹ : Category C
inst✝ : ConcreteCategory C
X : TopCat
F : Presheaf (Type v) X
ι : Type v
U : ι → Opens ↑X
sf : piOpens F U
h : leftRes F U sf = rightRes F U sf
⊢ IsCompatible F U ((piOpensIsoSectionsFamily F U).hom sf)

tactic: convert congr_arg (Limits.Pi.π (fun p : ι × ι => F.obj (op (U p.1 ⊓ U p.2))) (i, j)) h
state_before: case mpr
C : Type u
inst✝¹ : Category C
inst✝ : ConcreteCategory C
X : TopCat
F : Presheaf (Type v) X
ι : Type v
U : ι → Opens ↑X
sf : piOpens F U
h : leftRes F U sf = rightRes F U sf
i j : ι
⊢ (forget (Type v)).map (F.map (infLELeft (U i) (U j)).op) ((piOpensIsoSectionsFamily F U).hom sf i) =
    (forget (Type v)).map (F.map (infLERight (U i) (U j)).op) ((piOpensIsoSectionsFamily F U).hom sf j)

tactic: rw [leftRes, Types.pi_lift_π_apply]
state_before: case h.e'_2.h
C : Type u
inst✝¹ : Category C
inst✝ : ConcreteCategory C
X : TopCat
F : Presheaf (Type v) X
ι : Type v
U : ι → Opens ↑X
sf : piOpens F U
h : leftRes F U sf = rightRes F U sf
i j : ι
e_1✝ : (forget (Type v)).obj (F.obj (U i ⊓ U j).op) = F.obj (U (i, j).fst ⊓ U (i, j).snd).op
⊢ (forget (Type v)).map (F.map (infLELeft (U i) (U j)).op) ((piOpensIsoSectionsFamily F U).hom sf i) =
    Pi.π (fun p => F.obj (U p.fst ⊓ U p.snd).op) (i, j) (leftRes F U sf)

tactic: rfl
state_before: case h.e'_2.h
C : Type u
inst✝¹ : Category C
inst✝ : ConcreteCategory C
X : TopCat
F : Presheaf (Type v) X
ι : Type v
U : ι → Opens ↑X
sf : piOpens F U
h : leftRes F U sf = rightRes F U sf
i j : ι
e_1✝ : (forget (Type v)).obj (F.obj (U i ⊓ U j).op) = F.obj (U (i, j).fst ⊓ U (i, j).snd).op
⊢ (forget (Type v)).map (F.map (infLELeft (U i) (U j)).op) ((piOpensIsoSectionsFamily F U).hom sf i) =
    (Pi.π (fun i => F.obj (U i).op) (i, j).fst ≫ F.map (infLELeft (U (i, j).fst) (U (i, j).snd)).op) sf

tactic: rw [rightRes, Types.pi_lift_π_apply]
state_before: case h.e'_3.h
C : Type u
inst✝¹ : Category C
inst✝ : ConcreteCategory C
X : TopCat
F : Presheaf (Type v) X
ι : Type v
U : ι → Opens ↑X
sf : piOpens F U
h : leftRes F U sf = rightRes F U sf
i j : ι
e_1✝ : (forget (Type v)).obj (F.obj (U i ⊓ U j).op) = F.obj (U (i, j).fst ⊓ U (i, j).snd).op
⊢ (forget (Type v)).map (F.map (infLERight (U i) (U j)).op) ((piOpensIsoSectionsFamily F U).hom sf j) =
    Pi.π (fun p => F.obj (U p.fst ⊓ U p.snd).op) (i, j) (rightRes F U sf)

tactic: rfl
state_before: case h.e'_3.h
C : Type u
inst✝¹ : Category C
inst✝ : ConcreteCategory C
X : TopCat
F : Presheaf (Type v) X
ι : Type v
U : ι → Opens ↑X
sf : piOpens F U
h : leftRes F U sf = rightRes F U sf
i j : ι
e_1✝ : (forget (Type v)).obj (F.obj (U i ⊓ U j).op) = F.obj (U (i, j).fst ⊓ U (i, j).snd).op
⊢ (forget (Type v)).map (F.map (infLERight (U i) (U j)).op) ((piOpensIsoSectionsFamily F U).hom sf j) =
    (Pi.π (fun i => F.obj (U i).op) (i, j).snd ≫ F.map (infLERight (U (i, j).fst) (U (i, j).snd)).op) sf