Commit 9110f9bd authored by Müller, Felix's avatar Müller, Felix
Browse files

Remove makeProblemStat

parent 2cd4562c
......@@ -517,14 +517,6 @@ namespace AMDiS
-> ProblemStat<DefaultProblemTraits<GlobalBasis>>;
// Generator for ProblemStat with given Grid and GlobalBasis
template <class Grid, class GlobalBasis>
ProblemStat<DefaultProblemTraits<GlobalBasis>>
makeProblemStat(std::string const& name, Grid& grid, GlobalBasis& globalBasis)
{
return {name, grid, globalBasis};
}
// mark templates as explicitly instantiated in cpp file
extern template class ProblemStat<YaspGridBasis<2,1>>;
extern template class ProblemStat<YaspGridBasis<2,2>>;
......
......@@ -42,7 +42,7 @@ auto basis = makeBasis(gv,
lagrange<2>(), blockedLexicographic()
));
// Create a Problem with c++17, use makeProblemStat() in pre c++17
// Create a Problem
ProblemStat prob("prob", *grid, basis);
prob.initialize(INIT_ALL);
```
......
......@@ -113,13 +113,6 @@ given in the `Traits` as `C = typename Traits::CoefficientType`.
--------------------------------|---------------------------------------------
[`oneIteration`](#function-problemstatbuildafteradapt) | A single build-solve-adapt step
### Related functions
Function | Descriptions
--------------------------------|---------------------------------------------
[`makeProblemStat`](#function-makeproblemstat) | Constructs a new problem
## function `ProblemStat::ProblemStat`
```c++
explicit ProblemStat(std::string const& name) // (1)
......@@ -173,10 +166,6 @@ ProblemStat<LagrangeBasis<Grid, 2>> prob3("prob", grid, basis);
ProblemStat prob4("prob", grid, basis);
```
#### See Also
- Generator function to construct a problem: [`makeProblemStat()`](#function-makeproblemstat)
## function `ProblemStat::initialize`
```c++
......@@ -378,45 +367,6 @@ prob.boundaryManager()->setBoxBoundary({1,2,2,2});
prob.addDirichletBC(BoundaryType{1}, 0, 0, 0.0);
```
## function `makeProblemStat`
```c++
template <class Grid, class GlobalBasis>
ProblemStat<DefaultProblemTraits<GlobalBasis>>
makeProblemStat(std::string const& name, Grid& grid, GlobalBasis& globalBasis)
```
Construct a [`ProblemStat`](#class-problemstat) with given name, grid, and basis. The `Traits` type is constructed
from the global basis type, using the wrapper `DefaultProblemTraits`
#### Arguments
`std::string name`
: The name of the problem that is used to identify parameters in the initfile.
`Grid grid`
: A grid implementing the `Dune::Grid` interface.
`GlobalBasis globalBasis`
: A basis implementing the `Dune::Functions::GlobalBasis` interface.
#### Example
```c++
using Grid = Dune::YaspGrid<2>;
Grid grid({1.0, 1.0}, {2, 2});
using namespace Dune::Functions::BasisFactory;
auto basis = makeBasis(grid.leafGridView(), lagrange<2>());
// using c++17 class template argument deduction
auto prob = makeProblemStat("prob", grid, basis);
```
#### See Also
- Class: [`ProblemStat`](#class-problemstat)
## class `ProblemInstat`
Defined in header [`<amdis/ProblemInstat.hpp>`](https://gitlab.mn.tu-dresden.de/amdis/amdis-core/blob/master/src/amdis/ProblemInstat.hpp)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment