Check if a system is well-formed.
The list of definitions must be well-formed, and the list of constraints must be well-formed with respect to the list of definitions.
Function:
(defun system-wfp (sys) (declare (xargs :guard (systemp sys))) (let ((__function__ 'system-wfp)) (declare (ignorable __function__)) (b* (((system sys) sys)) (and (definition-list-wfp sys.definitions) (constraint-list-wfp sys.constraints sys.definitions)))))
Theorem:
(defthm booleanp-of-system-wfp (b* ((yes/no (system-wfp sys))) (booleanp yes/no)) :rule-classes :rewrite)
Theorem:
(defthm system-wfp-of-system-fix-sys (equal (system-wfp (system-fix sys)) (system-wfp sys)))
Theorem:
(defthm system-wfp-system-equiv-congruence-on-sys (implies (system-equiv sys sys-equiv) (equal (system-wfp sys) (system-wfp sys-equiv))) :rule-classes :congruence)