Fixing function for integer-range-listp.
(integer-range-list-fix lower upper x) → fixed-x
This lifts integer-range-fix to lists.
See that function for more information,
in particular about
the fixing of
Function:
(defun integer-range-list-fix (lower upper x) (declare (xargs :guard (and (integerp lower) (integerp upper) (integer-range-listp (ifix lower) (ifix upper) x)))) (let ((__function__ 'integer-range-list-fix)) (declare (ignorable __function__)) (mbe :logic (cond ((atom x) nil) (t (cons (integer-range-fix lower upper (car x)) (integer-range-list-fix lower upper (cdr x))))) :exec x)))
Theorem:
(defthm return-type-of-integer-range-list-fix (implies (and (integerp lower) (integerp upper) (< lower upper)) (b* ((fixed-x (integer-range-list-fix lower upper x))) (integer-range-listp lower upper fixed-x))) :rule-classes :rewrite)
Theorem:
(defthm integer-listp-of-integer-range-list-fix (b* ((fixed-x (integer-range-list-fix lower upper x))) (integer-listp fixed-x)) :rule-classes :rewrite)
Theorem:
(defthm integer-range-list-fix-when-integer-range-p (implies (and (integer-range-listp (ifix lower) (ifix upper) x) (< (ifix lower) (ifix upper))) (equal (integer-range-list-fix lower upper x) x)))
Theorem:
(defthm integer-range-list-fix-of-nil (equal (integer-range-list-fix lower upper nil) nil))
Theorem:
(defthm integer-range-list-fix-of-cons (equal (integer-range-list-fix lower upper (cons x y)) (cons (integer-range-fix lower upper x) (integer-range-list-fix lower upper y))))
Theorem:
(defthm integer-range-list-fix-of-append (equal (integer-range-list-fix lower upper (append x y)) (append (integer-range-list-fix lower upper x) (integer-range-list-fix lower upper y))))
Theorem:
(defthm len-of-integer-range-list-fix (equal (len (integer-range-list-fix lower upper x)) (len x)))
Theorem:
(defthm consp-of-integer-range-list-fix (equal (consp (integer-range-list-fix lower upper x)) (consp x)))
Theorem:
(defthm car-of-integer-range-list-fix (implies (consp x) (equal (car (integer-range-list-fix lower upper x)) (integer-range-fix lower upper (car x)))))
Theorem:
(defthm cdr-of-integer-range-list-fix (implies (consp x) (equal (cdr (integer-range-list-fix lower upper x)) (integer-range-list-fix lower upper (cdr x)))))
Theorem:
(defthm rev-of-integer-range-list-fix (equal (rev (integer-range-list-fix lower upper x)) (integer-range-list-fix lower upper (rev x))))
Theorem:
(defthm integer-range-list-fix-of-ifix-lower (equal (integer-range-list-fix (ifix lower) upper x) (integer-range-list-fix lower upper x)))
Theorem:
(defthm integer-range-list-fix-int-equiv-congruence-on-lower (implies (int-equiv lower lower-equiv) (equal (integer-range-list-fix lower upper x) (integer-range-list-fix lower-equiv upper x))) :rule-classes :congruence)
Theorem:
(defthm integer-range-list-fix-of-ifix-upper (equal (integer-range-list-fix lower (ifix upper) x) (integer-range-list-fix lower upper x)))
Theorem:
(defthm integer-range-list-fix-int-equiv-congruence-on-upper (implies (int-equiv upper upper-equiv) (equal (integer-range-list-fix lower upper x) (integer-range-list-fix lower upper-equiv x))) :rule-classes :congruence)