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