Lemmas about strip-cdrs available in the std/alists library.
Note that
Even so, we provide many lemmas for working with
Theorem:
(defthm strip-cdrs-when-atom (implies (atom x) (equal (strip-cdrs x) nil)))
Theorem:
(defthm strip-cdrs-of-cons (equal (strip-cdrs (cons a x)) (cons (cdr a) (strip-cdrs x))))
Theorem:
(defthm len-of-strip-cdrs (equal (len (strip-cdrs x)) (len x)))
Theorem:
(defthm consp-of-strip-cdrs (equal (consp (strip-cdrs x)) (consp x)))
Theorem:
(defthm car-of-strip-cdrs (equal (car (strip-cdrs x)) (cdr (car x))))
Theorem:
(defthm cdr-of-strip-cdrs (equal (cdr (strip-cdrs x)) (strip-cdrs (cdr x))))
Theorem:
(defthm strip-cdrs-under-iff (iff (strip-cdrs x) (consp x)))
Theorem:
(defthm strip-cdrs-of-list-fix (equal (strip-cdrs (list-fix x)) (strip-cdrs x)))
Theorem:
(defthm list-equiv-implies-equal-strip-cdrs-1 (implies (list-equiv x x-equiv) (equal (strip-cdrs x) (strip-cdrs x-equiv))) :rule-classes (:congruence))
Theorem:
(defthm set-equiv-implies-set-equiv-strip-cdrs-1 (implies (set-equiv x x-equiv) (set-equiv (strip-cdrs x) (strip-cdrs x-equiv))) :rule-classes (:congruence))
Theorem:
(defthm strip-cdrs-of-append (equal (strip-cdrs (append x y)) (append (strip-cdrs x) (strip-cdrs y))))
Theorem:
(defthm strip-cdrs-of-rev (equal (strip-cdrs (rev x)) (rev (strip-cdrs x))))
Theorem:
(defthm strip-cdrs-of-revappend (equal (strip-cdrs (revappend x y)) (revappend (strip-cdrs x) (strip-cdrs y))))
Theorem:
(defthm strip-cdrs-of-repeat (equal (strip-cdrs (repeat n x)) (repeat n (cdr x))))
Theorem:
(defthm strip-cdrs-of-take (equal (strip-cdrs (take n x)) (take n (strip-cdrs x))))
Theorem:
(defthm strip-cdrs-of-nthcdr (equal (strip-cdrs (nthcdr n x)) (nthcdr n (strip-cdrs x))))
Theorem:
(defthm strip-cdrs-of-last (equal (strip-cdrs (last x)) (last (strip-cdrs x))))
Theorem:
(defthm strip-cdrs-of-butlast (equal (strip-cdrs (butlast x n)) (butlast (strip-cdrs x) n)))
Theorem:
(defthm strip-cdrs-of-pairlis$ (equal (strip-cdrs (pairlis$ x y)) (take (len x) y)))