Fixer for double-value-abs.
(double-value-abs-fix x) → fixed-x
Function:
(defun double-value-abs-fix (x) (declare (xargs :guard (double-value-abs-p x))) (mbe :logic (if (double-value-abs-p x) x (double-value-abs-pos-zero)) :exec x))
Theorem:
(defthm double-value-abs-p-of-double-value-abs-fix (b* ((fixed-x (double-value-abs-fix x))) (double-value-abs-p fixed-x)) :rule-classes :rewrite)
Theorem:
(defthm double-value-abs-fix-when-double-value-abs-p (implies (double-value-abs-p x) (equal (double-value-abs-fix x) x)))