Exemplo n.º 1
0
NOX::Abstract::Group::ReturnType 
NOX::LAPACK::Group::applyJacobian(const Abstract::Vector& input, 
				  NOX::Abstract::Vector& result) const
{
  const Vector& lapackinput = dynamic_cast<const Vector&> (input);
  Vector& lapackresult = dynamic_cast<Vector&> (result);
  return applyJacobian(lapackinput, lapackresult);
}
Exemplo n.º 2
0
NOX::Abstract::Group::ReturnType 
LOCA::PhaseTransition::ExtendedGroup::applyJacobian(const NOX::Abstract::Vector& input, 
				  NOX::Abstract::Vector& result) const
{
  const LOCA::PhaseTransition::ExtendedVector& lapackinput = 
     dynamic_cast<const LOCA::PhaseTransition::ExtendedVector&> (input);
  LOCA::PhaseTransition::ExtendedVector& lapackresult =
     dynamic_cast<LOCA::PhaseTransition::ExtendedVector&> (result);
  return applyJacobian(lapackinput, lapackresult);
}
double
LOCA::TurningPoint::MooreSpence::ExtendedGroup::getNormNewtonSolveResidual() const 
{
  string callingFunction = 
    "LOCA::TurningPoint::MooreSpence::ExtendedGroup::getNormNewtonSolveResidual()";
  NOX::Abstract::Group::ReturnType finalStatus;
  LOCA::TurningPoint::MooreSpence::ExtendedVector residual = *fVec;
  
  finalStatus = applyJacobian(*newtonVec, residual);
  globalData->locaErrorCheck->checkReturnType(finalStatus, callingFunction);

  residual.update(1.0, *fVec, 1.0);
  return residual.norm();
}
Exemplo n.º 4
0
double
LOCA::Hopf::MinimallyAugmented::ExtendedGroup::
getNormNewtonSolveResidual() const 
{
  string callingFunction = 
    "LOCA::Hopf::MinimallyAugmented::ExtendedGroup::getNormNewtonSolveResidual()";
  NOX::Abstract::Group::ReturnType finalStatus;
  LOCA::MultiContinuation::ExtendedVector residual = *fVec;
  
  finalStatus = applyJacobian(*newtonVec, residual);
  globalData->locaErrorCheck->checkReturnType(finalStatus, callingFunction);

  residual = residual.update(1.0, *fVec, 1.0);
  return residual.norm();
}
Exemplo n.º 5
0
double
NOX::Belos::Group::getNormNewtonSolveResidual() const 
{
  NOX::Abstract::Group::ReturnType status;
  Teuchos::RCP<NOX::Abstract::Vector> residual = 
    getF().clone(NOX::DeepCopy);
  
  status = applyJacobian(*newtonVecPtr, *residual);
  if (status != NOX::Abstract::Group::Ok) {
    std::cerr << "Error:  NOX::Belos::Group::getNormNewtonSolveResidual() -- applyJacobian failed!" << std::endl;
    throw "NOX Error";
  }

  residual->update(1.0, getF(), 1.0);
  double resid_norm = residual->norm();

  return resid_norm;
}