org.uacalc.alg.conlat
Interface Partition

All Superinterfaces:
BinaryRelation, java.lang.Comparable, java.lang.Iterable<IntArray>
All Known Implementing Classes:
BasicPartition

public interface Partition
extends BinaryRelation

This interface specifies the basic operations for partitions on the set {0, 1, ..., n-1}. This also specifies that the partition should have a system of distinct representatives, an SDR.

Version:
$Id: Partition.java,v 1.6 2010/01/26 08:22:23 ralphfreese Exp $
Author:
Ralph Freese

Field Summary
static int BLOCK
          Printing types: blocks, the useual way of writing a partition.
static int EWK
          Printing types: the algebra program representtation: a comma separated sequence of ints defining a map whose kernel is the partition.
static int HUMAN
          Printing types: blocks, plus number of blocks at the end.
static int INTERNAL
          Printing types: the internal representation.
 
Method Summary
 int blockIndex(int i)
           
 int[][] getBlocks()
           
 boolean isRelated(int i, int j)
           
 boolean isRepresentative(int i)
           
 boolean isZero()
           
 Partition join(Partition part2)
           
 void joinBlocks(int r, int s)
          Note r and s must be roots and distinct.
 boolean leq(Partition part2)
           
 Partition meet(Partition part2)
           
 void normalize()
           
 int numberOfBlocks()
           
 int representative(int i)
           
 int[] representatives()
           
 int[] toArray()
          This returns the array representation of the partition as described in Ralph Freese's notes on partitions, see http://www.math.hawaii.edu/~ralph/Notes/.
 java.lang.String toString(int kind)
           
 int universeSize()
           
 
Methods inherited from interface org.uacalc.alg.conlat.BinaryRelation
getPairs
 
Methods inherited from interface java.lang.Iterable
iterator
 
Methods inherited from interface java.lang.Comparable
compareTo
 

Field Detail

INTERNAL

static final int INTERNAL
Printing types: the internal representation.

See Also:
Constant Field Values

EWK

static final int EWK
Printing types: the algebra program representtation: a comma separated sequence of ints defining a map whose kernel is the partition.

See Also:
Constant Field Values

BLOCK

static final int BLOCK
Printing types: blocks, the useual way of writing a partition.

See Also:
Constant Field Values

HUMAN

static final int HUMAN
Printing types: blocks, plus number of blocks at the end.

See Also:
Constant Field Values
Method Detail

toArray

int[] toArray()
This returns the array representation of the partition as described in Ralph Freese's notes on partitions, see http://www.math.hawaii.edu/~ralph/Notes/.


joinBlocks

void joinBlocks(int r,
                int s)
Note r and s must be roots and distinct.


join

Partition join(Partition part2)

meet

Partition meet(Partition part2)

leq

boolean leq(Partition part2)

normalize

void normalize()

universeSize

int universeSize()
Specified by:
universeSize in interface BinaryRelation

numberOfBlocks

int numberOfBlocks()

isRelated

boolean isRelated(int i,
                  int j)
Specified by:
isRelated in interface BinaryRelation

toString

java.lang.String toString(int kind)

representative

int representative(int i)

isRepresentative

boolean isRepresentative(int i)

representatives

int[] representatives()

blockIndex

int blockIndex(int i)

getBlocks

int[][] getBlocks()

isZero

boolean isZero()


Copyright 2003 Ralph Freese. All Rights Reserved.