at.jku.risc.stout.urauc.algo
public class AntiUnifyProblem extends Object implements Equation, Cloneable
Modifier and Type | Class and Description |
---|---|
class |
AntiUnifyProblem.CommutativeArrangementIter |
static class |
AntiUnifyProblem.VariableWithHedges |
Modifier and Type | Field and Description |
---|---|
static String |
PRINT_EQ_SEPARATOR |
static String |
PRINT_SYS_SEPARATOR |
static String |
PRINT_VAR_SEPARATOR |
Constructor and Description |
---|
AntiUnifyProblem()
Obtain an empty AUP with fresh generalization variables.
|
AntiUnifyProblem(Hedge left,
Hedge right,
Alignment alignment)
Create an AUP with fresh generalization variables and the given hedges.
|
Modifier and Type | Method and Description |
---|---|
void |
addLeft(TermNode left)
Adds a TermNode to the left hedge of the equation.
|
void |
addRight(TermNode right)
Adds a TermNode to the right hedge of the equation.
|
AntiUnifyProblem |
clone() |
Hedge |
createMostGeneral() |
Alignment |
getAlignment() |
AntiUnifyProblem.VariableWithHedges |
getHorizontalPartX()
Returns the horizontal abstraction of this AUP.
|
HedgeVar |
getHorizontalVarX()
Returns the hedge generalization variable, which is used for horizontal
abstraction.
|
Hedge |
getLeft()
Returns the left hedge of this AUP.
|
Hedge |
getRight()
Returns the right hedge of this AUP.
|
AntiUnifyProblem.VariableWithHedges |
getVerticalPartC()
Returns the vertical abstraction of this AUP.
|
ContextVar |
getVerticalVarC()
Returns the context generalization variable, which is used for vertical
abstraction.
|
void |
init()
This method is called automatically by the input parser after a new
equation has been created.
|
void |
initPositionIndexHorizontalPartX(int[] holeParentIndexLeft,
int[] holeParentIndexRight)
Initialize the position indexes of the hedge (horizontal sequence
getHorizontalPartX()) with the given hole position of the
context (getVerticalPartC()).
|
void |
initPositionIndexVerticalPartC()
Initialize the position indexes of the context (vertical sequence
getVerticalPartC()).
|
AntiUnifyProblem.CommutativeArrangementIter |
iteratorHorizontalPartX(boolean ignoreDisjointLeaves) |
AntiUnifyProblem.CommutativeArrangementIter |
iteratorVerticalPartC(boolean ignoreDisjointLeaves) |
void |
makeAssociative(Set<TermAtom> associativeSymbols)
Make some symbols and/or the root hedge commutative.
|
void |
makeCommutativ(Set<TermAtom> commutativeSymbols,
boolean commutativeRootHedge)
Make some symbols and/or the root hedge commutative.
|
Hedge |
newHedge(TermNode... nodes)
Creates a new hedge which is commutative iff
getHorizontalPartX().checkCommutative() is true.
|
void |
setAlignment(Alignment alignment) |
void |
setLeft(Hedge hedge)
Set the left hedge of this AUP.
|
void |
setRight(Hedge hedge)
Set the left hedge of this AUP.
|
String |
toString() |
public static String PRINT_EQ_SEPARATOR
public static String PRINT_SYS_SEPARATOR
public static String PRINT_VAR_SEPARATOR
public AntiUnifyProblem()
public void addLeft(TermNode left)
Equation
public void addRight(TermNode right)
Equation
public AntiUnifyProblem clone()
public Hedge createMostGeneral()
public Alignment getAlignment()
public AntiUnifyProblem.VariableWithHedges getHorizontalPartX()
public HedgeVar getHorizontalVarX()
public Hedge getLeft()
public Hedge getRight()
public AntiUnifyProblem.VariableWithHedges getVerticalPartC()
public ContextVar getVerticalVarC()
public void init()
Equation
public void initPositionIndexHorizontalPartX(int[] holeParentIndexLeft, int[] holeParentIndexRight)
public void initPositionIndexVerticalPartC()
public AntiUnifyProblem.CommutativeArrangementIter iteratorHorizontalPartX(boolean ignoreDisjointLeaves)
public AntiUnifyProblem.CommutativeArrangementIter iteratorVerticalPartC(boolean ignoreDisjointLeaves)
public void makeAssociative(Set<TermAtom> associativeSymbols)
public void makeCommutativ(Set<TermAtom> commutativeSymbols, boolean commutativeRootHedge)
public Hedge newHedge(TermNode... nodes)
public void setAlignment(Alignment alignment)
public void setLeft(Hedge hedge)
public void setRight(Hedge hedge)