• 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
        • Apt
        • Error-checking
        • Abnf
        • Fty-extensions
        • Isar
        • Kestrel-utilities
        • Pfcs
        • Soft
        • Bv
        • Imp-language
        • Event-macros
        • Bitcoin
        • Ethereum
        • Yul
        • Zcash
        • ACL2-programming-language
        • Prime-fields
        • Java
        • C
        • Syntheto
        • File-io-light
        • Number-theory
        • Cryptography
        • Lists-light
        • Json
        • Built-ins
        • Axe
        • Solidity
        • Std-extensions
          • Std/util-extensions
          • Std/basic-extensions
            • Organize-symbols-by-pkg
            • Organize-symbols-by-name
            • Good-valuep
            • Symbol-package-name-non-cl
            • Symbol-package-name-lst
            • Mbt$
            • Good-pseudo-termp
            • Maybe-string-fix
            • Std/basic/if*
              • Std/basic/member-symbol-name
            • Std/strings-extensions
            • Std/system-extensions
          • Helpers
          • Htclient
          • Typed-lists-light
          • Arithmetic-light
        • X86isa
        • Axe
        • Execloader
      • Math
      • Testing-utilities
    • Std/basic-extensions
    • Std/basic

    Std/basic/if*

    Rules about if*.

    These rules are unrelated to the special status of if* in BDD reasoning. These rules are useful when if* is used as a more controllable version of the built-in if, e.g. so that ACL2 does not do unwanted case splits.

    Definitions and Theorems

    Theorem: if*-when-true

    (defthm if*-when-true
      (implies a (equal (if* a b c) b)))

    Theorem: if*-when-false

    (defthm if*-when-false
      (implies (not a) (equal (if* a b c) c)))

    Theorem: if*-when-same

    (defthm if*-when-same
      (equal (if* a b b) b))