mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
Made the solve() methods const.
This commit is contained in:
parent
8f8baa62c8
commit
e52cae02ac
@ -35,7 +35,7 @@ namespace Opm
|
||||
LinearSolverInterface::LinearSolverReport
|
||||
LinearSolverInterface::solve(const CSRMatrix* A,
|
||||
const double* rhs,
|
||||
double* solution)
|
||||
double* solution) const
|
||||
{
|
||||
return solve(A->m, A->nnz, A->ia, A->ja, A->sa, rhs, solution);
|
||||
}
|
||||
|
@ -52,7 +52,7 @@ namespace Opm
|
||||
/// Note: this method is a convenience method that calls the virtual solve() method.
|
||||
LinearSolverReport solve(const CSRMatrix* A,
|
||||
const double* rhs,
|
||||
double* solution);
|
||||
double* solution) const;
|
||||
|
||||
/// Solve a linear system, with a matrix given in compressed sparse row format.
|
||||
/// \param[in] size # of rows in matrix
|
||||
@ -69,7 +69,7 @@ namespace Opm
|
||||
const int* ja,
|
||||
const double* sa,
|
||||
const double* rhs,
|
||||
double* solution) = 0;
|
||||
double* solution) const = 0;
|
||||
|
||||
};
|
||||
|
||||
|
@ -109,7 +109,7 @@ namespace Opm
|
||||
const int* ja,
|
||||
const double* sa,
|
||||
const double* rhs,
|
||||
double* solution)
|
||||
double* solution) const
|
||||
{
|
||||
// Build Istl structures from input.
|
||||
// System matrix
|
||||
|
@ -70,7 +70,7 @@ namespace Opm
|
||||
const int* ja,
|
||||
const double* sa,
|
||||
const double* rhs,
|
||||
double* solution);
|
||||
double* solution) const;
|
||||
private:
|
||||
double linsolver_residual_tolerance_;
|
||||
int linsolver_verbosity_;
|
||||
|
@ -45,7 +45,7 @@ namespace Opm
|
||||
const int* ja,
|
||||
const double* sa,
|
||||
const double* rhs,
|
||||
double* solution)
|
||||
double* solution) const
|
||||
{
|
||||
CSRMatrix A = {
|
||||
size,
|
||||
|
@ -76,7 +76,7 @@ namespace Opm
|
||||
const int* ja,
|
||||
const double* sa,
|
||||
const double* rhs,
|
||||
double* solution);
|
||||
double* solution) const;
|
||||
};
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user