spot  2.16
ltl2tgba_fm.hh
1 // -*- coding: utf-8 -*-
2 // Copyright (C) by the Spot authors, see the AUTHORS file for details.
3 //
4 // This file is part of Spot, a model checking library.
5 //
6 // Spot is free software; you can redistribute it and/or modify it
7 // under the terms of the GNU General Public License as published by
8 // the Free Software Foundation; either version 3 of the License, or
9 // (at your option) any later version.
10 //
11 // Spot is distributed in the hope that it will be useful, but WITHOUT
12 // ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
13 // or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
14 // License for more details.
15 //
16 // You should have received a copy of the GNU General Public License
17 // along with this program. If not, see <http://www.gnu.org/licenses/>.
18 
19 #pragma once
20 
21 #include <spot/tl/formula.hh>
22 #include <spot/twa/twagraph.hh>
23 #include <spot/tl/apcollect.hh>
24 #include <spot/tl/simplify.hh>
25 #include <spot/twaalgos/powerset.hh>
26 
27 namespace spot
28 {
85  SPOT_API twa_graph_ptr
87  bool exprop = false, bool symb_merge = true,
88  bool branching_postponement = false,
89  bool fair_loop_approx = false,
90  const atomic_prop_set* unobs = nullptr,
91  tl_simplifier* simplifier = nullptr,
92  bool unambiguous = false,
93  const output_aborter* aborter = nullptr,
94  bool label_with_ltl = false,
95  bool force_obligation = false);
96 
99  struct SPOT_API fm_edge
100  {
101  bdd cond;
105  };
106 
114  struct SPOT_API fm_simple_edge
115  {
118  };
119 
164  class SPOT_API ltl_to_tgba_fm_otf final
165  {
166  public:
168  struct options
169  {
171  bool exprop = false;
173  bool symb_merge = true;
175  bool branching_postponement = false;
178  bool fair_loop_approx = false;
180  bool unambiguous = false;
182  bool force_obligation = false;
183  options() {}
184  };
185 
199  options opts = options(),
200  tl_simplifier* simplifier = nullptr,
201  const atomic_prop_set* unobs = nullptr);
202 
204 
205  // Non-copyable, non-movable.
206  ltl_to_tgba_fm_otf(const ltl_to_tgba_fm_otf&) = delete;
207  ltl_to_tgba_fm_otf& operator=(const ltl_to_tgba_fm_otf&) = delete;
208 
209  // ---- State interface ----
210 
213 
218 
219  // ---- Symbolic successor view ----
220 
233 
234  // ---- Explicit successor view ----
235 
248  std::vector<fm_edge> succ_as_edges(formula s);
249 
269  std::vector<fm_simple_edge> succ_as_acc_and_dest(formula s);
270 
271  // ---- Accessors for interpreting succ_as_bdd() results ----
272 
274  const bdd& var_set() const;
275 
277  const bdd& next_set() const;
278 
280  const bdd& a_set() const;
281 
284 
287 
291 
293  const bdd_dict_ptr& get_dict() const;
294 
295  private:
296  struct impl;
297  std::unique_ptr<impl> impl_;
298  };
299 
300 }
Main class for temporal logic formula.
Definition: formula.hh:847
On-the-fly LTL→TGBA explorer.
Definition: ltl2tgba_fm.hh:165
acc_cond::mark_t bdd_to_mark(bdd a) const
Convert a cube over a_set() into acceptance marks.
std::vector< fm_edge > succ_as_edges(formula s)
formula init_state() const
The initial formula-state (canonicalized if symb_merge is on).
const bdd & next_set() const
Variable set: Next variables (destination encoding).
formula conj_bdd_to_formula(bdd cube) const
Convert a cube over next_set() into a formula.
bdd succ_as_bdd(formula s)
const bdd & var_set() const
Variable set: atomic propositions.
ltl_to_tgba_fm_otf(formula f, twa_graph_ptr aut, options opts=options(), tl_simplifier *simplifier=nullptr, const atomic_prop_set *unobs=nullptr)
Constructor.
std::vector< fm_simple_edge > succ_as_acc_and_dest(formula s)
Decompose the successors of s into edges without conditions.
const bdd & a_set() const
Variable set: acceptance promises.
const bdd_dict_ptr & get_dict() const
The BDD dictionary.
int register_next_variable(formula f)
formula orig_formula() const
Helper object to specify when an algorithm should abort its construction.
Definition: powerset.hh:50
Rewrite or simplify f in various ways.
Definition: simplify.hh:145
LTL/PSL formula interface.
std::set< formula > atomic_prop_set
Set of atomic propositions.
Definition: apcollect.hh:34
std::shared_ptr< bdd_dict > bdd_dict_ptr
Shared pointer to a bdd_dict.
Definition: bdddict.hh:304
twa_graph_ptr ltl_to_tgba_fm(formula f, const bdd_dict_ptr &dict, bool exprop=false, bool symb_merge=true, bool branching_postponement=false, bool fair_loop_approx=false, const atomic_prop_set *unobs=nullptr, tl_simplifier *simplifier=nullptr, bool unambiguous=false, const output_aborter *aborter=nullptr, bool label_with_ltl=false, bool force_obligation=false)
Build a spot::twa_graph_ptr from an LTL or PSL formula.
std::shared_ptr< twa_graph > twa_graph_ptr
Shared pointer to a mutable twa_graph.
Definition: fwd.hh:44
unsigned * cube
A cube is only a set of bits in memory.
Definition: cube.hh:66
Definition: automata.hh:26
An acceptance mark.
Definition: acc.hh:76
A single successor edge from a formula-state.
Definition: ltl2tgba_fm.hh:100
formula dst
Destination formula-state.
Definition: ltl2tgba_fm.hh:102
bdd cond
Condition on atomic propositions.
Definition: ltl2tgba_fm.hh:101
acc_cond::mark_t acc
Definition: ltl2tgba_fm.hh:103
A simplified successor edge without condition.
Definition: ltl2tgba_fm.hh:115
formula dst
Destination formula-state.
Definition: ltl2tgba_fm.hh:117
acc_cond::mark_t acc
Acceptance marks, using negated-Inf semantics.
Definition: ltl2tgba_fm.hh:116
Bundle the boolean options for translation.
Definition: ltl2tgba_fm.hh:169

Please direct any question, comment, or bug report to the Spot mailing list at spot@lrde.epita.fr.
Generated on Fri Feb 27 2015 10:00:07 for spot by doxygen 1.9.1