* src/ta/Makefile.am, src/ta/taexplicit.cc, src/ta/taexplicit.hh, src/ta/taproduct.cc, src/ta/tgbta.cc, src/ta/tgbta.hh, src/ta/tgbtaexplicit.cc, src/ta/tgbtaexplicit.hh, src/ta/tgbtaproduct.cc, src/ta/tgbtaproduct.hh, src/taalgos/emptinessta.cc, src/taalgos/emptinessta.hh, src/taalgos/sba2ta.cc, src/taalgos/tgba2ta.cc, src/taalgos/tgba2ta.hh, src/tgbatest/ltl2tgba.cc: Implementation of TGTA, a new kind of automata combining ideas from TGBA and TA.
110 lines
2.8 KiB
C++
110 lines
2.8 KiB
C++
// Copyright (C) 2011 Laboratoire de Recherche et Développement
|
|
// de l'Epita (LRDE).
|
|
// Copyright (C) 2003, 2004, 2006 Laboratoire d'Informatique de Paris
|
|
// 6 (LIP6), département Systèmes Répartis Coopératifs (SRC),
|
|
// Université Pierre et Marie Curie.
|
|
//
|
|
// This file is part of Spot, a model checking library.
|
|
//
|
|
// Spot is free software; you can redistribute it and/or modify it
|
|
// under the terms of the GNU General Public License as published by
|
|
// the Free Software Foundation; either version 2 of the License, or
|
|
// (at your option) any later version.
|
|
//
|
|
// Spot is distributed in the hope that it will be useful, but WITHOUT
|
|
// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
|
|
// or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
|
|
// License for more details.
|
|
//
|
|
// You should have received a copy of the GNU General Public License
|
|
// along with Spot; see the file COPYING. If not, write to the Free
|
|
// Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
|
// 02111-1307, USA.
|
|
|
|
#ifndef SPOT_TGBTA_TGBAPRODUCT_HH
|
|
# define SPOT_TGBTA_TGBAPRODUCT_HH
|
|
|
|
#include "tgba/tgba.hh"
|
|
#include "tgba/tgbaproduct.hh"
|
|
#include "misc/fixpool.hh"
|
|
#include "kripke/kripke.hh"
|
|
#include "tgbta.hh"
|
|
|
|
namespace spot
|
|
{
|
|
|
|
/// \brief A lazy product. (States are computed on the fly.)
|
|
class tgbta_product : public tgba_product
|
|
{
|
|
public:
|
|
|
|
tgbta_product(const kripke* left, const tgbta* right);
|
|
|
|
virtual state*
|
|
get_init_state() const;
|
|
|
|
virtual tgba_succ_iterator*
|
|
succ_iter(const state* local_state, const state* global_state = 0,
|
|
const tgba* global_automaton = 0) const;
|
|
|
|
|
|
};
|
|
|
|
/// \brief Iterate over the successors of a product computed on the fly.
|
|
class tgbta_succ_iterator_product : public tgba_succ_iterator
|
|
{
|
|
public:
|
|
tgbta_succ_iterator_product(const state_product* s, const kripke* k, const tgbta* tgbta, fixed_size_pool* pool);
|
|
|
|
virtual
|
|
~tgbta_succ_iterator_product();
|
|
|
|
// iteration
|
|
void
|
|
first();
|
|
void
|
|
next();
|
|
bool
|
|
done() const;
|
|
|
|
// inspection
|
|
state_product*
|
|
current_state() const;
|
|
bdd
|
|
current_condition() const;
|
|
|
|
bdd
|
|
current_acceptance_conditions() const;
|
|
|
|
private:
|
|
//@{
|
|
/// Internal routines to advance to the next successor.
|
|
void
|
|
step_();
|
|
void
|
|
find_next_succ_();
|
|
|
|
void
|
|
next_kripke_dest();
|
|
|
|
//@}
|
|
|
|
protected:
|
|
const state_product* source_;
|
|
const tgbta* tgbta_;
|
|
const kripke* kripke_;
|
|
fixed_size_pool* pool_;
|
|
tgba_succ_iterator* tgbta_succ_it_;
|
|
tgba_succ_iterator* kripke_succ_it_;
|
|
state_product* current_state_;
|
|
bdd current_condition_;
|
|
bdd current_acceptance_conditions_;
|
|
bdd kripke_source_condition;
|
|
state * kripke_current_dest_state;
|
|
|
|
|
|
};
|
|
|
|
}
|
|
|
|
#endif // SPOT_TGBTA_TGBAPRODUCT_HH
|