directsolvers.h

来自「Flens库-一个在C++的矩阵运算库」· C头文件 代码 · 共 72 行

H
72
字号
#ifndef POISSON_SOLVER_FLENS_IMPL_DIRECTSOLVERS_H#define POISSON_SOLVER_FLENS_IMPL_DIRECTSOLVERS_H 1#include <fftw3.h>namespace flens {//-- stationary iterative solver -----------------------------------------------template <typename Method>class StationaryIterativeSolver{    public:        typedef typename Method::MatrixType MatrixType;        typedef typename Method::VectorType VectorType;        StationaryIterativeSolver(const MatrixType &A, const VectorType &f,                                  VectorType &_u);        void        solve();    private:        Method            S;        const MatrixType  &A;        const VectorType  &f;        VectorType        &u, r;};//-- fast poisson solver -------------------------------------------------------template <typename MatrixType, typename VectorType>class FastPoissonSolver{    public:        FastPoissonSolver(const MatrixType &A, const VectorType &f,                          VectorType &_u);        ~FastPoissonSolver();        void        solve();    private:        const VectorType &f;        VectorType       &u;        fftw_plan        plan;};//-- cholesky factorization ----------------------------------------------------template <typename MatrixType, typename VectorType>class Cholesky{    public:        Cholesky(const MatrixType &A, const VectorType &f,                 VectorType &_u);        void        solve();    private:        const VectorType &f;        VectorType       &u;};} // namespace flens#include <poisson_solver/flens_impl/directsolvers.tcc>#endif // POISSON_SOLVER_FLENS_IMPL_DIRECTSOLVERS_H

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?