(frame-list-fix x) is a usual ACL2::fty list fixing function.
(frame-list-fix x) → fty::newx
In the logic, we apply frame-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 frame-list-fix$inline (x) (declare (xargs :guard (frame-listp x))) (let ((__function__ 'frame-list-fix)) (declare (ignorable __function__)) (mbe :logic (if (atom x) nil (cons (frame-fix (car x)) (frame-list-fix (cdr x)))) :exec x)))
Theorem:
(defthm frame-listp-of-frame-list-fix (b* ((fty::newx (frame-list-fix$inline x))) (frame-listp fty::newx)) :rule-classes :rewrite)
Theorem:
(defthm frame-list-fix-when-frame-listp (implies (frame-listp x) (equal (frame-list-fix x) x)))
Function:
(defun frame-list-equiv$inline (acl2::x acl2::y) (declare (xargs :guard (and (frame-listp acl2::x) (frame-listp acl2::y)))) (equal (frame-list-fix acl2::x) (frame-list-fix acl2::y)))
Theorem:
(defthm frame-list-equiv-is-an-equivalence (and (booleanp (frame-list-equiv x y)) (frame-list-equiv x x) (implies (frame-list-equiv x y) (frame-list-equiv y x)) (implies (and (frame-list-equiv x y) (frame-list-equiv y z)) (frame-list-equiv x z))) :rule-classes (:equivalence))
Theorem:
(defthm frame-list-equiv-implies-equal-frame-list-fix-1 (implies (frame-list-equiv acl2::x x-equiv) (equal (frame-list-fix acl2::x) (frame-list-fix x-equiv))) :rule-classes (:congruence))
Theorem:
(defthm frame-list-fix-under-frame-list-equiv (frame-list-equiv (frame-list-fix acl2::x) acl2::x) :rule-classes (:rewrite :rewrite-quoted-constant))
Theorem:
(defthm equal-of-frame-list-fix-1-forward-to-frame-list-equiv (implies (equal (frame-list-fix acl2::x) acl2::y) (frame-list-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm equal-of-frame-list-fix-2-forward-to-frame-list-equiv (implies (equal acl2::x (frame-list-fix acl2::y)) (frame-list-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm frame-list-equiv-of-frame-list-fix-1-forward (implies (frame-list-equiv (frame-list-fix acl2::x) acl2::y) (frame-list-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm frame-list-equiv-of-frame-list-fix-2-forward (implies (frame-list-equiv acl2::x (frame-list-fix acl2::y)) (frame-list-equiv acl2::x acl2::y)) :rule-classes :forward-chaining)
Theorem:
(defthm car-of-frame-list-fix-x-under-frame-equiv (frame-equiv (car (frame-list-fix acl2::x)) (car acl2::x)))
Theorem:
(defthm car-frame-list-equiv-congruence-on-x-under-frame-equiv (implies (frame-list-equiv acl2::x x-equiv) (frame-equiv (car acl2::x) (car x-equiv))) :rule-classes :congruence)
Theorem:
(defthm cdr-of-frame-list-fix-x-under-frame-list-equiv (frame-list-equiv (cdr (frame-list-fix acl2::x)) (cdr acl2::x)))
Theorem:
(defthm cdr-frame-list-equiv-congruence-on-x-under-frame-list-equiv (implies (frame-list-equiv acl2::x x-equiv) (frame-list-equiv (cdr acl2::x) (cdr x-equiv))) :rule-classes :congruence)
Theorem:
(defthm cons-of-frame-fix-x-under-frame-list-equiv (frame-list-equiv (cons (frame-fix acl2::x) acl2::y) (cons acl2::x acl2::y)))
Theorem:
(defthm cons-frame-equiv-congruence-on-x-under-frame-list-equiv (implies (frame-equiv acl2::x x-equiv) (frame-list-equiv (cons acl2::x acl2::y) (cons x-equiv acl2::y))) :rule-classes :congruence)
Theorem:
(defthm cons-of-frame-list-fix-y-under-frame-list-equiv (frame-list-equiv (cons acl2::x (frame-list-fix acl2::y)) (cons acl2::x acl2::y)))
Theorem:
(defthm cons-frame-list-equiv-congruence-on-y-under-frame-list-equiv (implies (frame-list-equiv acl2::y y-equiv) (frame-list-equiv (cons acl2::x acl2::y) (cons acl2::x y-equiv))) :rule-classes :congruence)
Theorem:
(defthm consp-of-frame-list-fix (equal (consp (frame-list-fix acl2::x)) (consp acl2::x)))
Theorem:
(defthm frame-list-fix-under-iff (iff (frame-list-fix acl2::x) (consp acl2::x)))
Theorem:
(defthm frame-list-fix-of-cons (equal (frame-list-fix (cons a x)) (cons (frame-fix a) (frame-list-fix x))))
Theorem:
(defthm len-of-frame-list-fix (equal (len (frame-list-fix acl2::x)) (len acl2::x)))
Theorem:
(defthm frame-list-fix-of-append (equal (frame-list-fix (append std::a std::b)) (append (frame-list-fix std::a) (frame-list-fix std::b))))
Theorem:
(defthm frame-list-fix-of-repeat (equal (frame-list-fix (repeat acl2::n acl2::x)) (repeat acl2::n (frame-fix acl2::x))))
Theorem:
(defthm list-equiv-refines-frame-list-equiv (implies (list-equiv acl2::x acl2::y) (frame-list-equiv acl2::x acl2::y)) :rule-classes :refinement)
Theorem:
(defthm nth-of-frame-list-fix (equal (nth acl2::n (frame-list-fix acl2::x)) (if (< (nfix acl2::n) (len acl2::x)) (frame-fix (nth acl2::n acl2::x)) nil)))
Theorem:
(defthm frame-list-equiv-implies-frame-list-equiv-append-1 (implies (frame-list-equiv acl2::x fty::x-equiv) (frame-list-equiv (append acl2::x acl2::y) (append fty::x-equiv acl2::y))) :rule-classes (:congruence))
Theorem:
(defthm frame-list-equiv-implies-frame-list-equiv-append-2 (implies (frame-list-equiv acl2::y fty::y-equiv) (frame-list-equiv (append acl2::x acl2::y) (append acl2::x fty::y-equiv))) :rule-classes (:congruence))
Theorem:
(defthm frame-list-equiv-implies-frame-list-equiv-nthcdr-2 (implies (frame-list-equiv acl2::l l-equiv) (frame-list-equiv (nthcdr acl2::n acl2::l) (nthcdr acl2::n l-equiv))) :rule-classes (:congruence))
Theorem:
(defthm frame-list-equiv-implies-frame-list-equiv-take-2 (implies (frame-list-equiv acl2::l l-equiv) (frame-list-equiv (take acl2::n acl2::l) (take acl2::n l-equiv))) :rule-classes (:congruence))