de.ls5.jlearn.util
Class AutomatonUtil

java.lang.Object
  extended by de.ls5.jlearn.util.AutomatonUtil

public class AutomatonUtil
extends Object

Author:
fh

Constructor Summary
AutomatonUtil()
           
 
Method Summary
static Automaton arraysToAutomaton(int[] transitions, int[] outputs, int sigma)
           
static int[] automatonToOutputArray(Automaton a)
           
static int[] automatonToTransitionArray(Automaton a)
           
static Automaton convertSymbolsToStrings(Automaton a)
           
static Word findCounterexample(Automaton a1, Automaton a2)
          will minimize the automata first
static Word findCounterexample(Automaton a1, Automaton a2, boolean minimize)
           
static Word findDistinguishingSuffix(Automaton a, State s1, State s2)
          Deprecated. 
static Word findDistinguishingSuffix(Automaton m, Word p1, Word p2)
          Deprecated. 
static Set<Word> getCharacterizingSet(Automaton a)
           
static Automaton getCopyWithoutTransitions(Automaton aut, Set<Symbol> forbiddentransitions)
           
static Automaton getCopyWithRestrictedAlphabet(Automaton aut, Alphabet alpha)
          Create a copy of an Automaton that only contains Symbols present in the specified Alphabet
static List<State> getStatesInBFSOrder(Automaton automaton)
          Applies a breadth-first search algorithm to retrieve all states reachable from the starting state.
static Automaton minimize(Automaton in)
          Deprecated. 
static boolean testEquivalence(Automaton t1, Automaton t2)
          will minimize the automata first
static boolean testEquivalence(Automaton t1, Automaton t2, boolean minimize)
           
static Word testEquivalenceLinear(Automaton m1, Automaton m2)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AutomatonUtil

public AutomatonUtil()
Method Detail

testEquivalence

public static boolean testEquivalence(Automaton t1,
                                      Automaton t2)
will minimize the automata first

Parameters:
t1 -
t2 -
Returns:

testEquivalence

public static boolean testEquivalence(Automaton t1,
                                      Automaton t2,
                                      boolean minimize)
Parameters:
t1 -
t2 -
Returns:

findCounterexample

public static Word findCounterexample(Automaton a1,
                                      Automaton a2)
will minimize the automata first

Parameters:
a1 -
a2 -
Returns:

findCounterexample

public static Word findCounterexample(Automaton a1,
                                      Automaton a2,
                                      boolean minimize)
Returns:

findDistinguishingSuffix

@Deprecated
public static Word findDistinguishingSuffix(Automaton m,
                                                       Word p1,
                                                       Word p2)
Deprecated. 

Parameters:
m -
p1 -
p2 -
Returns:

minimize

@Deprecated
public static Automaton minimize(Automaton in)
Deprecated. 

minimization for abritrary automata INEFFICIENT IMPLEMENTATION !!!! please use AutomatonMinimizer.minimize()

Parameters:
in -
Returns:

automatonToOutputArray

public static int[] automatonToOutputArray(Automaton a)

automatonToTransitionArray

public static int[] automatonToTransitionArray(Automaton a)

arraysToAutomaton

public static Automaton arraysToAutomaton(int[] transitions,
                                          int[] outputs,
                                          int sigma)

getCharacterizingSet

public static Set<Word> getCharacterizingSet(Automaton a)

getStatesInBFSOrder

public static List<State> getStatesInBFSOrder(Automaton automaton)
Applies a breadth-first search algorithm to retrieve all states reachable from the starting state.


findDistinguishingSuffix

@Deprecated
public static Word findDistinguishingSuffix(Automaton a,
                                                       State s1,
                                                       State s2)
Deprecated. 


convertSymbolsToStrings

public static Automaton convertSymbolsToStrings(Automaton a)

getCopyWithRestrictedAlphabet

public static Automaton getCopyWithRestrictedAlphabet(Automaton aut,
                                                      Alphabet alpha)
Create a copy of an Automaton that only contains Symbols present in the specified Alphabet

Parameters:
aut - Automaton to make a copy of
alpha - The Alphabet to consider
Returns:
copy of the Automaton restricted to the provided Alphabet

getCopyWithoutTransitions

public static Automaton getCopyWithoutTransitions(Automaton aut,
                                                  Set<Symbol> forbiddentransitions)

testEquivalenceLinear

public static Word testEquivalenceLinear(Automaton m1,
                                         Automaton m2)


Copyright © 2011. All Rights Reserved.