• Top
    • Documentation
    • Books
    • Boolean-reasoning
      • Ipasir
      • Aignet
      • Aig
      • Satlink
        • Sat-solver-options
          • Unsat-checking
          • Check-config
            • Pigeon-hole
              • No-two-in-hole-aux
              • No-others-in-hole
              • Not-both-in-hole
              • No-two-in-any-hole
              • Every-bird-in-hole
              • No-two-in-hole
              • Bird-in-some-hole
                • Bird-in-hole
              • Simple-sat
              • Assert-unsat
              • Assert-sat
          • Config-p
          • Logical-story
          • Dimacs
          • Gather-benchmarks
          • Cnf
          • Satlink-extra-hook
          • Sat
        • Truth
        • Ubdds
        • Bdd
        • Faig
        • Bed
        • 4v
      • Projects
      • Debugging
      • Community
      • Std
      • Proof-automation
      • Macro-libraries
      • ACL2
      • Interfacing-tools
      • Hardware-verification
      • Software-verification
      • Math
      • Testing-utilities
    • Pigeon-hole

    Bird-in-some-hole

    Signature
    (bird-in-some-hole bird hole) → clause
    Arguments
    bird — Fixed.
        Guard (natp bird).
    hole — Counts down from max hole.
        Guard (natp hole).
    Returns
    clause — This bird is in some hole.
        Type (lit-listp clause).

    Definitions and Theorems

    Function: bird-in-some-hole

    (defun bird-in-some-hole (bird hole)
      (declare (xargs :guard (and (natp bird) (natp hole))))
      (let ((__function__ 'bird-in-some-hole))
        (declare (ignorable __function__))
        (b* (((when (zp hole)) nil)
             (hole (- hole 1)))
          (cons (bird-in-hole bird hole)
                (bird-in-some-hole bird hole)))))

    Theorem: lit-listp-of-bird-in-some-hole

    (defthm lit-listp-of-bird-in-some-hole
      (b* ((clause (bird-in-some-hole bird hole)))
        (lit-listp clause))
      :rule-classes :rewrite)