Basic equivalence relation for enumspec structures.
Function:
(defun enumspec-equiv$inline (acl2::x acl2::y) (declare (xargs :guard (and (enumspecp acl2::x) (enumspecp acl2::y)))) (equal (enumspec-fix acl2::x) (enumspec-fix acl2::y)))
Theorem:
(defthm enumspec-equiv-is-an-equivalence (and (booleanp (enumspec-equiv x y)) (enumspec-equiv x x) (implies (enumspec-equiv x y) (enumspec-equiv y x)) (implies (and (enumspec-equiv x y) (enumspec-equiv y z)) (enumspec-equiv x z))) :rule-classes (:equivalence))
Theorem:
(defthm enumspec-equiv-implies-equal-enumspec-fix-1 (implies (enumspec-equiv acl2::x x-equiv) (equal (enumspec-fix acl2::x) (enumspec-fix x-equiv))) :rule-classes (:congruence))
Theorem:
(defthm enumspec-fix-under-enumspec-equiv (enumspec-equiv (enumspec-fix acl2::x) acl2::x) :rule-classes (:rewrite :rewrite-quoted-constant))
Theorem:
(defthm equal-of-enumspec-fix-1-forward-to-enumspec-equiv (implies (equal (enumspec-fix acl2::x) acl2::y) (enumspec-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm equal-of-enumspec-fix-2-forward-to-enumspec-equiv (implies (equal acl2::x (enumspec-fix acl2::y)) (enumspec-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm enumspec-equiv-of-enumspec-fix-1-forward (implies (enumspec-equiv (enumspec-fix acl2::x) acl2::y) (enumspec-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm enumspec-equiv-of-enumspec-fix-2-forward (implies (enumspec-equiv acl2::x (enumspec-fix acl2::y)) (enumspec-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)