Inductive LNTFunction : Set :=
| Plus : LNTFunction
| Times : LNTFunction
| Succ : LNTFunction
| Zero : LNTFunction.
Inductive LNNRelation : Set :=
LT : LNNRelation.
Definition LNTFunctionArity (x : LNTFunction) : nat :=
match x with
| Plus => 2
| Times => 2
| Succ => 1
| Zero => 0
end.
Definition LNTArity (x : Empty_set + LNTFunction) : nat :=
match x return nat with
| inl bot => Empty_set_rec (fun _ => nat) bot
| inr y => LNTFunctionArity y
end.
Definition LNNArity (x : LNNRelation + LNTFunction) : nat :=
match x return nat with
| inl y => match y with
| LT => 2
end
| inr y => LNTFunctionArity y
end.
Definition LNT : Language := language Empty_set LNTFunction LNTArity.
Definition LNN : Language := language LNNRelation LNTFunction LNNArity.
Definition codeLNTFunction (f : LNTFunction) : nat :=
match f with
| Plus => 0
| Times => 1
| Succ => 2
| Zero => 3
end.
Definition codeLNTRelation (R : Empty_set) : nat :=
match R return nat with
end.
Definition codeLNNRelation (R : LNNRelation) : nat := 0.

(* Specifications: *)
Lemma codeLNTFunctionInj :
forall f g : LNTFunction, codeLNTFunction f = codeLNTFunction g -> f = g.
Lemma codeLNTRelationInj :
forall R S : Empty_set, codeLNTRelation R = codeLNTRelation S -> R = S.
Lemma codeLNNRelationInj :
forall R S : LNNRelation, codeLNNRelation R = codeLNNRelation S -> R = S.