Goal:
  
  G : t
  HI : invariants G
  HG : acyclic_no_loop G
  y_0 : V.t
  x_0 : V.t
  Hxs : lsp G x_0 y_0 = None
  K : Z
  x : V.t
  y : V.t
  z : V.t
  e : EdgeOf G' x y
  q : PathOf G' y z
  IHq : weight q =
        match from_G'_path q with
        | inl q' => weight q'
        | inr (q1, q2) => weight q1 + K + weight q2
        end
  XX : (y_0, K, x_0) <> (x, e.π1, y)
  ============================
   (e.π1 + weight q =
    match
      sum_rect
        (fun _ : PathOf G y z + (PathOf G y y_0 × PathOf G x_0 z) =>
         (PathOf G x z + (PathOf G x y_0 × PathOf G x_0 z))%type)
        (fun IHq : PathOf G y z =>
         inl (pathOf_step G x y z (e.π1; EdgeSetFact.add_3 XX e.π2) IHq))
        (fun IHq : PathOf G y y_0 × PathOf G x_0 z =>
         inr
           (pathOf_step G x y y_0 (e.π1; EdgeSetFact.add_3 XX e.π2) IHq.1,
            IHq.2)) (from_G'_path q)
    with
    | inl q' => weight q'
    | inr (q1, q2) => weight q1 + K + weight q2
    end)


DEBUG:Going to execute:
destruct (from_G'_path q) as [q'| [q1 q2]]

Goals:
  
  G : t
  HI : invariants G
  HG : acyclic_no_loop G
  y_0 : V.t
  x_0 : V.t
  Hxs : lsp G x_0 y_0 = None
  K : Z
  x : V.t
  y : V.t
  z : V.t
  e : EdgeOf G' x y
  q : PathOf G' y z
  q' : PathOf G y z
  IHq : weight q = weight q'
  XX : (y_0, K, x_0) <> (x, e.π1, y)
  ============================
   (e.π1 + weight q =
    match
      sum_rect
        (fun _ : PathOf G y z + (PathOf G y y_0 × PathOf G x_0 z) =>
         (PathOf G x z + (PathOf G x y_0 × PathOf G x_0 z))%type)
        (fun IHq : PathOf G y z =>
         inl (pathOf_step G x y z (e.π1; EdgeSetFact.add_3 XX e.π2) IHq))
        (fun IHq : PathOf G y y_0 × PathOf G x_0 z =>
         inr
           (pathOf_step G x y y_0 (e.π1; EdgeSetFact.add_3 XX e.π2) IHq.1,
            IHq.2)) (inl q')
    with
    | inl q' => weight q'
    | inr (q1, q2) => weight q1 + K + weight q2
    end)

  
  G : t
  HI : invariants G
  HG : acyclic_no_loop G
  y_0 : V.t
  x_0 : V.t
  Hxs : lsp G x_0 y_0 = None
  K : Z
  x : V.t
  y : V.t
  z : V.t
  e : EdgeOf G' x y
  q : PathOf G' y z
  q1 : PathOf G y y_0
  q2 : PathOf G x_0 z
  IHq : weight q = weight q1 + K + weight q2
  XX : (y_0, K, x_0) <> (x, e.π1, y)
  ============================
   (e.π1 + weight q =
    match
      sum_rect
        (fun _ : PathOf G y z + (PathOf G y y_0 × PathOf G x_0 z) =>
         (PathOf G x z + (PathOf G x y_0 × PathOf G x_0 z))%type)
        (fun IHq : PathOf G y z =>
         inl (pathOf_step G x y z (e.π1; EdgeSetFact.add_3 XX e.π2) IHq))
        (fun IHq : PathOf G y y_0 × PathOf G x_0 z =>
         inr
           (pathOf_step G x y y_0 (e.π1; EdgeSetFact.add_3 XX e.π2) IHq.1,
            IHq.2)) (inr (q1, q2))
    with
    | inl q' => weight q'
    | inr (q1, q2) => weight q1 + K + weight q2
    end)


DEBUG:Going to execute:
simpl
DEBUG LTAC Evaluated term: (from_G'_path q)