• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
      • Apt
      • Zfc
      • Acre
      • Milawa
      • Smtlink
      • Abnf
      • Vwsim
      • Isar
      • Wp-gen
      • Dimacs-reader
      • Pfcs
        • Proof-support
        • Abstract-syntax
          • Syntax-abstraction
          • Expression
          • Definition
          • Constraint
          • Definition-option
          • Abstract-syntax-operations
          • System
          • Convenience-constructors
          • System-result
            • System-result-fix
            • System-result-equiv
              • System-result-ok
              • System-result-err
              • System-resultp
              • System-result-kind
            • Expression-result
            • Expression-list-result
            • Definition-result
            • Definition-list-result
            • Constraint-result
            • Constraint-list-result
            • Expression-list
            • Definition-list
            • Constraint-list
          • R1cs-subset
          • Semantics
          • Abstract-syntax-operations
          • Indexed-names
          • Well-formedness
          • 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
    • System-result

    System-result-equiv

    Basic equivalence relation for system-result structures.

    Definitions and Theorems

    Function: system-result-equiv$inline

    (defun system-result-equiv$inline (acl2::x acl2::y)
      (declare (xargs :guard (and (system-resultp acl2::x)
                                  (system-resultp acl2::y))))
      (equal (system-result-fix acl2::x)
             (system-result-fix acl2::y)))

    Theorem: system-result-equiv-is-an-equivalence

    (defthm system-result-equiv-is-an-equivalence
      (and (booleanp (system-result-equiv x y))
           (system-result-equiv x x)
           (implies (system-result-equiv x y)
                    (system-result-equiv y x))
           (implies (and (system-result-equiv x y)
                         (system-result-equiv y z))
                    (system-result-equiv x z)))
      :rule-classes (:equivalence))

    Theorem: system-result-equiv-implies-equal-system-result-fix-1

    (defthm system-result-equiv-implies-equal-system-result-fix-1
      (implies (system-result-equiv acl2::x x-equiv)
               (equal (system-result-fix acl2::x)
                      (system-result-fix x-equiv)))
      :rule-classes (:congruence))

    Theorem: system-result-fix-under-system-result-equiv

    (defthm system-result-fix-under-system-result-equiv
      (system-result-equiv (system-result-fix acl2::x)
                           acl2::x)
      :rule-classes (:rewrite :rewrite-quoted-constant))

    Theorem: equal-of-system-result-fix-1-forward-to-system-result-equiv

    (defthm equal-of-system-result-fix-1-forward-to-system-result-equiv
      (implies (equal (system-result-fix acl2::x)
                      acl2::y)
               (system-result-equiv acl2::x acl2::y))
      :rule-classes :forward-chaining)

    Theorem: equal-of-system-result-fix-2-forward-to-system-result-equiv

    (defthm equal-of-system-result-fix-2-forward-to-system-result-equiv
      (implies (equal acl2::x (system-result-fix acl2::y))
               (system-result-equiv acl2::x acl2::y))
      :rule-classes :forward-chaining)

    Theorem: system-result-equiv-of-system-result-fix-1-forward

    (defthm system-result-equiv-of-system-result-fix-1-forward
      (implies (system-result-equiv (system-result-fix acl2::x)
                                    acl2::y)
               (system-result-equiv acl2::x acl2::y))
      :rule-classes :forward-chaining)

    Theorem: system-result-equiv-of-system-result-fix-2-forward

    (defthm system-result-equiv-of-system-result-fix-2-forward
      (implies (system-result-equiv acl2::x (system-result-fix acl2::y))
               (system-result-equiv acl2::x acl2::y))
      :rule-classes :forward-chaining)