org: simplify babel blocks using #+PROPERTY: header-args

This feature is in Org 9, which is already required.

* doc/org/autcross.org, doc/org/autfilt.org, doc/org/compile.org,
doc/org/concepts.org, doc/org/csv.org, doc/org/dstar2tgba.org,
doc/org/genaut.org, doc/org/genltl.org, doc/org/hierarchy.org,
doc/org/hoa.org, doc/org/ioltl.org, doc/org/ltl2tgba.org,
doc/org/ltl2tgta.org, doc/org/ltlcross.org, doc/org/ltldo.org,
doc/org/ltlfilt.org, doc/org/ltlgrind.org, doc/org/ltlsynt.org,
doc/org/oaut.org, doc/org/randaut.org, doc/org/randltl.org,
doc/org/satmin.org, doc/org/setup.org, doc/org/tools.org,
doc/org/tut01.org, doc/org/tut02.org, doc/org/tut03.org,
doc/org/tut04.org, doc/org/tut10.org, doc/org/tut11.org,
doc/org/tut12.org, doc/org/tut20.org, doc/org/tut21.org,
doc/org/tut22.org, doc/org/tut23.org, doc/org/tut24.org,
doc/org/tut30.org, doc/org/tut31.org, doc/org/tut50.org,
doc/org/upgrade2.org: Simplify SRC block setups for sh, python and
C++.  Also fix a few typos and examples along the way.
This commit is contained in:
Alexandre Duret-Lutz 2019-04-16 21:03:13 +02:00
parent 0c8e6a38a8
commit 8a96828d85
40 changed files with 2193 additions and 2281 deletions

View file

@ -3,6 +3,7 @@
#+DESCRIPTION: Informal explanation of various concepts used in Spot.
#+INCLUDE: setup.org
#+HTML_LINK_UP: index.html
#+PROPERTY: header-args:sh :results verbatim :exports none
This page documents some of the concepts used in Spot, and whose
knowledge is usually assumed throughout the documentation. The
@ -128,7 +129,7 @@ For instance here is a Büchi automaton that accepts only words in
which $a$ is always true, and $b$ is true infinitely often.
#+NAME: buchi-example1
#+BEGIN_SRC sh :results verbatim :exports none
#+BEGIN_SRC sh
ltl2tgba 'G(a) & GF(b)' -B -d
#+END_SRC
@ -149,7 +150,7 @@ the [[#ltl][LTL formula]] =G(door_open -> light_on)= that specifies that
=light_on= should be true whenever =door_open= is true.
#+NAME: buchi-example2
#+BEGIN_SRC sh :results verbatim :exports none
#+BEGIN_SRC sh
ltl2tgba 'G(door_open -> light_on)' -d -C
#+END_SRC
@ -183,7 +184,7 @@ all runs in which at all point $a$ is true iff $b$ is true at the next
instant.
#+NAME: buchi-example3
#+BEGIN_SRC sh :results verbatim :exports none
#+BEGIN_SRC sh
ltl2tgba 'G(a <-> Xb)' -B -d
#+END_SRC
#+BEGIN_SRC dot :file concept-buchi3.svg :var txt=buchi-example3 :exports results
@ -210,7 +211,7 @@ have been aggregated in an edge.
Here is a simple example:
#+NAME: te1
#+BEGIN_SRC sh :results verbatim :exports none
#+BEGIN_SRC sh
cat >concept-te.hoa <<EOF
HOA: v1
Acceptance: 0 t
@ -232,7 +233,7 @@ $txt
[[file:concept-te1.svg]]
#+NAME: size
#+BEGIN_SRC sh :exports none
#+BEGIN_SRC sh
autfilt --merge --stats=$arg concept-te.hoa
#+END_SRC
@ -243,7 +244,7 @@ This is because those formula-labeled edges actually simplify the
following transition structure:
#+NAME: te2
#+BEGIN_SRC sh :results verbatim :exports none
#+BEGIN_SRC sh
autfilt concept-te.hoa -d.A
#+END_SRC
#+BEGIN_SRC dot :file concept-te2.svg :var txt=te2 :exports results
@ -296,7 +297,7 @@ states labeled with ❶ belong to set 1. Here each acceptance set
contains a single state.
#+NAME: gen-buchi-example1
#+BEGIN_SRC sh :results verbatim :exports none
#+BEGIN_SRC sh
ltl2tgba 'GFa & GFb' | autfilt -S --sat-minimize -d
#+END_SRC
@ -317,7 +318,7 @@ following automaton has the same language as the previous one (despite
its more complex look).
#+NAME: gen-buchi-example2
#+BEGIN_SRC sh :results verbatim :exports none
#+BEGIN_SRC sh
ltl2tgba 'GFa & GFb' -S -d
#+END_SRC
@ -337,7 +338,7 @@ with a 2-state generalized-Büchi automaton, but the smallest
equivalent Büchi automaton has three state:
#+NAME: gen-buchi-example-ba
#+BEGIN_SRC sh :results verbatim :exports none
#+BEGIN_SRC sh
ltl2tgba 'GFa & GFb' -B -d
#+END_SRC
@ -356,7 +357,7 @@ acceptance sets (as below). Spot's output routines have options for
both.
#+NAME: gen-buchi-example-ba2
#+BEGIN_SRC sh :results verbatim :exports none
#+BEGIN_SRC sh
ltl2tgba 'GFa & GFb' -B -d.b
#+END_SRC
@ -384,7 +385,7 @@ Here is an example of Transition-based Generalized Büchi Automaton
(TGBA).
#+NAME: tgba-example1
#+BEGIN_SRC sh :results verbatim :exports none
#+BEGIN_SRC sh
ltl2tgba 'GF(a & X(a U b))' -d
#+END_SRC
#+BEGIN_SRC dot :file concept-tgba1.svg :var txt=tgba-example1 :exports results
@ -403,7 +404,7 @@ The typical example is the LTL formula =GFa= (infinitely often $a$)
that can be represented using a one-state transition-based Büchi
automaton:
#+NAME: tgba-example2
#+BEGIN_SRC sh :results verbatim :exports none
#+BEGIN_SRC sh
ltl2tgba 'GFa' -d
#+END_SRC
#+BEGIN_SRC dot :file concept-tgba2.svg :var txt=tgba-example2 :exports results
@ -417,7 +418,7 @@ While the same property require a 2-state Büchi automaton using
state-based acceptance:
#+NAME: tgba-example3
#+BEGIN_SRC sh :results verbatim :exports none
#+BEGIN_SRC sh
ltl2tgba 'GFa' -B -d
#+END_SRC
#+BEGIN_SRC dot :file concept-tba-vs-ba.svg :var txt=tgba-example3 :exports results
@ -544,7 +545,7 @@ produced by =ltl2dstar= for the LTL formula =GFa | FGb=, but displayed
by Spot:
#+NAME: twa-example1
#+BEGIN_SRC sh :results verbatim :exports none
#+BEGIN_SRC sh
ltlfilt -l -f 'GFa | FGb' | ltl2dstar --output-format=hoa - - | autfilt --merge -d
#+END_SRC
#+BEGIN_SRC dot :file concept-twa1.svg :var txt=twa-example1 :exports results
@ -572,7 +573,7 @@ For instance the following alternating co-Büchi ω-automaton was
generated by [[https://sourceforge.net/projects/ltl3ba/][=ltl3ba 1.1.3=]] for the LTL formula =GF(a <-> Xb)=.
#+NAME: concepts-alt
#+BEGIN_SRC sh :results verbatim :exports none
#+BEGIN_SRC sh
autfilt -d.ba <<EOF
HOA: v1
States: 5
@ -635,7 +636,7 @@ alternating automata is the [[#hoa][HOA format, introduced below]].
infinitely often $p_1$). The graphical representation of that
automaton follows.
#+BEGIN_SRC sh :results verbatim :exports results
#+BEGIN_SRC sh :exports results
ltl2tgba -s 'p0 | GFp1' > tmp.$$
ltl2tgba -s6 'p0 | GFp1' | pr -w80 -m -t tmp.$$ -
rm tmp.$$
@ -665,7 +666,7 @@ accept_all: accept_all:
#+end_example
#+NAME: never-ex1
#+BEGIN_SRC sh :results verbatim :exports none
#+BEGIN_SRC sh
ltl2tgba -Bd 'p0 | GFp1'
#+END_SRC
#+BEGIN_SRC dot :file concept-never1.svg :var txt=never-ex1 :exports results
@ -697,7 +698,7 @@ LTL to (state-based) generalized Büchi automata, and then used by
For instance the Büchi automaton we used as an example for never
claims can be encoded as follows:
#+BEGIN_SRC sh :results verbatim :exports results
#+BEGIN_SRC sh :exports results
ltl2tgba --ba --lbtt 'p0 | GFp1'
#+END_SRC
@ -727,7 +728,7 @@ The format has been extended in two ways. First, LBTT extended it to
support transition-based acceptance. This is indicated by a =t= on
the first line:
#+BEGIN_SRC sh :results verbatim :exports results
#+BEGIN_SRC sh :exports results
ltl2tgba --lbtt 'p0 | GFp1'
#+END_SRC
@ -748,7 +749,7 @@ ltl2tgba --lbtt 'p0 | GFp1'
#+end_example
#+NAME: lbtt-ex2
#+BEGIN_SRC sh :results verbatim :exports none
#+BEGIN_SRC sh
ltl2tgba -d 'p0 | GFp1'
#+END_SRC
#+BEGIN_SRC dot :file concept-lbtt2.svg :var txt=lbtt-ex2 :exports results
@ -781,7 +782,7 @@ preferred. =ltl2dstar= can now also output HOA directly.
Here is one Rabin automaton in the DSTAR format:
#+BEGIN_SRC sh :results verbatim :exports results
#+BEGIN_SRC sh :exports results
echo '| F G p0 G F p1' | ltl2dstar --output-format=native - -
#+END_SRC
@ -821,7 +822,7 @@ Acc-Sig: +0 +1
#+end_example
#+NAME: dstar-example1
#+BEGIN_SRC sh :results verbatim :exports none
#+BEGIN_SRC sh
echo '| F G p0 G F p1' | ltl2dstar --output-format=native - - | autfilt -d
#+END_SRC
#+BEGIN_SRC dot :file concept-dstar.svg :var txt=dstar-example1 :exports results
@ -840,7 +841,7 @@ The [[http://adl.github.io/hoaf/][HOA format]] inherits several features from th
extends it in many ways, including support for non-deterministic
automata, alternating automata, and for arbitrary acceptance conditions.
#+BEGIN_SRC sh :results verbatim :exports results
#+BEGIN_SRC sh :exports results
ltldo ltl2dstar -f 'FGp0 | GFp1' --name=%f
#+END_SRC
@ -880,7 +881,7 @@ State: 3 {1 3}
#+end_example
#+NAME: hoa1
#+BEGIN_SRC sh :results verbatim :exports none
#+BEGIN_SRC sh
ltldo ltl2dstar -f 'FGp0 | GFp1' -d
#+END_SRC
#+BEGIN_SRC dot :file concept-hoa.svg :var txt=hoa1 :exports results
@ -994,7 +995,7 @@ automaton can then be simplified using several algorithms depending on what opti
Here is for instance a translation of ={(1;1)[*]}[]->a= discussed [[#psl][above]].
#+NAME: ltl2tgba1
#+BEGIN_SRC sh :results verbatim :exports code
#+BEGIN_SRC sh :exports code
ltl2tgba '{(1;1)[*]}[]->a' -d
#+END_SRC
#+BEGIN_SRC dot :file concept-ltl2tgba.svg :var txt=ltl2tgba1 :exports results