Definition codeInductionSchema (f : nat) : bool :=
  let n :=
    cPairPi1
      (cPairPi2 (cPairPi2 (cPairPi2 (cPairPi2 (cPairPi2 (codeOpen f)))))) in
  let g :=
    cPairPi2
      (cPairPi2 (cPairPi2 (cPairPi2 (cPairPi2 (cPairPi2 (codeOpen f)))))) in
  beq_nat
    (codeClose
       (codeImp (codeSubFormula g n (codeTerm Zero))
          (codeImp
             (codeForall n
                (codeImp g (codeSubFormula g n (codeTerm (Succ (var n))))))
             (codeForall n g)))) f.

(* Specifications: *)
Lemma codeInductionSchemaCorrect1 : forall f : Formula, InductionSchema f -> codeInductionSchema (codeFormula f) = true.
Lemma codeInductionSchemaCorrect2 : forall f : Formula, codeInductionSchema (codeFormula f) = true -> InductionSchema f.
Lemma codeInductionSchemaCorrect3 : forall f : Formula, ~ InductionSchema f -> codeInductionSchema (codeFormula f) = false.
Lemma codeInductionSchemaIsPR : isPRrel 1 codeInductionSchema.