• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
      • Apt
      • Zfc
      • Acre
      • Milawa
      • Smtlink
        • Z3-installation
        • Smt-hint
        • Tutorial
        • Status
        • Developer
          • Verified
            • Uninterpreted-fn-cp
            • Smt-hint-interface
            • Function-expansion
            • Smt-config
            • Fty-support
            • Smt-computed-hints
            • Add-hypo-cp
            • Smt-hint-please
            • Type-extract-cp
            • Smt-extract
            • Smtlink-process-user-hint
              • Process-smtlink-hints
              • Function-syntax
              • Smtlink-hint-syntax
              • Argument-lst-syntax
              • Hypothesis-lst-syntax
                • Hypothesis-syntax-p
                • Hypothesis-lst-syntax-p
                • Hypothesis-lst-syntax-fix
                • Hypothesis-syntax-fix
              • Translate-cmp-smtlink
              • Process-hint-clause-processor
              • Smt-solver-params
              • Hints-syntax
              • True-set-equiv-relation
            • Smt-basics
            • Smt-type-hyp
            • Smt-magic-fix
          • Trusted
      • 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
      • Solidity
      • Paco
      • Concurrent-programs
      • Bls12-377-curves
    • Debugging
    • Std
    • Proof-automation
    • Macro-libraries
    • ACL2
    • Interfacing-tools
    • Hardware-verification
    • Software-verification
    • Math
    • Testing-utilities
  • Smtlink-process-user-hint

Hypothesis-lst-syntax

Definitions and Theorems

Function: hypothesis-syntax-p

(defun hypothesis-syntax-p (term)
  (declare (xargs :guard t))
  (let ((acl2::__function__ 'hypothesis-syntax-p))
    (declare (ignorable acl2::__function__))
    (or (and (atom term) (equal term nil))
        (and (true-listp term)
             (car term)
             (not (cdr term))
             (pseudo-termp (car term)))
        (and (true-listp term)
             (car term)
             (cadr term)
             (not (cdddr term))
             (pseudo-termp (car term))
             (equal (cadr term) ':hints)
             (hints-syntax-p (caddr term))))))

Theorem: booleanp-of-hypothesis-syntax-p

(defthm booleanp-of-hypothesis-syntax-p
  (b* ((syntax-good? (hypothesis-syntax-p term)))
    (booleanp syntax-good?))
  :rule-classes :rewrite)

Theorem: true-listp-of-caddr

(defthm true-listp-of-caddr
  (implies (and (consp term)
                (consp (cdr term))
                (true-listp (cddr term))
                (equal (+ 2 (len (cddr term))) 3)
                (pseudo-termp (car term))
                (equal (cadr term) :hints)
                (hints-syntax-p (caddr term)))
           (true-listp (caddr term))))

Function: hypothesis-syntax-fix

(defun hypothesis-syntax-fix (term)
  (declare (xargs :guard (hypothesis-syntax-p term)))
  (let ((acl2::__function__ 'hypothesis-syntax-fix))
    (declare (ignorable acl2::__function__))
    (mbe :logic (if (hypothesis-syntax-p term) term nil)
         :exec term)))

Theorem: hypothesis-syntax-p-of-hypothesis-syntax-fix

(defthm hypothesis-syntax-p-of-hypothesis-syntax-fix
  (b* ((fixed-term (hypothesis-syntax-fix term)))
    (hypothesis-syntax-p fixed-term))
  :rule-classes :rewrite)

Function: hypothesis-syntax-equiv$inline

(defun hypothesis-syntax-equiv$inline (acl2::x acl2::y)
  (declare (xargs :guard (and (hypothesis-syntax-p acl2::x)
                              (hypothesis-syntax-p acl2::y))))
  (equal (hypothesis-syntax-fix acl2::x)
         (hypothesis-syntax-fix acl2::y)))

Theorem: hypothesis-syntax-equiv-is-an-equivalence

(defthm hypothesis-syntax-equiv-is-an-equivalence
  (and (booleanp (hypothesis-syntax-equiv x y))
       (hypothesis-syntax-equiv x x)
       (implies (hypothesis-syntax-equiv x y)
                (hypothesis-syntax-equiv y x))
       (implies (and (hypothesis-syntax-equiv x y)
                     (hypothesis-syntax-equiv y z))
                (hypothesis-syntax-equiv x z)))
  :rule-classes (:equivalence))

Theorem: hypothesis-syntax-equiv-implies-equal-hypothesis-syntax-fix-1

(defthm
      hypothesis-syntax-equiv-implies-equal-hypothesis-syntax-fix-1
  (implies (hypothesis-syntax-equiv acl2::x x-equiv)
           (equal (hypothesis-syntax-fix acl2::x)
                  (hypothesis-syntax-fix x-equiv)))
  :rule-classes (:congruence))

Theorem: hypothesis-syntax-fix-under-hypothesis-syntax-equiv

(defthm hypothesis-syntax-fix-under-hypothesis-syntax-equiv
  (hypothesis-syntax-equiv (hypothesis-syntax-fix acl2::x)
                           acl2::x)
  :rule-classes (:rewrite :rewrite-quoted-constant))

Theorem: equal-of-hypothesis-syntax-fix-1-forward-to-hypothesis-syntax-equiv

(defthm
 equal-of-hypothesis-syntax-fix-1-forward-to-hypothesis-syntax-equiv
 (implies (equal (hypothesis-syntax-fix acl2::x)
                 acl2::y)
          (hypothesis-syntax-equiv acl2::x acl2::y))
 :rule-classes :forward-chaining)

Theorem: equal-of-hypothesis-syntax-fix-2-forward-to-hypothesis-syntax-equiv

(defthm
 equal-of-hypothesis-syntax-fix-2-forward-to-hypothesis-syntax-equiv
 (implies (equal acl2::x (hypothesis-syntax-fix acl2::y))
          (hypothesis-syntax-equiv acl2::x acl2::y))
 :rule-classes :forward-chaining)

Theorem: hypothesis-syntax-equiv-of-hypothesis-syntax-fix-1-forward

(defthm hypothesis-syntax-equiv-of-hypothesis-syntax-fix-1-forward
  (implies (hypothesis-syntax-equiv (hypothesis-syntax-fix acl2::x)
                                    acl2::y)
           (hypothesis-syntax-equiv acl2::x acl2::y))
  :rule-classes :forward-chaining)

Theorem: hypothesis-syntax-equiv-of-hypothesis-syntax-fix-2-forward

(defthm hypothesis-syntax-equiv-of-hypothesis-syntax-fix-2-forward
 (implies
   (hypothesis-syntax-equiv acl2::x (hypothesis-syntax-fix acl2::y))
   (hypothesis-syntax-equiv acl2::x acl2::y))
 :rule-classes :forward-chaining)

Function: hypothesis-lst-syntax-p

(defun hypothesis-lst-syntax-p (term)
  (declare (xargs :guard t))
  (let ((acl2::__function__ 'hypothesis-lst-syntax-p))
    (declare (ignorable acl2::__function__))
    (b* (((if (atom term)) (equal term nil))
         ((cons first rest) term))
      (and (hypothesis-syntax-p first)
           (hypothesis-lst-syntax-p rest)))))

Theorem: booleanp-of-hypothesis-lst-syntax-p

(defthm booleanp-of-hypothesis-lst-syntax-p
  (b* ((syntax-good? (hypothesis-lst-syntax-p term)))
    (booleanp syntax-good?))
  :rule-classes :rewrite)

Function: hypothesis-lst-syntax-fix

(defun hypothesis-lst-syntax-fix (term)
  (declare (xargs :guard (hypothesis-lst-syntax-p term)))
  (let ((acl2::__function__ 'hypothesis-lst-syntax-fix))
    (declare (ignorable acl2::__function__))
    (mbe :logic
         (if (consp term)
             (cons (hypothesis-syntax-fix (car term))
                   (hypothesis-lst-syntax-fix (cdr term)))
           nil)
         :exec term)))

Theorem: hypothesis-lst-syntax-p-of-hypothesis-lst-syntax-fix

(defthm hypothesis-lst-syntax-p-of-hypothesis-lst-syntax-fix
  (b* ((fixed-term (hypothesis-lst-syntax-fix term)))
    (hypothesis-lst-syntax-p fixed-term))
  :rule-classes :rewrite)

Function: hypothesis-lst-syntax-equiv$inline

(defun hypothesis-lst-syntax-equiv$inline (acl2::x acl2::y)
  (declare (xargs :guard (and (hypothesis-lst-syntax-p acl2::x)
                              (hypothesis-lst-syntax-p acl2::y))))
  (equal (hypothesis-lst-syntax-fix acl2::x)
         (hypothesis-lst-syntax-fix acl2::y)))

Theorem: hypothesis-lst-syntax-equiv-is-an-equivalence

(defthm hypothesis-lst-syntax-equiv-is-an-equivalence
  (and (booleanp (hypothesis-lst-syntax-equiv x y))
       (hypothesis-lst-syntax-equiv x x)
       (implies (hypothesis-lst-syntax-equiv x y)
                (hypothesis-lst-syntax-equiv y x))
       (implies (and (hypothesis-lst-syntax-equiv x y)
                     (hypothesis-lst-syntax-equiv y z))
                (hypothesis-lst-syntax-equiv x z)))
  :rule-classes (:equivalence))

Theorem: hypothesis-lst-syntax-equiv-implies-equal-hypothesis-lst-syntax-fix-1

(defthm
 hypothesis-lst-syntax-equiv-implies-equal-hypothesis-lst-syntax-fix-1
 (implies (hypothesis-lst-syntax-equiv acl2::x x-equiv)
          (equal (hypothesis-lst-syntax-fix acl2::x)
                 (hypothesis-lst-syntax-fix x-equiv)))
 :rule-classes (:congruence))

Theorem: hypothesis-lst-syntax-fix-under-hypothesis-lst-syntax-equiv

(defthm hypothesis-lst-syntax-fix-under-hypothesis-lst-syntax-equiv
  (hypothesis-lst-syntax-equiv (hypothesis-lst-syntax-fix acl2::x)
                               acl2::x)
  :rule-classes (:rewrite :rewrite-quoted-constant))

Theorem: equal-of-hypothesis-lst-syntax-fix-1-forward-to-hypothesis-lst-syntax-equiv

(defthm
 equal-of-hypothesis-lst-syntax-fix-1-forward-to-hypothesis-lst-syntax-equiv
 (implies (equal (hypothesis-lst-syntax-fix acl2::x)
                 acl2::y)
          (hypothesis-lst-syntax-equiv acl2::x acl2::y))
 :rule-classes :forward-chaining)

Theorem: equal-of-hypothesis-lst-syntax-fix-2-forward-to-hypothesis-lst-syntax-equiv

(defthm
 equal-of-hypothesis-lst-syntax-fix-2-forward-to-hypothesis-lst-syntax-equiv
 (implies (equal acl2::x
                 (hypothesis-lst-syntax-fix acl2::y))
          (hypothesis-lst-syntax-equiv acl2::x acl2::y))
 :rule-classes :forward-chaining)

Theorem: hypothesis-lst-syntax-equiv-of-hypothesis-lst-syntax-fix-1-forward

(defthm
 hypothesis-lst-syntax-equiv-of-hypothesis-lst-syntax-fix-1-forward
 (implies
    (hypothesis-lst-syntax-equiv (hypothesis-lst-syntax-fix acl2::x)
                                 acl2::y)
    (hypothesis-lst-syntax-equiv acl2::x acl2::y))
 :rule-classes :forward-chaining)

Theorem: hypothesis-lst-syntax-equiv-of-hypothesis-lst-syntax-fix-2-forward

(defthm
 hypothesis-lst-syntax-equiv-of-hypothesis-lst-syntax-fix-2-forward
 (implies
   (hypothesis-lst-syntax-equiv acl2::x
                                (hypothesis-lst-syntax-fix acl2::y))
   (hypothesis-lst-syntax-equiv acl2::x acl2::y))
 :rule-classes :forward-chaining)

Subtopics

Hypothesis-syntax-p
Recognizer for hypothesis-syntax.
Hypothesis-lst-syntax-p
Recognizer for hypothesis-lst-syntax.
Hypothesis-lst-syntax-fix
Fixing function for a hypothesis-lst-syntax-p.
Hypothesis-syntax-fix
Fixing function for a hypothesis-syntax-p.