Recognizer for svar-widths.
(svar-widths-p x) → *
Function:
(defun svar-widths-p (x) (declare (xargs :guard t)) (let ((__function__ 'svar-widths-p)) (declare (ignorable __function__)) (if (atom x) (eq x nil) (and (consp (car x)) (svar-p (caar x)) (integerp (cdar x)) (svar-widths-p (cdr x))))))
Theorem:
(defthm svar-widths-p-of-repeat (iff (svar-widths-p (repeat acl2::n x)) (or (and (consp x) (svar-p (car x)) (integerp (cdr x))) (zp acl2::n))) :rule-classes ((:rewrite)))
Theorem:
(defthm svar-widths-p-of-rev (equal (svar-widths-p (rev x)) (svar-widths-p (list-fix x))) :rule-classes ((:rewrite)))
Theorem:
(defthm svar-widths-p-of-list-fix (implies (svar-widths-p x) (svar-widths-p (list-fix x))) :rule-classes ((:rewrite)))
Theorem:
(defthm true-listp-when-svar-widths-p-compound-recognizer (implies (svar-widths-p x) (true-listp x)) :rule-classes :compound-recognizer)
Theorem:
(defthm svar-widths-p-when-not-consp (implies (not (consp x)) (equal (svar-widths-p x) (not x))) :rule-classes ((:rewrite)))
Theorem:
(defthm svar-widths-p-of-cdr-when-svar-widths-p (implies (svar-widths-p (double-rewrite x)) (svar-widths-p (cdr x))) :rule-classes ((:rewrite)))
Theorem:
(defthm svar-widths-p-of-cons (equal (svar-widths-p (cons acl2::a x)) (and (and (consp acl2::a) (svar-p (car acl2::a)) (integerp (cdr acl2::a))) (svar-widths-p x))) :rule-classes ((:rewrite)))
Theorem:
(defthm svar-widths-p-of-remove-assoc (implies (svar-widths-p x) (svar-widths-p (remove-assoc-equal acl2::name x))) :rule-classes ((:rewrite)))
Theorem:
(defthm svar-widths-p-of-put-assoc (implies (and (svar-widths-p x)) (iff (svar-widths-p (put-assoc-equal acl2::name acl2::val x)) (and (svar-p acl2::name) (integerp acl2::val)))) :rule-classes ((:rewrite)))
Theorem:
(defthm svar-widths-p-of-fast-alist-clean (implies (svar-widths-p x) (svar-widths-p (fast-alist-clean x))) :rule-classes ((:rewrite)))
Theorem:
(defthm svar-widths-p-of-hons-shrink-alist (implies (and (svar-widths-p x) (svar-widths-p y)) (svar-widths-p (hons-shrink-alist x y))) :rule-classes ((:rewrite)))
Theorem:
(defthm svar-widths-p-of-hons-acons (equal (svar-widths-p (hons-acons acl2::a acl2::n x)) (and (svar-p acl2::a) (integerp acl2::n) (svar-widths-p x))) :rule-classes ((:rewrite)))
Theorem:
(defthm integerp-of-cdr-of-hons-assoc-equal-when-svar-widths-p (implies (svar-widths-p x) (iff (integerp (cdr (hons-assoc-equal acl2::k x))) (or (hons-assoc-equal acl2::k x) (integerp nil)))) :rule-classes ((:rewrite)))
Theorem:
(defthm alistp-when-svar-widths-p-rewrite (implies (svar-widths-p x) (alistp x)) :rule-classes ((:rewrite)))
Theorem:
(defthm alistp-when-svar-widths-p (implies (svar-widths-p x) (alistp x)) :rule-classes :tau-system)
Theorem:
(defthm integerp-of-cdar-when-svar-widths-p (implies (svar-widths-p x) (iff (integerp (cdar x)) (or (consp x) (integerp nil)))) :rule-classes ((:rewrite)))
Theorem:
(defthm svar-p-of-caar-when-svar-widths-p (implies (svar-widths-p x) (iff (svar-p (caar x)) (or (consp x) (svar-p nil)))) :rule-classes ((:rewrite)))