F : PFunctor
X : Type ?u.18893
f✝ : X → Obj F X
r : M F → Sort u_1
x : Obj F (M F)
f : (x : Obj F (M F)) → r (M.mk x)
⊢ Eq.mpr
      (_ :
        r
            {
              approx := fun x_1 =>
                match x_1 with
                | 0 => CofixA.continue
                | succ n => CofixA.intro x.fst fun i => MIntl.approx (Sigma.snd x i) n,
              consistent := (_ : AllAgree (Approx.sMk x)) } =
          r
            {
              approx := fun x_1 =>
                match x_1 with
                | 0 => CofixA.continue
                | succ n =>
                  CofixA.intro x.fst fun i =>
                    MIntl.approx
                      (children
                        {
                          approx := fun x_2 =>
                            match x_2 with
                            | 0 => CofixA.continue
                            | succ n => CofixA.intro x.fst fun i => MIntl.approx (Sigma.snd x i) n,
                          consistent := (_ : AllAgree (Approx.sMk x)) }
                        i)
                      n,
              consistent :=
                (_ :
                  AllAgree
                    (Approx.sMk
                      { fst := x.fst,
                        snd := fun i =>
                          children
                            {
                              approx := fun x_1 =>
                                match x_1 with
                                | 0 => CofixA.continue
                                | succ n => CofixA.intro x.fst fun i => MIntl.approx (Sigma.snd x i) n,
                              consistent := (_ : AllAgree (Approx.sMk x)) }
                            i })) })
      (f
        { fst := x.fst,
          snd := fun i =>
            children
              {
                approx := fun x_1 =>
                  match x_1 with
                  | 0 => CofixA.continue
                  | succ n => CofixA.intro x.fst fun i => MIntl.approx (Sigma.snd x i) n,
                consistent := (_ : AllAgree (Approx.sMk x)) }
              i }) =
    f x
F : PFunctor
X : Type ?u.18893
f✝ : X → Obj F X
r : M F → Sort u_1
x : Obj F (M F)
f : (x : Obj F (M F)) → r (M.mk x)
⊢ M.cases f (M.mk x) = f x
dsimp only [M.mk, PFunctor.M.cases, dest, head, Approx.sMk, head']
case mk
F : PFunctor
X : Type ?u.18893
f✝ : X → Obj F X
r : M F → Sort u_1
f : (x : Obj F (M F)) → r (M.mk x)
fst✝ : F.A
snd✝ : B F fst✝ → M F
⊢ Eq.mpr
      (_ :
        r
            {
              approx := fun x =>
                match x with
                | 0 => CofixA.continue
                | succ n =>
                  CofixA.intro { fst := fst✝, snd := snd✝ }.fst fun i =>
                    MIntl.approx (Sigma.snd { fst := fst✝, snd := snd✝ } i) n,
              consistent := (_ : AllAgree (Approx.sMk { fst := fst✝, snd := snd✝ })) } =
          r
            {
              approx := fun x =>
                match x with
                | 0 => CofixA.continue
                | succ n =>
                  CofixA.intro { fst := fst✝, snd := snd✝ }.fst fun i =>
                    MIntl.approx
                      (children
                        {
                          approx := fun x =>
                            match x with
                            | 0 => CofixA.continue
                            | succ n =>
                              CofixA.intro { fst := fst✝, snd := snd✝ }.fst fun i =>
                                MIntl.approx (Sigma.snd { fst := fst✝, snd := snd✝ } i) n,
                          consistent := (_ : AllAgree (Approx.sMk { fst := fst✝, snd := snd✝ })) }
                        i)
                      n,
              consistent :=
                (_ :
                  AllAgree
                    (Approx.sMk
                      { fst := { fst := fst✝, snd := snd✝ }.fst,
                        snd := fun i =>
                          children
                            {
                              approx := fun x =>
                                match x with
                                | 0 => CofixA.continue
                                | succ n =>
                                  CofixA.intro { fst := fst✝, snd := snd✝ }.fst fun i =>
                                    MIntl.approx (Sigma.snd { fst := fst✝, snd := snd✝ } i) n,
                              consistent := (_ : AllAgree (Approx.sMk { fst := fst✝, snd := snd✝ })) }
                            i })) })
      (f
        { fst := { fst := fst✝, snd := snd✝ }.fst,
          snd := fun i =>
            children
              {
                approx := fun x =>
                  match x with
                  | 0 => CofixA.continue
                  | succ n =>
                    CofixA.intro { fst := fst✝, snd := snd✝ }.fst fun i =>
                      MIntl.approx (Sigma.snd { fst := fst✝, snd := snd✝ } i) n,
                consistent := (_ : AllAgree (Approx.sMk { fst := fst✝, snd := snd✝ })) }
              i }) =
    f { fst := fst✝, snd := snd✝ }
F : PFunctor
X : Type ?u.18893
f✝ : X → Obj F X
r : M F → Sort u_1
x : Obj F (M F)
f : (x : Obj F (M F)) → r (M.mk x)
⊢ Eq.mpr
      (_ :
        r
            {
              approx := fun x_1 =>
                match x_1 with
                | 0 => CofixA.continue
                | succ n => CofixA.intro x.fst fun i => MIntl.approx (Sigma.snd x i) n,
              consistent := (_ : AllAgree (Approx.sMk x)) } =
          r
            {
              approx := fun x_1 =>
                match x_1 with
                | 0 => CofixA.continue
                | succ n =>
                  CofixA.intro x.fst fun i =>
                    MIntl.approx
                      (children
                        {
                          approx := fun x_2 =>
                            match x_2 with
                            | 0 => CofixA.continue
                            | succ n => CofixA.intro x.fst fun i => MIntl.approx (Sigma.snd x i) n,
                          consistent := (_ : AllAgree (Approx.sMk x)) }
                        i)
                      n,
              consistent :=
                (_ :
                  AllAgree
                    (Approx.sMk
                      { fst := x.fst,
                        snd := fun i =>
                          children
                            {
                              approx := fun x_1 =>
                                match x_1 with
                                | 0 => CofixA.continue
                                | succ n => CofixA.intro x.fst fun i => MIntl.approx (Sigma.snd x i) n,
                              consistent := (_ : AllAgree (Approx.sMk x)) }
                            i })) })
      (f
        { fst := x.fst,
          snd := fun i =>
            children
              {
                approx := fun x_1 =>
                  match x_1 with
                  | 0 => CofixA.continue
                  | succ n => CofixA.intro x.fst fun i => MIntl.approx (Sigma.snd x i) n,
                consistent := (_ : AllAgree (Approx.sMk x)) }
              i }) =
    f x
cases x
case mk
F : PFunctor
X : Type ?u.18893
f✝ : X → Obj F X
r : M F → Sort u_1
f : (x : Obj F (M F)) → r (M.mk x)
fst✝ : F.A
snd✝ : B F fst✝ → M F
⊢ Eq.mpr
      (_ :
        r
            {
              approx := fun x =>
                match x with
                | 0 => CofixA.continue
                | succ n => CofixA.intro fst✝ fun i => MIntl.approx (snd✝ i) n,
              consistent := (_ : AllAgree (Approx.sMk { fst := fst✝, snd := snd✝ })) } =
          r
            {
              approx := fun x =>
                match x with
                | 0 => CofixA.continue
                | succ n =>
                  CofixA.intro fst✝ fun i =>
                    MIntl.approx
                      (children
                        {
                          approx := fun x =>
                            match x with
                            | 0 => CofixA.continue
                            | succ n => CofixA.intro fst✝ fun i => MIntl.approx (snd✝ i) n,
                          consistent := (_ : AllAgree (Approx.sMk { fst := fst✝, snd := snd✝ })) }
                        i)
                      n,
              consistent :=
                (_ :
                  AllAgree
                    (Approx.sMk
                      { fst := fst✝,
                        snd := fun i =>
                          children
                            {
                              approx := fun x =>
                                match x with
                                | 0 => CofixA.continue
                                | succ n => CofixA.intro fst✝ fun i => MIntl.approx (snd✝ i) n,
                              consistent := (_ : AllAgree (Approx.sMk { fst := fst✝, snd := snd✝ })) }
                            i })) })
      (f
        { fst := fst✝,
          snd := fun i =>
            children
              {
                approx := fun x =>
                  match x with
                  | 0 => CofixA.continue
                  | succ n => CofixA.intro fst✝ fun i => MIntl.approx (snd✝ i) n,
                consistent := (_ : AllAgree (Approx.sMk { fst := fst✝, snd := snd✝ })) }
              i }) =
    f { fst := fst✝, snd := snd✝ }
case mk
F : PFunctor
X : Type ?u.18893
f✝ : X → Obj F X
r : M F → Sort u_1
f : (x : Obj F (M F)) → r (M.mk x)
fst✝ : F.A
snd✝ : B F fst✝ → M F
⊢ Eq.mpr
      (_ :
        r
            {
              approx := fun x =>
                match x with
                | 0 => CofixA.continue
                | succ n =>
                  CofixA.intro { fst := fst✝, snd := snd✝ }.fst fun i =>
                    MIntl.approx (Sigma.snd { fst := fst✝, snd := snd✝ } i) n,
              consistent := (_ : AllAgree (Approx.sMk { fst := fst✝, snd := snd✝ })) } =
          r
            {
              approx := fun x =>
                match x with
                | 0 => CofixA.continue
                | succ n =>
                  CofixA.intro { fst := fst✝, snd := snd✝ }.fst fun i =>
                    MIntl.approx
                      (children
                        {
                          approx := fun x =>
                            match x with
                            | 0 => CofixA.continue
                            | succ n =>
                              CofixA.intro { fst := fst✝, snd := snd✝ }.fst fun i =>
                                MIntl.approx (Sigma.snd { fst := fst✝, snd := snd✝ } i) n,
                          consistent := (_ : AllAgree (Approx.sMk { fst := fst✝, snd := snd✝ })) }
                        i)
                      n,
              consistent :=
                (_ :
                  AllAgree
                    (Approx.sMk
                      { fst := { fst := fst✝, snd := snd✝ }.fst,
                        snd := fun i =>
                          children
                            {
                              approx := fun x =>
                                match x with
                                | 0 => CofixA.continue
                                | succ n =>
                                  CofixA.intro { fst := fst✝, snd := snd✝ }.fst fun i =>
                                    MIntl.approx (Sigma.snd { fst := fst✝, snd := snd✝ } i) n,
                              consistent := (_ : AllAgree (Approx.sMk { fst := fst✝, snd := snd✝ })) }
                            i })) })
      (f
        { fst := { fst := fst✝, snd := snd✝ }.fst,
          snd := fun i =>
            children
              {
                approx := fun x =>
                  match x with
                  | 0 => CofixA.continue
                  | succ n =>
                    CofixA.intro { fst := fst✝, snd := snd✝ }.fst fun i =>
                      MIntl.approx (Sigma.snd { fst := fst✝, snd := snd✝ } i) n,
                consistent := (_ : AllAgree (Approx.sMk { fst := fst✝, snd := snd✝ })) }
              i }) =
    f { fst := fst✝, snd := snd✝ }
dsimp only [Approx.sMk]
case mk
F : PFunctor
X : Type ?u.18893
f✝ : X → Obj F X
r : M F → Sort u_1
f : (x : Obj F (M F)) → r (M.mk x)
fst✝ : F.A
snd✝ : B F fst✝ → M F
⊢ f
      { fst := fst✝,
        snd := fun i =>
          children
            {
              approx := fun x =>
                match x with
                | 0 => CofixA.continue
                | succ n => CofixA.intro fst✝ fun i => MIntl.approx (snd✝ i) n,
              consistent := (_ : AllAgree (Approx.sMk { fst := fst✝, snd := snd✝ })) }
            i } =
    f { fst := fst✝, snd := snd✝ }
case mk
F : PFunctor
X : Type ?u.18893
f✝ : X → Obj F X
r : M F → Sort u_1
f : (x : Obj F (M F)) → r (M.mk x)
fst✝ : F.A
snd✝ : B F fst✝ → M F
⊢ Eq.mpr
      (_ :
        r
            {
              approx := fun x =>
                match x with
                | 0 => CofixA.continue
                | succ n => CofixA.intro fst✝ fun i => MIntl.approx (snd✝ i) n,
              consistent := (_ : AllAgree (Approx.sMk { fst := fst✝, snd := snd✝ })) } =
          r
            {
              approx := fun x =>
                match x with
                | 0 => CofixA.continue
                | succ n =>
                  CofixA.intro fst✝ fun i =>
                    MIntl.approx
                      (children
                        {
                          approx := fun x =>
                            match x with
                            | 0 => CofixA.continue
                            | succ n => CofixA.intro fst✝ fun i => MIntl.approx (snd✝ i) n,
                          consistent := (_ : AllAgree (Approx.sMk { fst := fst✝, snd := snd✝ })) }
                        i)
                      n,
              consistent :=
                (_ :
                  AllAgree
                    (Approx.sMk
                      { fst := fst✝,
                        snd := fun i =>
                          children
                            {
                              approx := fun x =>
                                match x with
                                | 0 => CofixA.continue
                                | succ n => CofixA.intro fst✝ fun i => MIntl.approx (snd✝ i) n,
                              consistent := (_ : AllAgree (Approx.sMk { fst := fst✝, snd := snd✝ })) }
                            i })) })
      (f
        { fst := fst✝,
          snd := fun i =>
            children
              {
                approx := fun x =>
                  match x with
                  | 0 => CofixA.continue
                  | succ n => CofixA.intro fst✝ fun i => MIntl.approx (snd✝ i) n,
                consistent := (_ : AllAgree (Approx.sMk { fst := fst✝, snd := snd✝ })) }
              i }) =
    f { fst := fst✝, snd := snd✝ }
simp only [Eq.mpr]
case mk.h
F : PFunctor
X : Type ?u.18893
f✝ : X → Obj F X
r : M F → Sort u_1
f : (x : Obj F (M F)) → r (M.mk x)
fst✝ : F.A
snd✝ : B F fst✝ → M F
⊢ f = f
case mk
F : PFunctor
X : Type ?u.18893
f✝ : X → Obj F X
r : M F → Sort u_1
f : (x : Obj F (M F)) → r (M.mk x)
fst✝ : F.A
snd✝ : B F fst✝ → M F
⊢ f
      { fst := fst✝,
        snd := fun i =>
          children
            {
              approx := fun x =>
                match x with
                | 0 => CofixA.continue
                | succ n => CofixA.intro fst✝ fun i => MIntl.approx (snd✝ i) n,
              consistent := (_ : AllAgree (Approx.sMk { fst := fst✝, snd := snd✝ })) }
            i } =
    f { fst := fst✝, snd := snd✝ }
apply congrFun
no goals
case mk.h
F : PFunctor
X : Type ?u.18893
f✝ : X → Obj F X
r : M F → Sort u_1
f : (x : Obj F (M F)) → r (M.mk x)
fst✝ : F.A
snd✝ : B F fst✝ → M F
⊢ f = f
rfl