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