waves
Basic FE playground
wPicard.h
Go to the documentation of this file.
1 /*
2  * Copyright 2022 University of Liège
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 #ifndef WPICARD_H
18 #define WPICARD_H
19 
20 #include "flow.h"
21 #include "wSolver.h"
22 
23 #include <iostream>
24 #include <vector>
25 #include <memory>
26 #include <Eigen/Sparse>
27 
28 namespace flow
29 {
30 
35 class FLOW_API Picard : public Solver
36 {
37 public:
38  double relax;
39 
40 public:
41  Picard(std::shared_ptr<Problem> _pbl, std::shared_ptr<tbox::LinearSolver> _linsol);
42 
43  virtual bool run() override;
44 
45 #ifndef SWIG
46  virtual void write(std::ostream &out) const override;
47 #endif
48 
49 private:
50  void build(Eigen::SparseMatrix<double, Eigen::RowMajor> &A, std::vector<double> &b);
51 };
52 
53 } // namespace flow
54 
55 #endif //WPICARD_H
flow::Picard::relax
double relax
relaxation
Definition: wPicard.h:38
flow::Solver
Base solver class.
Definition: wSolver.h:36
FLOW_API
#define FLOW_API
Definition: flow.h:29
flow
Namespace for flow module.
Definition: flow.h:37
flow::Picard
Picard solver.
Definition: wPicard.h:35
wSolver.h
flow.h