The Original CHomP Software
|
Files | |
file | algstruct.h |
This file defines an algebraic data structure which is used to store the information about computed homology groups. | |
file | cubfiles.h |
This file defines various types of cubical sets whose homology can be computed by homology engines. | |
file | cubiset.h |
This file defines a very simple interface to manipulating a full cubical set represented as a bitmap for the purpose of homology computation. | |
file | engines.h |
This file defines several engines for the homology computation of cubical sets. | |
file | homology.h |
This file defines a top-level interface to a homology computation procedure of full cubical sets represented in terms of a bitmap. | |
Namespaces | |
namespace | chomp |
This namespace contains the entire CHomP library interface. | |
Classes | |
class | CubicalSet |
This class stores a full cubical set and implements some basic operations on such a set, like adding or removing cubes with given coordinates. More... | |
Functions | |
void | ComputeBettiNumbers (const CubicalSet &s, int *result, const char *engine=0, bool quiet=false) |
Computes the Betti numbers of a full cubical set represented by an object of the class "CubicalSet". More... | |
void | ComputeBettiNumbers (const void *buffer, int *sizes, int dim, int *result, const char *engine=0, const int *wrapping=0, bool quiet=false) |
Computes the Betti numbers of the given set of full cubes encoded in a binary bitmap. More... | |
CubicalSet::CubicalSet (const int *left_coords, const int *right_coords, int dim=EMBEDDING_DIM, const int *space_wrapping=0) | |
The only constructor allowed: Creates an empty cubical bitmap of the given size. More... | |
CubicalSet::~CubicalSet () | |
The destructor. More... | |
CubicalSet::CubicalSet (const CubicalSet &c) | |
The copy constructor. More... | |
CubicalSet & | CubicalSet::operator= (const CubicalSet &c) |
The assignment operator. More... | |
int | CubicalSet::ByteOffset (const int *coords) const |
Computes the right word offset in the buffer. More... | |
int | CubicalSet::BitMask (const int *coords) const |
Computes the mask for the bit in the right word. More... | |
bool | CubicalSet::Inside (const int *coords) |
Verifies whether the cube is within the bounding box. More... | |
int | CubicalSet::Add (const int *coords) |
Adds a cube to the set unless the cube is outside the box. More... | |
int | CubicalSet::Delete (const int *coords) |
Deletes a cube from the set. More... | |
bool | CubicalSet::Contains (const int *coords) const |
Verifies whether the given cube is contained in the cubical set. More... | |
void | CubicalSet::Clear () |
Clears the bitmap and makes the cubical set empty. More... | |
void | CubicalSet::ComputeBettiNumbers (int *result, const char *engine=0, bool quiet=false) const |
Computes the Betti numbers of the cubical set. More... | |
Variables | |
ofstreamcout | fcout |
An output stream defined by M. Mrozek in the CAPD library. More... | |
|
inline |
Adds a cube to the set unless the cube is outside the box.
Returns 0 if the cube is within the box or -1 otherwise.
Definition at line 235 of file cubiset.h.
References CubicalSet::BitMask(), CubicalSet::buffer, CubicalSet::ByteOffset(), and CubicalSet::Inside().
|
inlineprivate |
Computes the mask for the bit in the right word.
Definition at line 218 of file cubiset.h.
References CubicalSet::minimal.
Referenced by CubicalSet::Add(), CubicalSet::Contains(), and CubicalSet::Delete().
|
inlineprivate |
Computes the right word offset in the buffer.
Definition at line 206 of file cubiset.h.
References CubicalSet::dim, CubicalSet::minimal, and CubicalSet::sizes.
Referenced by CubicalSet::Add(), CubicalSet::Contains(), and CubicalSet::Delete().
|
inline |
Clears the bitmap and makes the cubical set empty.
Definition at line 256 of file cubiset.h.
References CubicalSet::buffer, and CubicalSet::bufsize.
|
inline |
Computes the Betti numbers of a full cubical set represented by an object of the class "CubicalSet".
Definition at line 272 of file cubiset.h.
References ComputeBettiNumbers().
Referenced by ComputeBettiNumbers().
|
inline |
Computes the Betti numbers of the given set of full cubes encoded in a binary bitmap.
buffer | - a buffer that contains the bitmap which defines the cubes; each byte stores 8 subsequent positions, with lower bits corresponding to cubes placed to the left from the higher bits; the width of each line must be a multiple of 4 bytes (if the number of cubes is less than that, then the lines must be padded with zeros) - this is required by the MM* engines; the first line corresponds to pixels with the coordinates (0,0,0,...,0), (1,0,0,...,0), ..., (n,0,0,...,0); the next line in the bitmap corresponds to the pixels (0,1,0,...,0), ..., (n,1,0,...,0), etc. |
sizes | - a table of the sizes of the bitmap in each direction, |
dim | - the space dimension, |
result | - a table into which the result is written; its size must be at least (dim + 1), |
engine | - the name of a homology engine to choose; the engine is automatically selected if this is zero |
wrapping | - space wrapping in each direction (0 = no wrapping) |
quiet | - true = the function should display no messages to the standard output stream; false = show a lot of messages |
Definition at line 63 of file homology.h.
References fcout, chomp::homengin::engine::find(), chomp::homology::scon, and chomp::homology::sout.
|
inline |
Computes the Betti numbers of the cubical set.
Note: The size of the result table must be at least dim+1.
Definition at line 262 of file cubiset.h.
References CubicalSet::buffer, CubicalSet::ComputeBettiNumbers(), CubicalSet::dim, CubicalSet::sizes, and CubicalSet::wrapping.
Referenced by CubicalSet::ComputeBettiNumbers().
|
inline |
Verifies whether the given cube is contained in the cubical set.
Returns 'true' if yes, 'false' if not.
Definition at line 251 of file cubiset.h.
References CubicalSet::BitMask(), CubicalSet::buffer, and CubicalSet::ByteOffset().
|
inline |
The copy constructor.
Definition at line 168 of file cubiset.h.
References CubicalSet::buffer, CubicalSet::bufsize, CubicalSet::dim, CubicalSet::minimal, and CubicalSet::sizes.
|
inline |
The only constructor allowed: Creates an empty cubical bitmap of the given size.
Definition at line 118 of file cubiset.h.
References CubicalSet::buffer, CubicalSet::bufsize, CubicalSet::dim, CubicalSet::minimal, CubicalSet::sizes, and CubicalSet::wrapping.
|
inline |
Deletes a cube from the set.
Returns 0 if deleted or -1 if the cube is outside the box.
Definition at line 243 of file cubiset.h.
References CubicalSet::BitMask(), CubicalSet::buffer, CubicalSet::ByteOffset(), and CubicalSet::Inside().
|
inlineprivate |
Verifies whether the cube is within the bounding box.
Definition at line 223 of file cubiset.h.
References CubicalSet::dim, CubicalSet::minimal, and CubicalSet::sizes.
Referenced by CubicalSet::Add(), and CubicalSet::Delete().
|
inline |
The assignment operator.
Definition at line 184 of file cubiset.h.
References CubicalSet::buffer, CubicalSet::bufsize, CubicalSet::dim, CubicalSet::minimal, and CubicalSet::sizes.
|
inline |
The destructor.
Definition at line 158 of file cubiset.h.
References CubicalSet::buffer, CubicalSet::minimal, CubicalSet::sizes, and CubicalSet::wrapping.
|
extern |
An output stream defined by M. Mrozek in the CAPD library.
Referenced by ComputeBettiNumbers().