Skip to content

Commit

Permalink
set algloop to 1e12 instead of 1e6 when evaluating the right hand sid…
Browse files Browse the repository at this point in the history
…e fails
  • Loading branch information
qichenghua authored and OpenModelica-Hudson committed Jul 18, 2017
1 parent 5914059 commit 7187f70
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Expand Up @@ -33,7 +33,7 @@ NOX::StatusTest::StatusType NOX::StatusTest::SgnChange::checkStatus(const NOX::S
{
if(_firstCall) initialize(problem);
std::vector<bool> fSignChange(_dimSys, false);
Teuchos::RCP<NOX::LAPACK::Group> grp=Teuchos::rcp(new NOX::LAPACK::Group(dynamic_cast<const NOX::LAPACK::Group&>(problem.getSolutionGroup())));//(problem.getSolutionGroup());//solutiongroup is constant, thus we need to assign it to be able to modify it.
Teuchos::RCP<NOX::LAPACK::Group> grp=Teuchos::rcp(new NOX::LAPACK::Group(dynamic_cast<const NOX::LAPACK::Group&>(problem.getSolutionGroup())));//(problem.getSolutionGroup());//solutiongroup is constant, thus we need to assign it to be able to modify it.//throws an error if used in conjunction with lapack
*_x1=*_x0=grp->getX();
grp->computeF();
*_f0=grp->getF();
Expand Down
2 changes: 1 addition & 1 deletion SimulationRuntime/cpp/Solver/Nox/NoxLapackInterface.cpp
Expand Up @@ -167,7 +167,7 @@ bool NoxLapackInterface::computeActualF(NOX::LAPACK::Vector& f, const NOX::LAPAC

//new, experimental version. Delete comments, when this is tested.
for(int i=0;i<_dimSys;i++){
_rhs[i]= ((_rhs[i]<0.0) ? -1.0e6 : 1.0e6);
_rhs[i]= ((_rhs[i]<0.0) ? -1.0e12 : 1.0e12);
}
//Maybe this should have conical form, ie. in case of high values, use 1.0e6*x+1.0e6 instead.

Expand Down

0 comments on commit 7187f70

Please sign in to comment.