DEFINITION arity_subst0()
TYPE =
       g:G
         .c:C
           .t1:T
             .a:A
               .arity g c t1 a
                 d:C
                      .u:T
                        .i:nat
                          .getl i c (CHead d (Bind Abbr) u)
                            t2:T.(subst0 i u t1 t2)(arity g c t2 a)
BODY =
        assume gG
        assume cC
        assume t1T
        assume aA
        suppose Harity g c t1 a
        assume dC
        assume uT
        assume inat
        suppose H0getl i c (CHead d (Bind Abbr) u)
        assume t2T
        suppose H1subst0 i u t1 t2
          by (fsubst0_snd . . . . . H1)
          we proved fsubst0 i u c t1 c t2
          by (arity_fsubst0 . . . . H . . . H0 . . previous)
          we proved arity g c t2 a
       we proved 
          g:G
            .c:C
              .t1:T
                .a:A
                  .arity g c t1 a
                    d:C
                         .u:T
                           .i:nat
                             .getl i c (CHead d (Bind Abbr) u)
                               t2:T.(subst0 i u t1 t2)(arity g c t2 a)