End CFGs.
Definition CFP' (G : cfg) := exists x, L G x /\ x = List.rev x.
Definition CFI' '(G1, G2) :=
exists x, L G1 x /\ L G2 x.
Section Post_CFG.
Variable R : SRS.
Variable a : symbol.
Definition Sigma := sym R ++ [a].
Definition S : symbol := fresh Sigma.
Definition G := (S, (S,[S]) :: map (fun '(u / v) => (S, u ++ [S] ++ v)) R ++ map (fun '(u / v) => (S, u ++ [a] ++ v)) R).

(* Specifications: *)
Lemma terminal_iff_G y :
terminal G y <-> ~ S el y.
Lemma rewt_count x :
rewt G [S] x -> count x S <= 1.
Lemma Post_CFG_1' A :
A <<= R -> A = [] \/ rewt G [S] (sigma a A).
Lemma Post_CFG_2 x :
rewt G [S] x ->
exists A m, A <<= R /\ sigma m A = x /\ (m = S \/ m = a /\ A <> []).
Lemma reduction_full x :
(exists A, A <<= R /\ A <> [] /\ sigma a A = x) <->  L G x.