7#ifndef __IPPARDISOSOLVERINTERFACE_HPP__
8#define __IPPARDISOSOLVERINTERFACE_HPP__
19#define IPOPT_DECL_PARDISOINIT(x) void (x)( \
21 const ipindex* MTYPE, \
22 const ipindex* SOLVER, \
29#define IPOPT_DECL_PARDISO(x) void (x)( \
31 const ipindex* MAXFCT, \
32 const ipindex* MNUM, \
33 const ipindex* MTYPE, \
34 const ipindex* PHASE, \
39 const ipindex* PERM, \
40 const ipindex* NRHS, \
42 const ipindex* MSGLVL, \
50#define IPOPT_DECL_SMAT_REORDERING_PARDISO_WSMP(x) void (x)( \
86 const std::string& prefix
107 Index numberOfNegEVals);
142#ifndef PARDISO_MATCHING_PREPROCESS
177#ifdef PARDISO_MATCHING_PREPROCESS
265#ifdef PARDISO_MATCHING_PREPROCESS
285 Index numberOfNegEVals
#define IPOPT_DECL_SMAT_REORDERING_PARDISO_WSMP(x)
#define IPOPT_DECL_PARDISO(x)
#define IPOPT_DECL_PARDISOINIT(x)
This class stores a list of user set options.
Interface to the linear solver Pardiso as distributed by pardiso-project.org, derived from SparseSymL...
Number * a_
Array for storing the values of the matrix.
Index MSGLVL_
Message level.
static void RegisterOptions(SmartPtr< RegisteredOptions > roptions)
virtual bool IncreaseQuality()
Request to increase quality of solution for next solve.
PardisoSolverInterface(SmartPtr< LibraryLoader > pardisoloader_)
Constructor.
static void SetFunctions(IPOPT_DECL_PARDISOINIT(*pardisoinit), IPOPT_DECL_PARDISO(*pardiso), bool isparallel,=NULL)
set Pardiso functions to use for every instantiation of this class
PardisoSolverInterface(const PardisoSolverInterface &)
Copy Constructor.
virtual ESymSolverStatus InitializeStructure(Index dim, Index nonzeros, const Index *ia, const Index *ja)
Method for initializing internal structures.
IPOPT_DECL_PARDISOINIT * pardisoinit
bool have_symbolic_factorization_
Flag indicating if symbolic factorization has already been performed.
Index nonzeros_
Number of nonzeros of the matrix in triplet representation.
virtual ESymSolverStatus MultiSolve(bool new_matrix, const Index *ia, const Index *ja, Index nrhs, Number *rhs_vals, bool check_NegEVals, Index numberOfNegEVals)
Solve operation for multiple right hand sides.
PardisoMatchingStrategy match_strat_
Option that controls the matching strategy.
Index pardiso_max_droptol_corrections_
Maximal number of decreases of drop tolerance during one solve.
Number * DPARM_
Parameter and info array for Pardiso.
bool pardiso_iterative_
Flag indicating whether we are using the iterative solver in Pardiso.
Index negevals_
Number of negative eigenvalues.
bool skip_inertia_check_
Flag indicating if the inertia is always assumed to be correct.
IPOPT_DECL_PARDISO * pardiso
bool pardiso_repeated_perturbation_means_singular_
Flag indicating whether repeated perturbed elements even after a new symbolic factorization should be...
ESymSolverStatus Factorization(const Index *ia, const Index *ja, bool check_NegEVals, Index numberOfNegEVals)
Call Pardiso to factorize the Matrix.
ESymSolverStatus Solve(const Index *ia, const Index *ja, Index nrhs, Number *rhs_vals)
Call Pardiso to do the Solve.
virtual Number * GetValuesArrayPtr()
Method returning an internal array into which the nonzero elements (in the same order as ja) will be ...
void operator=(const PardisoSolverInterface &)
Default Assignment Operator.
ESymSolverStatus SymbolicFactorization(const Index *ia, const Index *ja)
Call Pardiso to do the analysis phase.
bool pardiso_exist_parallel
bool pardiso_redo_symbolic_fact_only_if_inertia_wrong_
Flag indicating whether the symbolic factorization should only be done after perturbed elements,...
Index MTYPE_
Matrix type; real and symmetric indefinite.
Index dim_
Number of rows and columns of the matrix.
virtual bool ProvidesInertia() const
Query whether inertia is computed by linear solver.
EMatrixFormat MatrixFormat() const
Query of requested matrix type that the linear solver understands.
bool initialized_
Flag indicating if internal data is initialized.
virtual ~PardisoSolverInterface()
Destructor.
bool InitializeImpl(const OptionsList &options, const std::string &prefix)
Implementation of the initialization method that has to be overloaded by for each derived class.
PardisoMatchingStrategy
Type for matching strategies.
void ** PT_
Internal data address pointers.
virtual Index NumberOfNegEVals() const
Number of negative eigenvalues detected during last factorization.
Index * IPARM_
Parameter and info array for Pardiso.
Index MNUM_
Actual matrix for the solution phase.
SmartPtr< LibraryLoader > pardisoloader
Index MAXFCT_
Maximal number of factors with identical nonzero structure.
Template class for Smart Pointers.
Base class for interfaces to symmetric indefinite linear solvers for sparse matrices.
EMatrixFormat
Enum to specify sparse matrix format.
@ CSR_Format_1_Offset
Compressed sparse row format for upper triangular part, with 1 offset.
This file contains a base class for all exceptions and a set of macros to help with exceptions.
ESymSolverStatus
Enum to report outcome of a linear solve.
ipindex Index
Type of all indices of vectors, matrices etc.
ipnumber Number
Type of all numbers.