• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
    • Debugging
    • Std
    • Community
    • Proof-automation
    • ACL2
      • Theories
      • Rule-classes
      • Proof-builder
      • Recursion-and-induction
      • Hons-and-memoization
      • Events
      • Parallelism
      • History
      • Programming
      • Operational-semantics
      • Real
      • Start-here
      • Debugging
      • Miscellaneous
      • Output-controls
      • Macros
        • Make-event
        • Defmacro
        • Untranslate-patterns
        • Tc
        • Trans*
        • Macro-aliases-table
        • Macro-args
        • Defabbrev
        • User-defined-functions-table
        • Trans
        • Untranslate-for-execution
        • Add-macro-fn
        • Check-vars-not-free
        • Safe-mode
        • Macro-libraries
          • B*
          • Defunc
          • Fty
          • Apt
            • Simplify-defun
            • Isodata
            • Tailrec
            • Schemalg
            • Restrict
            • Expdata
            • Casesplit
            • Simplify-term
            • Simplify-defun-sk
            • Parteval
            • Solve
              • Solve-implementation
                • Solve-event-generation
                • Solve-fn
                  • Solve-input-processing
                  • Solve-macro-definition
                  • Solve-call-ACL2-rewriter
              • Wrap-output
              • Propagate-iso
              • Simplify
              • Finite-difference
              • Drop-irrelevant-params
              • Copy-function
              • Lift-iso
              • Rename-params
              • Utilities
              • Simplify-term-programmatic
              • Simplify-defun-sk-programmatic
              • Simplify-defun-programmatic
              • Simplify-defun+
              • Common-options
              • Common-concepts
            • Std/util
            • Defdata
            • Defrstobj
            • Seq
            • Match-tree
            • Defrstobj
            • With-supporters
            • Def-partial-measure
            • Template-subst
            • Soft
            • Defthm-domain
            • Event-macros
            • Def-universal-equiv
            • Def-saved-obligs
            • With-supporters-after
            • Definec
            • Sig
            • Outer-local
            • Data-structures
          • Trans1
          • Defmacro-untouchable
          • Set-duplicate-keys-action
          • Add-macro-alias
          • Magic-macroexpand
          • Defmacroq
          • Trans!
          • Remove-macro-fn
          • Remove-macro-alias
          • Add-binop
          • Untrans-table
          • Trans*-
          • Remove-binop
          • Tcp
          • Tca
        • Mailing-lists
        • Interfacing-tools
      • Macro-libraries
        • B*
        • Defunc
        • Fty
        • Apt
          • Simplify-defun
          • Isodata
          • Tailrec
          • Schemalg
          • Restrict
          • Expdata
          • Casesplit
          • Simplify-term
          • Simplify-defun-sk
          • Parteval
          • Solve
            • Solve-implementation
              • Solve-event-generation
              • Solve-fn
                • Solve-input-processing
                • Solve-macro-definition
                • Solve-call-ACL2-rewriter
            • Wrap-output
            • Propagate-iso
            • Simplify
            • Finite-difference
            • Drop-irrelevant-params
            • Copy-function
            • Lift-iso
            • Rename-params
            • Utilities
            • Simplify-term-programmatic
            • Simplify-defun-sk-programmatic
            • Simplify-defun-programmatic
            • Simplify-defun+
            • Common-options
            • Common-concepts
          • Std/util
          • Defdata
          • Defrstobj
          • Seq
          • Match-tree
          • Defrstobj
          • With-supporters
          • Def-partial-measure
          • Template-subst
          • Soft
          • Defthm-domain
          • Event-macros
          • Def-universal-equiv
          • Def-saved-obligs
          • With-supporters-after
          • Definec
          • Sig
          • Outer-local
          • Data-structures
        • Interfacing-tools
        • Hardware-verification
        • Software-verification
        • Math
        • Testing-utilities
      • Solve-implementation

      Solve-fn

      Check redundancy, process the inputs, and generate the event.

      Signature
      (solve-fn old method method? method-rules 
                solution-name solution-enable 
                solution-enable? solution-guard 
                solution-guard? solution-guard-hints 
                solution-guard-hints? 
                solution-body solution-body? 
                solution-hints solution-hints? 
                new-name new-enable old-if-new-name 
                old-if-new-name? old-if-new-enable 
                old-if-new-enable? verify-guards 
                print show-only call ctx state) 
       
        → 
      (mv erp event state)
      Arguments
      method? — Guard (booleanp method?).
      solution-enable? — Guard (booleanp solution-enable?).
      solution-guard? — Guard (booleanp solution-guard?).
      solution-guard-hints? — Guard (booleanp solution-guard-hints?).
      solution-body? — Guard (booleanp solution-body?).
      solution-hints? — Guard (booleanp solution-hints?).
      old-if-new-name? — Guard (booleanp old-if-new-name?).
      old-if-new-enable? — Guard (booleanp old-if-new-enable?).
      call — Guard (pseudo-event-formp call).
      Returns
      event — A pseudo-event-formp.

      Definitions and Theorems

      Function: solve-fn

      (defun solve-fn (old method method? method-rules
                           solution-name solution-enable
                           solution-enable? solution-guard
                           solution-guard? solution-guard-hints
                           solution-guard-hints?
                           solution-body solution-body?
                           solution-hints solution-hints?
                           new-name new-enable old-if-new-name
                           old-if-new-name? old-if-new-enable
                           old-if-new-enable? verify-guards
                           print show-only call ctx state)
       (declare (xargs :stobjs (state)))
       (declare (xargs :guard (and (booleanp method?)
                                   (booleanp solution-enable?)
                                   (booleanp solution-guard?)
                                   (booleanp solution-guard-hints?)
                                   (booleanp solution-body?)
                                   (booleanp solution-hints?)
                                   (booleanp old-if-new-name?)
                                   (booleanp old-if-new-enable?)
                                   (pseudo-event-formp call))))
       (let ((__function__ 'solve-fn))
         (declare (ignorable __function__))
         (b*
          ((encapsulate?
                (previous-transformation-expansion call (w state)))
           ((when encapsulate?)
            (b* (((run-when show-only)
                  (cw "~x0~|" encapsulate?)))
              (cw "~%The transformation ~x0 is redundant.~%"
                  call)
              (value '(value-triple :invisible))))
           ((er (list old ??f x1...xn matrix f f-existsp new
                      new-enable old-if-new old-if-new-enable
                      verify-guards names-to-avoid))
            (solve-process-inputs old method method? method-rules
                                  solution-name solution-enable
                                  solution-enable? solution-guard
                                  solution-guard? solution-guard-hints
                                  solution-guard-hints?
                                  solution-body solution-body?
                                  solution-hints solution-hints?
                                  new-name new-enable old-if-new-name
                                  old-if-new-name? old-if-new-enable
                                  old-if-new-enable? verify-guards
                                  print show-only ctx state))
           ((er event)
            (solve-gen-everything old ?f x1...xn matrix method
                                  method-rules f f-existsp solution-enable
                                  solution-guard solution-guard-hints
                                  solution-body solution-hints new
                                  new-enable old-if-new old-if-new-enable
                                  verify-guards print show-only
                                  call names-to-avoid ctx state)))
          (value event))))