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