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