Skip to content

Commit

Permalink
blas/gonum: test that imaginary part of diagonal is ignored in Zher
Browse files Browse the repository at this point in the history
  • Loading branch information
vladimir-ch committed Aug 15, 2017
1 parent 1dc3fdb commit eabe408
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions blas/testblas/zher.go
Expand Up @@ -5,6 +5,7 @@
package testblas

import (
"math"
"math/cmplx"
"testing"

Expand Down Expand Up @@ -127,13 +128,15 @@ func ZherTest(t *testing.T, impl Zherer) {
a[i*lda+j] = cmplx.NaN()
want[i*lda+j] = cmplx.NaN()
}
a[i*lda+i] = complex(real(a[i*lda+i]), math.NaN())
}
} else {
for i := 0; i < n; i++ {
for j := i + 1; j < n; j++ {
a[i*lda+j] = cmplx.NaN()
want[i*lda+j] = cmplx.NaN()
}
a[i*lda+i] = complex(real(a[i*lda+i]), math.NaN())
}
}

Expand Down

0 comments on commit eabe408

Please sign in to comment.