Commit 62c92cd4 authored by Douglas Serson's avatar Douglas Serson
Browse files

Fix bug in DriverModifiedArnoldi

parent e8d55fde
......@@ -100,6 +100,8 @@ void DriverArnoldi::v_InitObject(ostream &out)
m_session->LoadParameter("nits", m_nits, 500);
m_session->LoadParameter("evtol", m_evtol, 1e-06);
ASSERTL0( m_kdim >= m_nvec, "nvec cannot be larger than kdim.");
m_session->LoadParameter("realShift", m_realShift, 0.0);
m_equ[0]->SetLambda(m_realShift);
......
......@@ -191,7 +191,14 @@ void DriverModifiedArnoldi::v_Execute(ostream &out)
// Test for convergence.
converged = EV_test(i, i, zvec, wr, wi, resnorm,
std::min(i, m_nvec), evlout, resid0);
converged = max (converged, 0);
if ( i >= m_nvec)
{
converged = max (converged, 0);
}
else
{
converged = 0;
}
if (m_comm->GetRank() == 0)
{
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment