Section RepresentableExpressible.
Variable T : System.
Hypothesis closedT1: (ClosedSystem LNN T).
Fixpoint RepresentableHalf1 (n : nat) : naryFunc n -> Formula -> Prop :=
match n return (naryFunc n -> Formula -> Prop) with
| O =>
fun (f : naryFunc 0) (A : Formula) =>
SysPrf T (impH A (equal (var 0) (natToTerm f)))
| S m =>
fun (f : naryFunc (S m)) (A : Formula) =>
forall a : nat,
RepresentableHalf1 m (f a)
(substituteFormula LNN A (S m) (natToTerm a))
end.
Fixpoint RepresentableHalf2 (n : nat) : naryFunc n -> Formula -> Prop :=
match n return (naryFunc n -> Formula -> Prop) with
| O =>
fun (f : naryFunc 0) (A : Formula) =>
SysPrf T (impH (equal (var 0) (natToTerm f)) A)
| S m =>
fun (f : naryFunc (S m)) (A : Formula) =>
forall a : nat,
RepresentableHalf2 m (f a)
(substituteFormula LNN A (S m) (natToTerm a))
end.
Fixpoint RepresentableHelp (n : nat) : naryFunc n -> Formula -> Prop :=
match n return (naryFunc n -> Formula -> Prop) with
| O =>
fun (f : naryFunc 0) (A : Formula) =>
SysPrf T (iffH A (equal (var 0) (natToTerm f)))
| S m =>
fun (f : naryFunc (S m)) (A : Formula) =>
forall a : nat,
RepresentableHelp m (f a) (substituteFormula LNN A (S m) (natToTerm a))
end.
Definition Representable (n : nat) (f : naryFunc n)
(A : Formula) : Prop :=
(forall v : nat, In v (freeVarFormula LNN A) -> v <= n) /\
RepresentableHelp n f A.

Lemma Representable_ext :
forall (n : nat) (f g : naryFunc n) (A : Formula),
extEqual n f g -> RepresentableHelp n f A -> RepresentableHelp n g A.