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