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