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