1. Creation
Permutation | permutation_name(int n) |
Permutation<Item> permutation_name(Set s) | |
Permutation<Item,Structure> permutation_name(Set s) |
2. Operations
Permutation& | random () |
int | rank () |
Permutation& | unrank (int m) |
Permutation& | next () |
Permutation& | previous() |
Permutation& | first () |
Permutation& | last () |
void | display () |
Bool operator==(Permutation& p) | |
Bool operator>(Permutation& p) | |
Bool operator>=(Permutation& p) | |
Bool operator<(Permutation& p) | |
Bool operator<=(Permutation& p) | |
Bool operator!=(Permutation& p) |
friend istream& | operator>> (istream& s,Permutation p) |
friend ostream& | operator<< (ostream& s,Permutation p) |
Permutation& operator=(Permutation p) | |
Permutation& copy(Permutation p) |
Type | operator[] (int i) |
int | size () |
Permutation objects can be used to obtain permutation of typed
objects like vertices and edges as follows. The class SetFuncs,
provides the necessary interface. Note that several of the methods
in this class produces results of exponential in the size of the
input.
Set<Sequence<Item> > | SetFuncs<Item>::cartesianProduct (const Set<Item>&s, const Set<Item>&s2); |
Set<Sequence<Item> > | SetFuncs<Item>::cartesianProduct (const Set<Item>&s1, const Set<Item>&s2) |
Set<Set<Item> > | SetFuncs<Item>::choose (const Set<Item>&s, int k) |
Set<Set<Item> > | SetFuncs<Item>::powerSet (const Set<Item>&s) |
Sequence<Item> | SetFuncs<Item>::permutation (const Set<Item>&s, const Permutation& p); |
Sequence<Item> | SetFuncs<Item>::permutation (const Array<Item>&a, const Permutation& p); |
Set<Sequence<Item> > | SetFuncs<Item>::permutations (const Set<Item>&a); |