7 #ifndef DENSE_GEN_REAL_SHIFT_SOLVE_H 8 #define DENSE_GEN_REAL_SHIFT_SOLVE_H 23 template <
typename Scalar>
48 m_mat(mat), m_n(mat.
rows())
50 if (mat.rows() != mat.cols())
51 throw std::invalid_argument(
"DenseGenRealShiftSolve: matrix must be square");
68 m_solver.
compute(m_mat - sigma * Matrix::Identity(m_n, m_n));
80 MapConstVec
x(x_in, m_n);
82 y.noalias() = m_solver.
solve(x);
88 #endif // DENSE_GEN_REAL_SHIFT_SOLVE_H
PartialPivLU & compute(const EigenBase< InputType > &matrix)
void perform_op(const Scalar *x_in, Scalar *y_out) const
A matrix or vector expression mapping an existing array of data.
Eigen::Matrix< Scalar, Eigen::Dynamic, Eigen::Dynamic > Matrix
static const double sigma
LU decomposition of a matrix with partial pivoting, and related features.
const Eigen::Ref< const Matrix > ConstGenericMatrix
Eigen::Map< Vector > MapVec
EIGEN_DEFAULT_DENSE_INDEX_TYPE Index
The Index type as used for the API.
void set_shift(Scalar sigma)
Eigen::Matrix< Scalar, Eigen::Dynamic, 1 > Vector
Eigen::PartialPivLU< Matrix > m_solver
DenseGenRealShiftSolve(ConstGenericMatrix &mat)
Eigen::Map< const Vector > MapConstVec
const Solve< PartialPivLU, Rhs > solve(const MatrixBase< Rhs > &b) const
set noclip points set clip one set noclip two set bar set border lt lw set xdata set ydata set zdata set x2data set y2data set boxwidth set dummy x