Mercurial > hg > octave-avbm
changeset 8421:b8ce8738a4d1
chol.cc: Trivial fix for chol tests.
author | Ben Abbott <bpabbott@mac.com> |
---|---|
date | Wed, 24 Dec 2008 14:50:25 -0500 |
parents | 9038f311c1a8 |
children | 20cbb0fdab48 |
files | src/ChangeLog src/DLD-FUNCTIONS/chol.cc |
diffstat | 2 files changed, 11 insertions(+), 8 deletions(-) [+] |
line wrap: on
line diff
--- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2008-12-24 Ben Abbott <bpabbott@mac.com> + + * DLD-FUNCTIONS/chol.cc: Compare results to 0 in tests. + Delete spurious function calls in test block. + 2008-12-24 John W. Eaton <jwe@octave.org> * DLD-FUNCTIONS/eigs.cc: Use "testif HAVE_ARPACK" to skip tests if @@ -881,7 +886,7 @@ (template <class T> bool extract_keyword (std::istream&, const string_vector&, std::string&, T&, const bool)): Likewise. -2008-09-03 Ben Abbott <bpabott@mac.com> +2008-09-03 Ben Abbott <bpabott@mac.com> * mappers.cc: Use eps(single) as tolerance for single precesion test. @@ -922,7 +927,7 @@ * DLD-FUNCTIONS/__glpk__.cc (F__glpk__): Initialize output vectors by NA value. -2008-08-26 Ben Abbott <bpabott@mac.com> +2008-08-26 Ben Abbott <bpabott@mac.com> * mappers.cc: Adjust tolerance for single precesion tests.
--- a/src/DLD-FUNCTIONS/chol.cc +++ b/src/DLD-FUNCTIONS/chol.cc @@ -473,17 +473,15 @@ %!test %! A = [2,0.2;0.2,1]; -%! issymmetric(A) -%! min(eig(A)) %! Ainv = inv(A); %! Ainv1 = cholinv(A); %! Ainv2 = inv(sparse(A)); %! Ainv3 = cholinv(sparse(A)); %! Ainv4 = spcholinv(sparse(A)); -%! assert (norm(Ainv-Ainv1),1e-10) -%! assert (norm(Ainv-Ainv2),1e-10) -%! assert (norm(Ainv-Ainv3),1e-10) -%! assert (norm(Ainv-Ainv4),1e-10) +%! assert (norm(Ainv-Ainv1),0,1e-10) +%! assert (norm(Ainv-Ainv2),0,1e-10) +%! assert (norm(Ainv-Ainv3),0,1e-10) +%! assert (norm(Ainv-Ainv4),0,1e-10) */