Mercurial > hg > octave-lojdl
changeset 10094:ab1101011a6d
lu.cc: avoid test failures if HAVE_QRUPDATE_LUU is not defined
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Wed, 13 Jan 2010 06:00:14 -0500 |
parents | d90736774da2 |
children | eb8ac0eed9f1 |
files | src/ChangeLog src/DLD-FUNCTIONS/lu.cc |
diffstat | 2 files changed, 13 insertions(+), 8 deletions(-) [+] |
line wrap: on
line diff
--- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2010-01-13 John W. Eaton <jwe@octave.org> + + * DLD-FUNCTIONS/lu.cc: Avoid test failures if HAVE_QRUPDATE_LUU is + not defined. + 2010-01-12 David Bateman <dbateman@free.fr> * graphics.h.in (patch::properties): Add "flat" value to
--- a/src/DLD-FUNCTIONS/lu.cc +++ b/src/DLD-FUNCTIONS/lu.cc @@ -795,56 +795,56 @@ %! 0.86184 + 0.34689i ]; %! -%!test +%!testif HAVE_QRUPDATE_LUU %! [L,U,P] = lu(A); %! [L,U] = luupdate(L,U,P*u,v); %! assert(norm(vec(tril(L)-L),Inf) == 0) %! assert(norm(vec(triu(U)-U),Inf) == 0) %! assert(norm(vec(P'*L*U - A - u*v.'),Inf) < norm(A)*1e1*eps) %! -%!test +%!testif HAVE_QRUPDATE_LUU %! [L,U,P] = lu(Ac); %! [L,U] = luupdate(L,U,P*uc,vc); %! assert(norm(vec(tril(L)-L),Inf) == 0) %! assert(norm(vec(triu(U)-U),Inf) == 0) %! assert(norm(vec(P'*L*U - Ac - uc*vc.'),Inf) < norm(Ac)*1e1*eps) -%!test +%!testif HAVE_QRUPDATE_LUU %! [L,U,P] = lu(single(A)); %! [L,U] = luupdate(L,U,P*single(u),single(v)); %! assert(norm(vec(tril(L)-L),Inf) == 0) %! assert(norm(vec(triu(U)-U),Inf) == 0) %! assert(norm(vec(P'*L*U - single(A) - single(u)*single(v).'),Inf) < norm(single(A))*1e1*eps('single')) %! -%!test +%!testif HAVE_QRUPDATE_LUU %! [L,U,P] = lu(single(Ac)); %! [L,U] = luupdate(L,U,P*single(uc),single(vc)); %! assert(norm(vec(tril(L)-L),Inf) == 0) %! assert(norm(vec(triu(U)-U),Inf) == 0) %! assert(norm(vec(P'*L*U - single(Ac) - single(uc)*single(vc).'),Inf) < norm(single(Ac))*1e1*eps('single')) -%!test +%!testif HAVE_QRUPDATE_LUU %! [L,U,P] = lu(A); %! [L,U,P] = luupdate(L,U,P,u,v); %! assert(norm(vec(tril(L)-L),Inf) == 0) %! assert(norm(vec(triu(U)-U),Inf) == 0) %! assert(norm(vec(P'*L*U - A - u*v.'),Inf) < norm(A)*1e1*eps) %! -%!test +%!testif HAVE_QRUPDATE_LUU %! [L,U,P] = lu(Ac); %! [L,U,P] = luupdate(L,U,P,uc,vc); %! assert(norm(vec(tril(L)-L),Inf) == 0) %! assert(norm(vec(triu(U)-U),Inf) == 0) %! assert(norm(vec(P'*L*U - Ac - uc*vc.'),Inf) < norm(Ac)*1e1*eps) -%!test +%!testif HAVE_QRUPDATE_LUU %! [L,U,P] = lu(single(A)); %! [L,U,P] = luupdate(L,U,P,single(u),single(v)); %! assert(norm(vec(tril(L)-L),Inf) == 0) %! assert(norm(vec(triu(U)-U),Inf) == 0) %! assert(norm(vec(P'*L*U - single(A) - single(u)*single(v).'),Inf) < norm(single(A))*1e1*eps('single')) %! -%!test +%!testif HAVE_QRUPDATE_LUU %! [L,U,P] = lu(single(Ac)); %! [L,U,P] = luupdate(L,U,P,single(uc),single(vc)); %! assert(norm(vec(tril(L)-L),Inf) == 0)