summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortorset2009-02-18 16:13:56 +0000
committertorset2009-02-18 16:13:56 +0000
commit739f45380ef86f5edee2688d4077422e2a3eb91b (patch)
tree4dce7320bdf76838ded360540d951e57bf2cf6c7
parent706bb0bfccb067e202377ab963efe75a6a648e95 (diff)
downloadscilab2c-739f45380ef86f5edee2688d4077422e2a3eb91b.tar.gz
scilab2c-739f45380ef86f5edee2688d4077422e2a3eb91b.tar.bz2
scilab2c-739f45380ef86f5edee2688d4077422e2a3eb91b.zip
add failing test
-rw-r--r--scilab2c/src/matrixOperations/logm/testDoubleLogm.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/scilab2c/src/matrixOperations/logm/testDoubleLogm.c b/scilab2c/src/matrixOperations/logm/testDoubleLogm.c
index f54b2af9..7667192c 100644
--- a/scilab2c/src/matrixOperations/logm/testDoubleLogm.c
+++ b/scilab2c/src/matrixOperations/logm/testDoubleLogm.c
@@ -79,14 +79,18 @@ static void dlogmaTest(void){
else assert(1);
}
+ /* FIXME : sign pb with the imaginary part below : it's due to the reals eigenvalues which are
+ stored like that : eigenvalues + (-0)*i instead of eigenvalues + 0 *i
+ When we do operations with eigenvalues the sign isn't good
+ */
+
for(i=0;i<16;i++) {
printf("out[%d] = %f + %f *i ---result = %f + %f *i\n",i,zreals(out16[i]),zimags(out16[i]),result16R[i],result16I[i]);
assert( fabs(zreals(out16[i])-result16R[i]) / fabs(zreals(out16[i])) <1e-13);
- /*assert( fabs(zimags(out16[i])-result16I[i]) / fabs(zimags(out16[i])) <1e-16);*/
+ assert( fabs(zimags(out16[i])-result16I[i]) / fabs(zimags(out16[i])) <1);
}
for(i=0;i<16;i++) {
- printf("out[%d] = %f + %f *i ---result = %f + %f *i\n",i,zreals(outHer[i]),zimags(outHer[i]),resultHerR[i],resultHerI[i]);
assert( fabs(zreals(outHer[i])-resultHerR[i]) / fabs(zreals(outHer[i])) <1e-12);
assert( fabs(zimags(outHer[i])-resultHerI[i]) / fabs(zimags(outHer[i])) <1e-13);
}