[BUG FIX] arpack may succeed to compute more EV than expected. (#197)
This commit is contained in:
committed by
Sylvestre Ledru
parent
a98f85544f
commit
dfc8abd708
@@ -75,7 +75,8 @@ void real_symmetric_runner() {
|
||||
&(workd[ipntr[1] - 1]));
|
||||
}
|
||||
// check number of ev found by arpack.
|
||||
if (iparam[4] != nev || info != 0) {
|
||||
if (iparam[4] < nev /*arpack may succeed to compute more EV than expected*/ || info != 0) {
|
||||
std::cout << "ERROR: iparam[4] " << iparam[4] << ", nev " << nev << ", info " << info << std::endl;
|
||||
throw std::domain_error("Error inside ARPACK routines");
|
||||
}
|
||||
|
||||
@@ -153,7 +154,8 @@ void complex_symmetric_runner() {
|
||||
}
|
||||
|
||||
// check number of ev found by arpack
|
||||
if (iparam[4] != nev || info != 0) {
|
||||
if (iparam[4] < nev /*arpack may succeed to compute more EV than expected*/ || info != 0) {
|
||||
std::cout << "ERROR: iparam[4] " << iparam[4] << ", nev " << nev << ", info " << info << std::endl;
|
||||
throw std::domain_error("Error inside ARPACK routines");
|
||||
}
|
||||
|
||||
|
||||
@@ -73,7 +73,8 @@ void real_symmetric_runner() {
|
||||
}
|
||||
|
||||
// check number of ev found by arpack.
|
||||
if (iparam[4] != nev || info != 0) {
|
||||
if (iparam[4] < nev /*arpack may succeed to compute more EV than expected*/ || info != 0) {
|
||||
std::cout << "ERROR: iparam[4] " << iparam[4] << ", nev " << nev << ", info " << info << std::endl;
|
||||
throw std::domain_error("Error inside ARPACK routines");
|
||||
}
|
||||
|
||||
@@ -151,7 +152,8 @@ void complex_symmetric_runner() {
|
||||
}
|
||||
|
||||
// check number of ev found by arpack.
|
||||
if (iparam[4] != nev || info != 0) {
|
||||
if (iparam[4] < nev /*arpack may succeed to compute more EV than expected*/ || info != 0) {
|
||||
std::cout << "ERROR: iparam[4] " << iparam[4] << ", nev " << nev << ", info " << info << std::endl;
|
||||
throw std::domain_error("Error inside ARPACK routines");
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user