• Top
    • Documentation
    • Books
      • Cert.pl
      • Community-books
      • Project-dir-alist
      • Bookdata
      • Book-hash
      • Uncertified-books
      • Sysfile
      • Show-books
      • Best-practices
        • Working-with-packages
        • Theory-management
        • Naming-rewrite-rules
        • Conventional-normal-forms
          • Where-do-i-place-my-book
          • File-names
          • File-extensions
          • Remove-whitespace
          • Finite-reasoning
        • Books-reference
        • Where-do-i-place-my-book
        • Books-tour
      • Recursion-and-induction
      • Boolean-reasoning
      • Projects
      • Debugging
      • Std
      • Proof-automation
      • Macro-libraries
      • ACL2
      • Interfacing-tools
      • Hardware-verification
      • Software-verification
      • Testing-utilities
      • Math
    • Best-practices

    Conventional-normal-forms

    Recommendations for respecting global conventions that the ACL2 books authors have agreed to.

    In many cases there are alternate normal forms that you can use for the same concept. For greater compatibility between libraries, we prefer to use various forms as described below.

    Disable mv-nth

    Recommendations:

    1. Write lemmas in terms of (mv-nth n ...) instead of (caddr ...)
    2. Include the tools/mv-nth book

    Rationale

    • It's important to have a standard here since multiply-valued functions are needed in many libraries.
    • Leaving mv-nth enabled is worse because it leads to different normal forms for slot 0 versus other slots. That is, ACL2 will rewrite (mv-nth 0 ...) to (car ...) but will not rewrite (mv-nth 1 ...) unless additional rewrite rules are added.
    • Writing theorems in terms of mv-nth is compatible with using b* bindings in theorems, which is particularly nice.

    BOZO Other important normal forms we should all agree on?

    Member versus Memberp?