Quellcodebibliothek Statistik Leitseite products/Sources/formale Sprachen/Isabelle/Archive-of-Formal-Proofs/thys/FOL_Seq_Calc2/   (Sammlung formaler Beweise Version 2026-5©)  Datei vom 29.4.2026 mit Größe 2 kB image not shown  

Quelle  Export.thy

  Sprache: Isabelle
 

section Export

theory Export
  imports Prover
begin

text In this theory, we make the prover executable using the code interpretation of the abstract
  framework and the Isabelle to Haskell code generator.


text To actually execute the prover, we need to lazily evaluate the stream of rules to apply.
 , we will never actually get to a result.

code_lazy_type stream

text We would also like to make the evaluation of streams a bit more efficient.
declare Stream.smember_code [code del]
lemma [code]: "Stream.smember x (y ## s) = (x = y Stream.smember x s)"
  unfolding Stream.smember_def by auto

text To export code to Haskell, we need to specify that functions on the option type should be
 exported into the equivalent functions on the Maybe monad.

code_printing
  constant the  (Haskell) "MaybeExt.fromJust"
| constant Option.is_none  (Haskell) "MaybeExt.isNothing"

text To use the Maybe monad, we need to import it, so we add a shim to do so in every module.
code_printing code_module MaybeExt  (Haskell)
  module MaybeExt(fromJust, isNothing) where
 import Data.Maybe(fromJust, isNothing);


text The default export setup will create a cycle of module imports, so we roll most of the
 theories into one module when exporting to Haskell to prevent this.

code_identifier
  code_module Stream  (Haskell) Prover
code_module Prover  (Haskell) Prover
code_module Export  (Haskell) Prover
code_module Option  (Haskell) Prover
code_module MaybeExt  (Haskell) Prover
code_module Abstract_Completeness  (Haskell) Prover

text Finally, we define an executable version of the prover using the code interpretation from the
 framework, and a version where the list of terms is initially empty.

definition secavTreeCode i.mkTree (λr s. Some (effect r s)) rules
definition secavProverCode λz . secavTreeCode ([], z)

text We then export this version of the prover into Haskell.
export_code open secavProverCode in Haskell

end

Messung V0.5 in Prozent
C=63 H=100 G=83

¤ Dauer der Verarbeitung: 0.1 Sekunden  (vorverarbeitet am  2026-06-10) ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

Beweissystem der NASA

Beweissystem Isabelle

NIST Cobol Testsuite

Cephes Mathematical Library

Wiener Entwicklungsmethode

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.