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