• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
      • Apt
      • Zfc
      • Acre
      • Milawa
      • Smtlink
      • Abnf
      • Vwsim
      • Isar
      • Wp-gen
      • Dimacs-reader
      • Pfcs
      • 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
        • Aleobft
          • Aleobft-static
          • Aleobft-stake2
          • Aleobft-dynamic
          • Aleobft-stake
          • Aleobft-proposals
            • Correctness
            • Definition
              • Initialization
              • Transitions
              • States
                • Committees
                • System-states
                • Certificates
                • Transactions
                • Proposals
                  • Proposal
                  • Props-with-author+round
                  • Props-with-round
                  • Prop-set-unequivp
                  • Proposal-option
                  • Prop-set-none-author-p
                  • Prop-set-all-author-p
                  • Proposal-set
                    • Proposal-set-fix
                    • Proposal-setp
                      • Proposal-set-equiv
                  • Messages
                  • Validator-states
                  • Blocks
                  • Addresses
                • Events
                • Reachability
            • Library-extensions
          • Leo
        • Solidity
        • Paco
        • Concurrent-programs
        • Bls12-377-curves
      • Debugging
      • Std
      • Proof-automation
      • Macro-libraries
      • ACL2
      • Interfacing-tools
      • Hardware-verification
      • Software-verification
      • Math
      • Testing-utilities
    • Proposal-set

    Proposal-setp

    Recognizer for proposal-set.

    Signature
    (proposal-setp x) → *

    Definitions and Theorems

    Function: proposal-setp

    (defun proposal-setp (x)
      (declare (xargs :guard t))
      (if (atom x)
          (null x)
        (and (proposalp (car x))
             (or (null (cdr x))
                 (and (consp (cdr x))
                      (acl2::fast-<< (car x) (cadr x))
                      (proposal-setp (cdr x)))))))

    Theorem: booleanp-ofproposal-setp

    (defthm booleanp-ofproposal-setp
      (booleanp (proposal-setp x)))

    Theorem: setp-when-proposal-setp

    (defthm setp-when-proposal-setp
      (implies (proposal-setp x) (setp x))
      :rule-classes (:rewrite))

    Theorem: proposalp-of-head-when-proposal-setp

    (defthm proposalp-of-head-when-proposal-setp
      (implies (proposal-setp x)
               (equal (proposalp (head x))
                      (not (emptyp x)))))

    Theorem: proposal-setp-of-tail-when-proposal-setp

    (defthm proposal-setp-of-tail-when-proposal-setp
      (implies (proposal-setp x)
               (proposal-setp (tail x))))

    Theorem: proposal-setp-of-insert

    (defthm proposal-setp-of-insert
      (equal (proposal-setp (insert a x))
             (and (proposalp a)
                  (proposal-setp (sfix x)))))

    Theorem: proposalp-when-in-proposal-setp-binds-free-x

    (defthm proposalp-when-in-proposal-setp-binds-free-x
      (implies (and (in a x) (proposal-setp x))
               (proposalp a)))

    Theorem: not-in-proposal-setp-when-not-proposalp

    (defthm not-in-proposal-setp-when-not-proposalp
      (implies (and (proposal-setp x)
                    (not (proposalp a)))
               (not (in a x))))

    Theorem: proposal-setp-of-union

    (defthm proposal-setp-of-union
      (equal (proposal-setp (union x y))
             (and (proposal-setp (sfix x))
                  (proposal-setp (sfix y)))))

    Theorem: proposal-setp-of-intersect

    (defthm proposal-setp-of-intersect
      (implies (and (proposal-setp x)
                    (proposal-setp y))
               (proposal-setp (intersect x y))))

    Theorem: proposal-setp-of-difference

    (defthm proposal-setp-of-difference
      (implies (proposal-setp x)
               (proposal-setp (difference x y))))

    Theorem: proposal-setp-of-delete

    (defthm proposal-setp-of-delete
      (implies (proposal-setp x)
               (proposal-setp (delete a x))))