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