dupexp, simulation: use tgba_digraph.

* src/tgbaalgos/dupexp.cc, src/tgbaalgos/dupexp.hh: Produce
a tgba_digraph instead of a tgba_explicit_number.
* src/tgbaalgos/simulation.cc: First pass to adjust to the use of
tgba_digraph as a return of tgba_dupexp_dfs() and tgba_dupexp_bfs().
Some maps have been replaced by vectors because states are indexed,
but more simplifications could be done.
This commit is contained in:
Alexandre Duret-Lutz 2014-04-02 22:03:50 +02:00
parent 1f70e6742d
commit 92eed08261
3 changed files with 169 additions and 175 deletions

View file

@ -1,6 +1,6 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2012, 2013 Laboratoire de Recherche et Développement
// de l'Epita (LRDE).
// Copyright (C) 2012, 2013, 2014 Laboratoire de Recherche et
// Développement de l'Epita (LRDE).
// Copyright (C) 2003, 2004, 2005 Laboratoire d'Informatique de Paris
// 6 (LIP6), département Systèmes Répartis Coopératifs (SRC),
// Université Pierre et Marie Curie.
@ -23,32 +23,32 @@
#ifndef SPOT_TGBAALGOS_DUPEXP_HH
# define SPOT_TGBAALGOS_DUPEXP_HH
# include "tgba/tgbaexplicit.hh"
# include "tgba/tgbagraph.hh"
namespace spot
{
/// \ingroup tgba_misc
/// \brief Build an explicit automata from all states of \a aut,
/// \brief Build an explicit automaton from all states of \a aut,
/// numbering states in bread first order as they are processed.
SPOT_API tgba_explicit_number*
SPOT_API tgba_digraph*
tgba_dupexp_bfs(const tgba* aut);
/// \ingroup tgba_misc
/// \brief Build an explicit automata from all states of \a aut,
/// \brief Build an explicit automaton from all states of \a aut,
/// numbering states in depth first order as they are processed.
SPOT_API tgba_explicit_number*
SPOT_API tgba_digraph*
tgba_dupexp_dfs(const tgba* aut);
/// \ingroup tgba_misc
/// \brief Build an explicit automata from all states of \a aut,
/// \brief Build an explicit automaton from all states of \a aut,
/// numbering states in bread first order as they are processed.
SPOT_API tgba_explicit_number*
SPOT_API tgba_digraph*
tgba_dupexp_bfs(const tgba* aut,
std::map<const state*, const state*,
state_ptr_less_than>& relation);
/// \ingroup tgba_misc
/// \brief Build an explicit automata from all states of \a aut,
/// numbering states in depth first order as they are processed.
SPOT_API tgba_explicit_number*
SPOT_API tgba_digraph*
tgba_dupexp_dfs(const tgba* aut,
std::map<const state*, const state*,
state_ptr_less_than>& relation);