learner
Class ObservationTable

java.lang.Object
  extended by learner.ObservationTable

public class ObservationTable
extends java.lang.Object

An observation table consists of sets of trees S and R which represents states and transitions, respectively, and a set of contexts C to tell the trees in S apart. The entry at position (c,t) in the table, where c is in C and t is in S or R, is 1 if c[t] is in the target language, and 0 otherwise.


Constructor Summary
ObservationTable(Teacher teacher)
          Creates a new observation table.
 
Method Summary
 boolean complete()
          Includes dag.getTransitions() with rows not matched by any state in the set of dag.getStates().
 Tree equivClass(Tree tree)
          Retrieves the representative tree for the equivalence class to which the input tree belongs.
 Tree extend(Tree context, Tree tree, boolean reference)
          Derives a new state & context, or a new transition, from a counterexample.
 FiniteTreeAutomata getFTA()
           
 void synthesize()
          Synthesizes a finite tree automata from the observation table.
 java.lang.String toString()
           
 void updateColumns(Tree context)
           
 void updateRows(Tree t)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ObservationTable

public ObservationTable(Teacher teacher)
Creates a new observation table.

Parameters:
teacher - the oracle to query
Method Detail

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

equivClass

public Tree equivClass(Tree tree)
Retrieves the representative tree for the equivalence class to which the input tree belongs.

Parameters:
teacher -
tree -
Returns:

synthesize

public void synthesize()
Synthesizes a finite tree automata from the observation table.


complete

public boolean complete()
Includes dag.getTransitions() with rows not matched by any state in the set of dag.getStates().


updateRows

public void updateRows(Tree t)

updateColumns

public void updateColumns(Tree context)

extend

public Tree extend(Tree context,
                   Tree tree,
                   boolean reference)
Derives a new state & context, or a new transition, from a counterexample.

Parameters:
context - The tree surrounding the current node in the counterexample
tree - the subtree rooted at the current node
Returns:
a tree in S if tree does not contain a new piece of information, null otherwise

getFTA

public FiniteTreeAutomata getFTA()