Basic theorems about concatenationp, generated by std::deflist.
Theorem:
(defthm concatenationp-of-cons (equal (concatenationp (cons acl2::a acl2::x)) (and (repetitionp acl2::a) (concatenationp acl2::x))) :rule-classes ((:rewrite)))
Theorem:
(defthm concatenationp-of-cdr-when-concatenationp (implies (concatenationp (double-rewrite acl2::x)) (concatenationp (cdr acl2::x))) :rule-classes ((:rewrite)))
Theorem:
(defthm concatenationp-when-not-consp (implies (not (consp acl2::x)) (equal (concatenationp acl2::x) (not acl2::x))) :rule-classes ((:rewrite)))
Theorem:
(defthm repetitionp-of-car-when-concatenationp (implies (concatenationp acl2::x) (iff (repetitionp (car acl2::x)) (consp acl2::x))) :rule-classes ((:rewrite)))
Theorem:
(defthm true-listp-when-concatenationp-compound-recognizer (implies (concatenationp acl2::x) (true-listp acl2::x)) :rule-classes :compound-recognizer)
Theorem:
(defthm concatenationp-of-list-fix (implies (concatenationp acl2::x) (concatenationp (list-fix acl2::x))) :rule-classes ((:rewrite)))
Theorem:
(defthm concatenationp-of-rev (equal (concatenationp (rev acl2::x)) (concatenationp (list-fix acl2::x))) :rule-classes ((:rewrite)))
Theorem:
(defthm concatenationp-of-append (equal (concatenationp (append acl2::a acl2::b)) (and (concatenationp (list-fix acl2::a)) (concatenationp acl2::b))) :rule-classes ((:rewrite)))
Theorem:
(defthm concatenationp-of-last (implies (concatenationp (double-rewrite acl2::x)) (concatenationp (last acl2::x))) :rule-classes ((:rewrite)))
Theorem:
(defthm repetitionp-of-nth-when-concatenationp (implies (concatenationp acl2::x) (iff (repetitionp (nth acl2::n acl2::x)) (< (nfix acl2::n) (len acl2::x)))) :rule-classes ((:rewrite)))
Theorem:
(defthm concatenationp-of-nthcdr (implies (concatenationp (double-rewrite acl2::x)) (concatenationp (nthcdr acl2::n acl2::x))) :rule-classes ((:rewrite)))
Theorem:
(defthm concatenationp-of-remove (implies (concatenationp acl2::x) (concatenationp (remove acl2::a acl2::x))) :rule-classes ((:rewrite)))
Theorem:
(defthm concatenationp-of-repeat (iff (concatenationp (repeat acl2::n acl2::x)) (or (repetitionp acl2::x) (zp acl2::n))) :rule-classes ((:rewrite)))
Theorem:
(defthm concatenationp-of-revappend (equal (concatenationp (revappend acl2::x acl2::y)) (and (concatenationp (list-fix acl2::x)) (concatenationp acl2::y))) :rule-classes ((:rewrite)))
Theorem:
(defthm concatenationp-of-rcons (iff (concatenationp (rcons acl2::a acl2::x)) (and (repetitionp acl2::a) (concatenationp (list-fix acl2::x)))) :rule-classes ((:rewrite)))
Theorem:
(defthm repetitionp-when-member-equal-of-concatenationp (and (implies (and (member-equal acl2::a acl2::x) (concatenationp acl2::x)) (repetitionp acl2::a)) (implies (and (concatenationp acl2::x) (member-equal acl2::a acl2::x)) (repetitionp acl2::a))) :rule-classes ((:rewrite)))
Theorem:
(defthm concatenationp-when-subsetp-equal (and (implies (and (subsetp-equal acl2::x acl2::y) (concatenationp acl2::y)) (equal (concatenationp acl2::x) (true-listp acl2::x))) (implies (and (concatenationp acl2::y) (subsetp-equal acl2::x acl2::y)) (equal (concatenationp acl2::x) (true-listp acl2::x)))) :rule-classes ((:rewrite)))
Theorem:
(defthm concatenationp-of-set-difference-equal (implies (concatenationp acl2::x) (concatenationp (set-difference-equal acl2::x acl2::y))) :rule-classes ((:rewrite)))
Theorem:
(defthm concatenationp-of-intersection-equal-1 (implies (concatenationp (double-rewrite acl2::x)) (concatenationp (intersection-equal acl2::x acl2::y))) :rule-classes ((:rewrite)))
Theorem:
(defthm concatenationp-of-intersection-equal-2 (implies (concatenationp (double-rewrite acl2::y)) (concatenationp (intersection-equal acl2::x acl2::y))) :rule-classes ((:rewrite)))
Theorem:
(defthm concatenationp-of-union-equal (equal (concatenationp (union-equal acl2::x acl2::y)) (and (concatenationp (list-fix acl2::x)) (concatenationp (double-rewrite acl2::y)))) :rule-classes ((:rewrite)))
Theorem:
(defthm concatenationp-of-take (implies (concatenationp (double-rewrite acl2::x)) (iff (concatenationp (take acl2::n acl2::x)) (or (repetitionp nil) (<= (nfix acl2::n) (len acl2::x))))) :rule-classes ((:rewrite)))
Theorem:
(defthm concatenationp-of-update-nth (implies (concatenationp (double-rewrite acl2::x)) (iff (concatenationp (update-nth acl2::n acl2::y acl2::x)) (and (repetitionp acl2::y) (or (<= (nfix acl2::n) (len acl2::x)) (repetitionp nil))))) :rule-classes ((:rewrite)))