34 #include "chomp/system/config.h" 35 #include "chomp/system/textfile.h" 36 #include "chomp/system/timeused.h" 37 #include "chomp/system/arg.h" 38 #include "chomp/struct/hashsets.h" 56 Alexander-Whitney diagonal for a single cubical cell.\n\ 57 Version 0.01 (April 11, 2013). Copyright (C) 1997-2016 by Pawel Pilarczyk.\n\ 58 This is free software. No warranty. Consult 'license.txt' for details.";
62 This program computes the Alexander-Whitney diagonal for a single cube.\n\ 64 -d N - choose the dimension of the cube.\n\ 65 Switches and additional arguments:\n\ 66 -pN - selection of the coefficients: p=0 for Z, p>1 for Z_p (default: 0);\n\ 67 \tnote: one should use p <= 181.\n\ 68 --log filename - save the output to a file (without progress indicators),\n\ 69 --quiet - suppress data output to the screen (whcih can be still logged),\n\ 70 --help - display this brief help information only and exit.\n\ 71 For more information please consult the accompanying documentation\n\ 72 or ask the program's author at http://www.PawelPilarczyk.com/.";
81 int main (
int argc,
char *argv [])
83 using namespace chomp::homology;
99 int argresult = a. analyze (argc, argv);
104 sout <<
title <<
'\n';
109 sout <<
"Call with '--help' for help.\n";
114 if ((argresult > 0) || (dim <= 0))
130 int *coord =
new int [dim];
131 for (
int i = 0; i < dim; ++ i)
133 CellT Q (dim, coord);
139 sout <<
"Combinatorial Alexander-Whitney diagonal of " <<
140 Q <<
":\n" << combDiag <<
"\n";
145 sout <<
"Alexander-Whitney diagonal over " <<
146 CoefT::ringsymbol () <<
" of " <<
147 Q <<
":\n" << diag <<
"\n";
153 catch (
const char *msg)
155 sout <<
"ERROR: " << msg <<
'\n';
158 catch (
const std::exception &e)
160 sout <<
"ERROR: " << e. what () <<
'\n';
165 sout <<
"ABORT: An unknown error occurred.\n";
Elements of the ring Z_p.
A cubical version of the Alexander-Whitney diagonal.
int main(int argc, char *argv [])
The main procedure of the program.
A tensor of chains with coefficients in an arbitrary commutative ring.
Tools for coordinate wrapping, a.k.a.
Combinatorial tensor of cells.
A combinatorial tensor (for coefficients in Z_2).
void AWdiagonal(const tCombChain< CellT > &ch, tCombTensor< CellT, CellT > &t)
Computes the Alexander-Whitney diagonal of a chain, using the procedure defined for individual cells...
The decision on whether the empty cell should be used as a valid cell of dimension -1...
const char * helpinfo
Brief help information on the program's usage.
An element of the ring Z_p, where p is globally set.
An elementary cubical cell with vertex coordinates of integer type.
const char * title
The title of the program and licensing information.
An empty cell existence decision class with the flag set to false.