• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
      • Apt
      • Zfc
      • Acre
      • Milawa
      • Smtlink
      • Abnf
      • Vwsim
      • Isar
      • Wp-gen
      • Dimacs-reader
      • Pfcs
        • Proof-support
        • Abstract-syntax
        • R1cs-subset
        • Semantics
        • Abstract-syntax-operations
        • Indexed-names
        • Well-formedness
          • Definition-list-wfp
          • Definition-wfp
          • Constraint-wfp
          • Constraint-list-wfp
          • System-wfp
          • Concrete-syntax
          • R1cs-bridge
          • Parser-interface
        • Legacy-defrstobj
        • Proof-checker-array
        • Soft
        • C
        • Farray
        • Rp-rewriter
        • Instant-runoff-voting
        • Imp-language
        • Sidekick
        • Leftist-trees
        • Java
        • Taspi
        • Bitcoin
        • Riscv
        • Des
        • Ethereum
        • X86isa
        • Sha-2
        • Yul
        • Zcash
        • Proof-checker-itp13
        • Regex
        • ACL2-programming-language
        • Json
        • Jfkr
        • Equational
        • Cryptography
        • Poseidon
        • Where-do-i-place-my-book
        • Axe
        • Bigmems
        • Builtins
        • Execloader
        • Aleo
        • Solidity
        • Paco
        • Concurrent-programs
        • Bls12-377-curves
      • Debugging
      • Std
      • Proof-automation
      • Macro-libraries
      • ACL2
      • Interfacing-tools
      • Hardware-verification
      • Software-verification
      • Math
      • Testing-utilities
    • Well-formedness

    System-wfp

    Check if a system is well-formed.

    Signature
    (system-wfp sys) → yes/no
    Arguments
    sys — Guard (systemp sys).
    Returns
    yes/no — Type (booleanp yes/no).

    The list of definitions must be well-formed, and the list of constraints must be well-formed with respect to the list of definitions.

    Definitions and Theorems

    Function: system-wfp

    (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: booleanp-of-system-wfp

    (defthm booleanp-of-system-wfp
      (b* ((yes/no (system-wfp sys)))
        (booleanp yes/no))
      :rule-classes :rewrite)

    Theorem: system-wfp-of-system-fix-sys

    (defthm system-wfp-of-system-fix-sys
      (equal (system-wfp (system-fix sys))
             (system-wfp sys)))

    Theorem: system-wfp-system-equiv-congruence-on-sys

    (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)