• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
    • Debugging
    • Std
    • Community
    • 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
          • Atj
          • Aij
          • Language
            • Syntax
              • Grammar
              • Unicode-escapes
              • Unicode-input-char
              • Escape-sequence
              • Identifiers
              • Primitive-types
              • Reference-types
              • Keywords
              • Unicode-characters
              • Integer-literals
              • String-literals
              • Octal-digits
              • Hexadecimal-digits
              • Decimal-digits
              • Binary-digits
              • Character-literals
              • Null-literal
              • Floating-point-literals
                • Floating-point-literal
                  • Floating-point-literal-fix
                • Boolean-literals
                • Package-names
                • Literals
              • Semantics
          • Bitcoin
          • Ethereum
          • Yul
          • 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
    • Floating-point-literal

    Floating-point-literal-fix

    Fixer for floating-point-literal.

    Signature
    (floating-point-literal-fix x) → fixed-x
    Arguments
    x — Guard (floating-point-literalp x).
    Returns
    fixed-x — Type (floating-point-literalp fixed-x).

    Definitions and Theorems

    Function: floating-point-literal-fix

    (defun floating-point-literal-fix (x)
      (declare (xargs :guard (floating-point-literalp x)))
      (mbe :logic
           (if (floating-point-literalp x)
               x
             (floating-point-literal-witness))
           :exec x))

    Theorem: floating-point-literalp-of-floating-point-literal-fix

    (defthm floating-point-literalp-of-floating-point-literal-fix
      (b* ((fixed-x (floating-point-literal-fix x)))
        (floating-point-literalp fixed-x))
      :rule-classes :rewrite)

    Theorem: floating-point-literal-fix-when-floating-point-literalp

    (defthm floating-point-literal-fix-when-floating-point-literalp
      (implies (floating-point-literalp x)
               (equal (floating-point-literal-fix x)
                      x)))