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