• Top
    • Documentation
    • Books
    • Recursion-and-induction
    • Boolean-reasoning
    • Debugging
    • Projects
    • Std
    • Proof-automation
    • Macro-libraries
    • ACL2
    • Interfacing-tools
    • Hardware-verification
    • Software-verification
      • Kestrel-books
        • Crypto-hdwallet
        • Error-checking
        • Apt
        • Abnf
        • Fty-extensions
        • Isar
        • Kestrel-utilities
        • Prime-field-constraint-systems
          • Proof-support
            • Constraint-equal-satp
            • Constraint-relation-satp
            • Exec-proof-tree-when-constraint-relation
            • Constraint-satp-of-relation
            • Exec-proof-tree-when-constraint-equal
              • Constraint-list-satp-of-atom
              • Constraint-list-satp-of-cons
              • Constraint-satp-of-equal
              • Constraint-list-satp-of-append
              • Constraint-list-satp-of-rev
              • Constraint-list-satp-of-nil
            • R1cs-subset
            • Semantics
            • Abstract-syntax
            • Well-formedness
            • Abstract-syntax-operations
            • R1cs-bridge
            • Concrete-syntax
            • Prime-field-library-extensions
            • R1cs-library-extensions
          • Soft
          • Bv
          • Imp-language
          • Event-macros
          • Bitcoin
          • Ethereum
          • Yul
          • Zcash
          • ACL2-programming-language
          • Prime-fields
          • Java
          • C
          • Syntheto
          • Number-theory
          • Cryptography
          • Lists-light
          • File-io-light
          • Json
          • Built-ins
          • Solidity
          • Axe
          • Std-extensions
          • Htclient
          • Typed-lists-light
          • Arithmetic-light
        • X86isa
        • Execloader
        • Axe
      • Testing-utilities
      • Math
    • Proof-support

    Exec-proof-tree-when-constraint-equal

    Characterization of a proof tree for an equality constraint.

    If running a proof tree is successful and returns an assertion for an equality constraint, then the proof tree must be one for an equality, and its components (assignment and expressions) must coincide with the ones from the assertion.

    This is used to prove constraint-satp-of-equal.

    Definitions and Theorems

    Theorem: exec-proof-tree-when-constraint-equal

    (defthm
     exec-proof-tree-when-constraint-equal
     (b*
      ((outcome (exec-proof-tree ptree defs p)))
      (implies
       (proof-outcome-case outcome :assertion)
       (b*
        ((asser (proof-outcome-assertion->get outcome))
         (asg (assertion->asg asser))
         (constr (assertion->constr asser)))
        (implies (constraint-case constr :equal)
                 (and (proof-tree-case ptree :equal)
                      (equal (proof-tree-equal->asg ptree)
                             asg)
                      (equal (proof-tree-equal->left ptree)
                             (constraint-equal->left constr))
                      (equal (proof-tree-equal->right ptree)
                             (constraint-equal->right constr))
                      (equal (eval-expr (constraint-equal->left constr)
                                        asg p)
                             (eval-expr (constraint-equal->right constr)
                                        asg p))
                      (natp (eval-expr (constraint-equal->left constr)
                                       asg p))))))))