Interface Yutsis

All Superinterfaces:
java.lang.Cloneable, Graph
All Known Implementing Classes:
AbstractYutsis

public interface Yutsis
extends Graph

Interface of a (cubic) graph allowing the graph transformations used to reduce a Yutsis graph.

Author:
Dries.VanDyck@rug.ac.be
See Also:
Graph, YutsisGraph

Method Summary
 int[] bubble()
          Returns the first bubble encoutered, or {-1,-1} if no bubbles are present.
 java.lang.Object clone()
          Returns an exact copy of the object.
 void interchange(int[] nodes, int[] icnodes)
          Interchange on the edge (nodes[0], nodes[1]) interchanging the edges (nodes[0], icnodes[0]) and (nodes[1].
 void interchange(int node1, int node2, int icnode1, int icnode2)
          Interchange on the edge (node1, node2) interchanging the edges (node1, icnode1) and (node2, icnode2).
 void removeBubble(int[] bubble)
          Removes the bubble.
 void removeTriangle(int[] triangle)
          Removes the triangle triangle[0], triangle[1], triangle[2].
 void removeTriangle(int node1, int node2, int node3)
          Removes the triangle node1, node2, node3.
 int[] triangle()
          Returns the first triangle encoutered, or {-1,-1,-1} if no bubbles are present.
 int[][] triangles()
          Returns all triangles as an array of int [3] objects.
 boolean triangularDelta()
          True if the graph represents a triangular delta, false otherwise.
 boolean triangularDelta(int[] td)
          True if the graph represents a triangular delta between node td[0] and td[1], false otherwise.
 boolean triangularDelta(int node1, int node2)
          True if the graph represents a triangular delta between node node1 and node2, false otherwise.
 
Methods inherited from interface Graph
addChangeListener, connected, first, isRemoved, isTree, last, neighbors, nodeIterator, nrOfEdges, nrOfNodes, order, removeChangeListener, toGml
 

Method Detail

bubble

public int[] bubble()
Returns the first bubble encoutered, or {-1,-1} if no bubbles are present.

Returns:
the nodes of the bubble as an array or {-1,-1} if no bubbles are present

interchange

public void interchange(int[] nodes,
                        int[] icnodes)
Interchange on the edge (nodes[0], nodes[1]) interchanging the edges (nodes[0], icnodes[0]) and (nodes[1].

Parameters:
nodes - array containing the endpoints of the edge on which the interchange is performed
icnodes - array containing the neighbors of the corresponding nodes of nodes to be interchanged

interchange

public void interchange(int node1,
                        int node2,
                        int icnode1,
                        int icnode2)
Interchange on the edge (node1, node2) interchanging the edges (node1, icnode1) and (node2, icnode2).

Parameters:
node1 - first node of the edge on which the interchange is performed
node2 - second node of the edge on which the interchange is performed
icnode1 - neighbor of node1 to be interchanged with icnode2
icnode2 - neighbor of node2 to be interchanged with icnode1

removeBubble

public void removeBubble(int[] bubble)
Removes the bubble.

Parameters:
bubble - the bubble to be removed

removeTriangle

public void removeTriangle(int[] triangle)
Removes the triangle triangle[0], triangle[1], triangle[2].

Parameters:
triangle - array containing the nodes of the triangle to be removed

removeTriangle

public void removeTriangle(int node1,
                           int node2,
                           int node3)
Removes the triangle node1, node2, node3.

Parameters:
node1 - first node of the triangle to be removed
node2 - second node of the triangle to be removed
node3 - third node of the triangle to be removed

triangle

public int[] triangle()
Returns the first triangle encoutered, or {-1,-1,-1} if no bubbles are present.

Returns:
the nodes of the triangle as an array or {-1,-1,-1} if no triangle are present.

triangles

public int[][] triangles()
Returns all triangles as an array of int [3] objects.

Returns:
all triangles as an array of int [3] objects.

triangularDelta

public boolean triangularDelta()
True if the graph represents a triangular delta, false otherwise.

Returns:
true if this graph represents a triangular delta

triangularDelta

public boolean triangularDelta(int[] td)
True if the graph represents a triangular delta between node td[0] and td[1], false otherwise.

Parameters:
td - the nodes of the triangular delta as an array
Returns:
true if this Graph is a triangular delta between the specified nodes

triangularDelta

public boolean triangularDelta(int node1,
                               int node2)
True if the graph represents a triangular delta between node node1 and node2, false otherwise.

Parameters:
node1 - first node of the triangular delta to be formatted
node2 - second node of the triangular delta to be formatted
Returns:
true if this Graph is a triangular delta between the specified nodes

clone

public java.lang.Object clone()
Returns an exact copy of the object.

Overrides:
clone in class java.lang.Object
Returns:
a clone of this object