(** Theory of pure CRs (CRs that have only one binary operator *)
Inductive PureCR (bop: R -> R -> R): Type :=
| PureBR: R -> R -> PureCR bop
|  PureCRRec:
R ->
PureCR bop ->
PureCR bop
.
(** Convert a `PureCR` into a CR by inserting the correct `bop` everywhere *)
Fixpoint purecr_to_cr (bop: R -> R -> R) (pure: PureCR bop): CR :=
match pure with
| PureBR r1 r2 => liftBRToCR (mkBR r1 bop (const r2))
| PureCRRec r cr' => (recurCR r bop (purecr_to_cr cr'))
end.

(** Give a way to simplify the evaluation of a PureBR *)
Lemma purecr_to_cr_eval_cr_inverses:
forall `{Ring R}
(bop: R -> R -> R)
(r1 r2: R)
(n: nat),
purecr_to_cr (PureBR bop r1 r2) # n =  {{r1, bop, (const r2)}} # n.