• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
    • Debugging
    • Std
    • Proof-automation
    • Macro-libraries
    • ACL2
    • Interfacing-tools
    • Hardware-verification
    • Software-verification
      • Kestrel-books
        • Crypto-hdwallet
        • Apt
        • Error-checking
        • Fty-extensions
        • Isar
        • Kestrel-utilities
        • Set
        • Soft
        • C
        • Bv
        • Imp-language
        • Event-macros
        • Java
        • Bitcoin
        • Ethereum
        • Yul
        • Zcash
        • ACL2-programming-language
          • Primitive-functions
          • Translated-terms
          • Values
          • Evaluation
          • Program-equivalence
          • Functions
          • Packages
          • Programs
          • Interpreter
          • Evaluation-states
            • Eval-state
              • Eval-state-fix
              • Eval-state-case
              • Eval-state-p
              • Eval-state-equiv
                • Eval-state-init
                • Eval-state-trans
                • Eval-state-final
                • Eval-state-kind
                • Eval-state-error
              • Frame
              • Binding
              • Stack
          • Prime-fields
          • Json
          • Syntheto
          • File-io-light
          • Cryptography
          • Number-theory
          • Lists-light
          • Axe
          • Builtins
          • Solidity
          • Helpers
          • Htclient
          • Typed-lists-light
          • Arithmetic-light
        • X86isa
        • Axe
        • Execloader
      • Math
      • Testing-utilities
    • Eval-state

    Eval-state-equiv

    Basic equivalence relation for eval-state structures.

    Definitions and Theorems

    Function: eval-state-equiv$inline

    (defun eval-state-equiv$inline (acl2::x acl2::y)
      (declare (xargs :guard (and (eval-state-p acl2::x)
                                  (eval-state-p acl2::y))))
      (equal (eval-state-fix acl2::x)
             (eval-state-fix acl2::y)))

    Theorem: eval-state-equiv-is-an-equivalence

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

    Theorem: eval-state-equiv-implies-equal-eval-state-fix-1

    (defthm eval-state-equiv-implies-equal-eval-state-fix-1
      (implies (eval-state-equiv acl2::x x-equiv)
               (equal (eval-state-fix acl2::x)
                      (eval-state-fix x-equiv)))
      :rule-classes (:congruence))

    Theorem: eval-state-fix-under-eval-state-equiv

    (defthm eval-state-fix-under-eval-state-equiv
      (eval-state-equiv (eval-state-fix acl2::x)
                        acl2::x)
      :rule-classes (:rewrite :rewrite-quoted-constant))

    Theorem: equal-of-eval-state-fix-1-forward-to-eval-state-equiv

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

    Theorem: equal-of-eval-state-fix-2-forward-to-eval-state-equiv

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

    Theorem: eval-state-equiv-of-eval-state-fix-1-forward

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

    Theorem: eval-state-equiv-of-eval-state-fix-2-forward

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