Symbolic version of 4vec-plus.
Function:
(defun a4vec-plus (x y) (declare (xargs :guard (and (a4vec-p x) (a4vec-p y)))) (let ((__function__ 'a4vec-plus)) (declare (ignorable __function__)) (a4vec-ite (aig-and (a2vec-p x) (a2vec-p y)) (b* (((a4vec x)) ((a4vec y)) (res (aig-+-ss nil x.upper y.upper))) (a4vec res res)) (a4vec-x))))
Theorem:
(defthm a4vec-p-of-a4vec-plus (b* ((res (a4vec-plus x y))) (a4vec-p res)) :rule-classes :rewrite)
Theorem:
(defthm a4vec-plus-correct (equal (a4vec-eval (a4vec-plus x y) env) (4vec-plus (a4vec-eval x env) (a4vec-eval y env))))
Theorem:
(defthm a4vec-plus-of-a4vec-fix-x (equal (a4vec-plus (a4vec-fix x) y) (a4vec-plus x y)))
Theorem:
(defthm a4vec-plus-a4vec-equiv-congruence-on-x (implies (a4vec-equiv x x-equiv) (equal (a4vec-plus x y) (a4vec-plus x-equiv y))) :rule-classes :congruence)
Theorem:
(defthm a4vec-plus-of-a4vec-fix-y (equal (a4vec-plus x (a4vec-fix y)) (a4vec-plus x y)))
Theorem:
(defthm a4vec-plus-a4vec-equiv-congruence-on-y (implies (a4vec-equiv y y-equiv) (equal (a4vec-plus x y) (a4vec-plus x y-equiv))) :rule-classes :congruence)