RIS.positive_regexp: regular expressions that do not contain the empty word.

Set Implicit Arguments.

Require Import tools algebra language regexp systems.

Section s.
  Context {X : Set}.
  Context {decX : decidable_set X}.

  Notation Regexp := (@regexp X).

  Fixpoint positive e : Regexp :=
    match e with
    | e_zero | e_unzero
    | xx
    | e_add e fpositive e positive f
    | e_prod e fpositive e · f e · positive f
    | e_star epositive e · e
    end.

  Lemma positive_lang e u : positive e u e u u [].

  Lemma positive_KA e f : e=KA f positive e =KA positive f.

  Lemma positive_KA_inf e f : eKA f positive e KA positive f.

  Lemma positive_inf e : positive e KA e.

  Lemma positive_star e : positive e =KA e .

End s.