20#ifndef LIBMESH_TRILINOS_NOX_NONLINEAR_SOLVER_H
21#define LIBMESH_TRILINOS_NOX_NONLINEAR_SOLVER_H
26#if defined(LIBMESH_TRILINOS_HAVE_NOX) && defined(LIBMESH_TRILINOS_HAVE_EPETRA)
29#include "libmesh/nonlinear_solver.h"
32#include "libmesh/ignore_warnings.h"
33#include "Epetra_Vector.h"
34#include "Epetra_Operator.h"
35#include "Epetra_RowMatrix.h"
36#include "NOX_Epetra_Interface_Required.H"
37#include "NOX_Epetra_Interface_Jacobian.H"
38#include "NOX_Epetra_Interface_Preconditioner.H"
40#include "libmesh/restore_warnings.h"
49class Problem_Interface;
83 virtual void clear ()
override;
88 virtual void init (
const char * name =
nullptr)
override;
94 virtual std::pair<unsigned int, Real>
99 const unsigned int)
override;
113 { libmesh_not_implemented();
return 0; }
141 _n_linear_iterations(0)
Manages consistently variables, degrees of freedom, coefficient vectors, matrices and non-linear solv...
This base class can be inherited from to provide interfaces to nonlinear solvers from different packa...
const sys_type & system() const
This class provides an interface to nox iterative solvers that is compatible with the libMesh Nonline...
virtual unsigned get_current_nonlinear_iteration_number() const override
virtual void init(const char *name=nullptr) override
Initialize data structures if not done so already.
virtual std::pair< unsigned int, Real > solve(SparseMatrix< T > &, NumericVector< T > &, NumericVector< T > &, const double, const unsigned int) override
Call the Nox solver.
NOX::Solver::Generic * _solver
Nonlinear solver context.
Problem_Interface * _interface
Solver interface.
virtual void clear() override
Release all memory and clear data structures.
virtual int get_total_linear_iterations() override
Get the total number of linear iterations done in the last solve.
int _n_linear_iterations
Stores the total number of linear iterations from the last solve.
NoxNonlinearSolver(sys_type &system)
Constructor.
virtual ~NoxNonlinearSolver()
Destructor.
NonlinearImplicitSystem sys_type
The type of system.
Provides a uniform interface to vector storage schemes for different linear algebra libraries.
The libMesh namespace provides an interface to certain functionality in the library.