(candidate-assigns-fix x) is a usual ACL2::fty list fixing function.
(candidate-assigns-fix x) → fty::newx
In the logic, we apply candidate-assign-fix to each member of the x. In the execution, none of that is actually necessary and this is just an inlined identity function.
Function:
(defun candidate-assigns-fix$inline (x) (declare (xargs :guard (candidate-assigns-p x))) (let ((__function__ 'candidate-assigns-fix)) (declare (ignorable __function__)) (mbe :logic (if (atom x) nil (cons (candidate-assign-fix (car x)) (candidate-assigns-fix (cdr x)))) :exec x)))
Theorem:
(defthm candidate-assigns-p-of-candidate-assigns-fix (b* ((fty::newx (candidate-assigns-fix$inline x))) (candidate-assigns-p fty::newx)) :rule-classes :rewrite)
Theorem:
(defthm candidate-assigns-fix-when-candidate-assigns-p (implies (candidate-assigns-p x) (equal (candidate-assigns-fix x) x)))
Function:
(defun candidate-assigns-equiv$inline (x y) (declare (xargs :guard (and (candidate-assigns-p x) (candidate-assigns-p y)))) (equal (candidate-assigns-fix x) (candidate-assigns-fix y)))
Theorem:
(defthm candidate-assigns-equiv-is-an-equivalence (and (booleanp (candidate-assigns-equiv x y)) (candidate-assigns-equiv x x) (implies (candidate-assigns-equiv x y) (candidate-assigns-equiv y x)) (implies (and (candidate-assigns-equiv x y) (candidate-assigns-equiv y z)) (candidate-assigns-equiv x z))) :rule-classes (:equivalence))
Theorem:
(defthm candidate-assigns-equiv-implies-equal-candidate-assigns-fix-1 (implies (candidate-assigns-equiv x x-equiv) (equal (candidate-assigns-fix x) (candidate-assigns-fix x-equiv))) :rule-classes (:congruence))
Theorem:
(defthm candidate-assigns-fix-under-candidate-assigns-equiv (candidate-assigns-equiv (candidate-assigns-fix x) x) :rule-classes (:rewrite :rewrite-quoted-constant))
Theorem:
(defthm equal-of-candidate-assigns-fix-1-forward-to-candidate-assigns-equiv (implies (equal (candidate-assigns-fix x) y) (candidate-assigns-equiv x y)) :rule-classes :forward-chaining)
Theorem:
(defthm equal-of-candidate-assigns-fix-2-forward-to-candidate-assigns-equiv (implies (equal x (candidate-assigns-fix y)) (candidate-assigns-equiv x y)) :rule-classes :forward-chaining)
Theorem:
(defthm candidate-assigns-equiv-of-candidate-assigns-fix-1-forward (implies (candidate-assigns-equiv (candidate-assigns-fix x) y) (candidate-assigns-equiv x y)) :rule-classes :forward-chaining)
Theorem:
(defthm candidate-assigns-equiv-of-candidate-assigns-fix-2-forward (implies (candidate-assigns-equiv x (candidate-assigns-fix y)) (candidate-assigns-equiv x y)) :rule-classes :forward-chaining)
Theorem:
(defthm car-of-candidate-assigns-fix-x-under-candidate-assign-equiv (candidate-assign-equiv (car (candidate-assigns-fix x)) (car x)))
Theorem:
(defthm car-candidate-assigns-equiv-congruence-on-x-under-candidate-assign-equiv (implies (candidate-assigns-equiv x x-equiv) (candidate-assign-equiv (car x) (car x-equiv))) :rule-classes :congruence)
Theorem:
(defthm cdr-of-candidate-assigns-fix-x-under-candidate-assigns-equiv (candidate-assigns-equiv (cdr (candidate-assigns-fix x)) (cdr x)))
Theorem:
(defthm cdr-candidate-assigns-equiv-congruence-on-x-under-candidate-assigns-equiv (implies (candidate-assigns-equiv x x-equiv) (candidate-assigns-equiv (cdr x) (cdr x-equiv))) :rule-classes :congruence)
Theorem:
(defthm cons-of-candidate-assign-fix-x-under-candidate-assigns-equiv (candidate-assigns-equiv (cons (candidate-assign-fix x) y) (cons x y)))
Theorem:
(defthm cons-candidate-assign-equiv-congruence-on-x-under-candidate-assigns-equiv (implies (candidate-assign-equiv x x-equiv) (candidate-assigns-equiv (cons x y) (cons x-equiv y))) :rule-classes :congruence)
Theorem:
(defthm cons-of-candidate-assigns-fix-y-under-candidate-assigns-equiv (candidate-assigns-equiv (cons x (candidate-assigns-fix y)) (cons x y)))
Theorem:
(defthm cons-candidate-assigns-equiv-congruence-on-y-under-candidate-assigns-equiv (implies (candidate-assigns-equiv y y-equiv) (candidate-assigns-equiv (cons x y) (cons x y-equiv))) :rule-classes :congruence)
Theorem:
(defthm consp-of-candidate-assigns-fix (equal (consp (candidate-assigns-fix x)) (consp x)))
Theorem:
(defthm candidate-assigns-fix-under-iff (iff (candidate-assigns-fix x) (consp x)))
Theorem:
(defthm candidate-assigns-fix-of-cons (equal (candidate-assigns-fix (cons a x)) (cons (candidate-assign-fix a) (candidate-assigns-fix x))))
Theorem:
(defthm len-of-candidate-assigns-fix (equal (len (candidate-assigns-fix x)) (len x)))
Theorem:
(defthm candidate-assigns-fix-of-append (equal (candidate-assigns-fix (append std::a std::b)) (append (candidate-assigns-fix std::a) (candidate-assigns-fix std::b))))
Theorem:
(defthm candidate-assigns-fix-of-repeat (equal (candidate-assigns-fix (acl2::repeat n x)) (acl2::repeat n (candidate-assign-fix x))))
Theorem:
(defthm list-equiv-refines-candidate-assigns-equiv (implies (acl2::list-equiv x y) (candidate-assigns-equiv x y)) :rule-classes :refinement)
Theorem:
(defthm nth-of-candidate-assigns-fix (equal (nth n (candidate-assigns-fix x)) (if (< (nfix n) (len x)) (candidate-assign-fix (nth n x)) nil)))
Theorem:
(defthm candidate-assigns-equiv-implies-candidate-assigns-equiv-append-1 (implies (candidate-assigns-equiv x fty::x-equiv) (candidate-assigns-equiv (append x y) (append fty::x-equiv y))) :rule-classes (:congruence))
Theorem:
(defthm candidate-assigns-equiv-implies-candidate-assigns-equiv-append-2 (implies (candidate-assigns-equiv y fty::y-equiv) (candidate-assigns-equiv (append x y) (append x fty::y-equiv))) :rule-classes (:congruence))
Theorem:
(defthm candidate-assigns-equiv-implies-candidate-assigns-equiv-nthcdr-2 (implies (candidate-assigns-equiv l l-equiv) (candidate-assigns-equiv (nthcdr n l) (nthcdr n l-equiv))) :rule-classes (:congruence))
Theorem:
(defthm candidate-assigns-equiv-implies-candidate-assigns-equiv-take-2 (implies (candidate-assigns-equiv l l-equiv) (candidate-assigns-equiv (take n l) (take n l-equiv))) :rule-classes (:congruence))