fact: Fixpoint minus (alpha beta : T1) :T1 := match alpha,beta with | zero, y => zero | cons zero n _, cons zero n' _ => if (le_lt_dec n n') then zero else cons zero (Peano.pred (n-n')) zero | cons zero n _, zero => cons zero n zero | cons zero _ _, _ => zero | cons a n b, zero => cons a n b | cons a n b, cons a' n' b' => (match compare a a' with | Lt => zero | Gt => cons a n b | Eq => (match Nat.compare n n' with | Lt => zero | Gt => (cons a (Peano.pred (n - n')) b') | Eq => b - b' end) end) end where "alpha - beta" := (minus alpha beta):t1_scope.
imports: Coq(Arith Max Bool Lia Compare_dec Relations Ensembles Wellfounded Bool RelationClasses Operators_Properties ArithRing Logic.Eqdep_dec) hydras(More_Arith Restriction DecPreOrder) hydras(OrdNotations)