(sd-filter-problems x major minor) → (mv major minor)
Function:
(defun sd-filter-problems (x major minor) (declare (xargs :guard (and (sd-problemlist-p x) (sd-problemlist-p major) (sd-problemlist-p minor)))) (let ((__function__ 'sd-filter-problems)) (declare (ignorable __function__)) (cond ((atom x) (mv major minor)) ((sd-problem-major-p (car x)) (sd-filter-problems (cdr x) (cons (car x) major) minor)) (t (sd-filter-problems (cdr x) major (cons (car x) minor))))))
Theorem:
(defthm sd-problemlist-p-of-sd-filter-problems.major (implies (and (force (sd-problemlist-p x)) (force (sd-problemlist-p major)) (force (sd-problemlist-p minor))) (b* (((mv ?major ?minor) (sd-filter-problems x major minor))) (sd-problemlist-p major))) :rule-classes :rewrite)
Theorem:
(defthm sd-problemlist-p-of-sd-filter-problems.minor (implies (and (force (sd-problemlist-p x)) (force (sd-problemlist-p major)) (force (sd-problemlist-p minor))) (b* (((mv ?major ?minor) (sd-filter-problems x major minor))) (sd-problemlist-p minor))) :rule-classes :rewrite)
Theorem:
(defthm true-listp-sd-filter-problems (and (implies (true-listp major) (true-listp (mv-nth 0 (sd-filter-problems x major minor)))) (implies (true-listp minor) (true-listp (mv-nth 1 (sd-filter-problems x major minor))))))