verify_probability_matrix - (MACRO) Debug verification of a matrix
Example compile flags (system dependent):
-DLINUX_X86_64 -DLINUX_X86_64_OPTERON -DGNU_COMPILER
-lKJB -lfftw3 -lgsl -lgslcblas -ljpeg -lSVM -lstdc++ -lpthread -lSLATEC -lg2c -lacml -lacml_mv -lblas -lg2c -lncursesw
const Matrix *mp,
When TEST is defined (typically this is "development" mode),
verify_probability_matrix checks that all elements of a matrix are valid
numbers, and that they are in the range of [0,1]. NULL input is considered
valid. If invalid numbers are found, then they are set to either zero or one
(depending on which side of [0,1] they fall), and a warning is printed.
Finally (new for 2017) we exit with EXIT_BUG.
In addition, if the second argument is not NULL, then the Boolean variable
pointed to it is set to either FALSE or TRUE depending on whether the
verification passed or failed.
When TEST is not defined (typically "production" mode), then
verify_probability_matrix becomes a NOP.
This software is not adequatedly tested. It is recomended that
results are checked independantly where appropriate.