Skip to content
Snippets Groups Projects
Commit 8b9f4d51 authored by James Goppert's avatar James Goppert
Browse files

Fixed max. iter. bug.

parent ea378671
No related branches found
No related tags found
No related merge requests found
......@@ -195,7 +195,7 @@ int main (int argc, char const* argv[])
solver = new FGNelderMead(trimmer,initialGuess,
lowerBound, upperBound, initialStepSize,iterMax,rtol,
abstol,speed,showConvergeStatus,showSimplex,pause,&callback);
while(solver->status()) solver->update();
while(solver->status()==1) solver->update();
}
catch (const std::runtime_error & e)
{
......
......@@ -108,7 +108,7 @@ void FGNelderMead::update()
m_cost[m_iMin])/(std::abs(m_cost[m_iMax]+std::abs(m_cost[m_iMin])+
std::numeric_limits<double>::epsilon()));
// check for max iteratin break condition
// check for max iteration break condition
if (iter > iterMax)
{
std::cout << "\nmax iterations exceeded" << std::endl;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment