• 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
          • Transformations
          • Language
            • Abstract-syntax
            • Dynamic-semantics
            • Concrete-syntax
            • Static-soundness
            • Static-semantics
              • Static-safety-checking
                • Check-safe-statements/blocks/cases/fundefs
                • Check-safe-expressions
                • Check-safe-fundef-list
                • Check-safe-variable-multi
                • Check-safe-variable-single
                • Check-safe-assign-multi
                • Check-safe-assign-single
                • Check-safe-path
                • Check-safe-extends-varset
                • Vars+modes
                • Add-vars
                • Add-var
                • Add-funtypes
                • Check-safe-literal
                • Funtype
                • Get-funtype
                • Check-var
                • Check-safe-top-block
                • Check-safe-path-list
                • Vars+modes-result
                • Funtype-result
                • Funtable-result
                • Funtable-for-fundefs
                • Funtype-for-fundef
                • Funtable
                  • Funtablep
                  • Funtable-fix
                  • Funtable-equiv
                • Static-shadowing-checking
                • Mode-set-result
                • Literal-evaluation
                • Static-identifier-checking
                • Static-safety-checking-evm
                • Mode-set
                • Modes
              • Errors
            • Yul-json
          • Zcash
          • ACL2-programming-language
          • 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
    • Funtable

    Funtable-equiv

    Basic equivalence relation for funtable structures.

    Definitions and Theorems

    Function: funtable-equiv$inline

    (defun funtable-equiv$inline (acl2::x acl2::y)
      (declare (xargs :guard (and (funtablep acl2::x)
                                  (funtablep acl2::y))))
      (equal (funtable-fix acl2::x)
             (funtable-fix acl2::y)))

    Theorem: funtable-equiv-is-an-equivalence

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

    Theorem: funtable-equiv-implies-equal-funtable-fix-1

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

    Theorem: funtable-fix-under-funtable-equiv

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

    Theorem: equal-of-funtable-fix-1-forward-to-funtable-equiv

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

    Theorem: equal-of-funtable-fix-2-forward-to-funtable-equiv

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

    Theorem: funtable-equiv-of-funtable-fix-1-forward

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

    Theorem: funtable-equiv-of-funtable-fix-2-forward

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