Skip to content
Snippets Groups Projects
Commit 352029bf authored by Tom Fischer's avatar Tom Fischer
Browse files

[MaL/LA] EigenLisLinearSolver constr. using string lis_options.

parent 168c198a
No related branches found
No related tags found
No related merge requests found
......@@ -29,6 +29,12 @@ EigenLisLinearSolver::EigenLisLinearSolver(
{
}
EigenLisLinearSolver::EigenLisLinearSolver(std::string const& /*solver_name*/,
std::string const& lis_options)
: lis_option_(nullptr), lis_options_(lis_options)
{
}
bool EigenLisLinearSolver::solve(EigenMatrix& A_, EigenVector& b_,
EigenVector& x_)
{
......
......@@ -10,10 +10,10 @@
#pragma once
#include <vector>
#include <lis.h>
#include <vector>
#include "BaseLib/ConfigTree.h"
#include "MathLib/LinAlg/Lis/LisOption.h"
......@@ -40,15 +40,31 @@ public:
EigenLisLinearSolver(const std::string solver_name,
BaseLib::ConfigTree const*const option);
/**
* Constructor
* @param solver_name A name used as a prefix for command line options
* if there are such options available.
* @param lis_options string containing the options for LIS library; options
* will be applied in the solve method.
*/
EigenLisLinearSolver(std::string const& solver_name,
std::string const& lis_options);
/**
* copy linear solvers options
* @param lis_options string containing the options for LIS library; options
* will be applied in the solve method.
*/
void setOption(const LisOption& option) { lis_option_ = option; }
void setOption(std::string const& lis_options)
{
lis_options_ = lis_options;
}
bool solve(EigenMatrix &A, EigenVector& b, EigenVector &x);
private:
LisOption lis_option_;
std::string lis_options_;
};
} // MathLib
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment