Commit 59f0c65c authored by Praetorius, Simon's avatar Praetorius, Simon
Browse files

moved to current dune version

parent 9b0f4bf7
Pipeline #901 passed with stage
in 13 minutes and 7 seconds
......@@ -30,8 +30,8 @@ namespace AMDiS
{
public:
template <class Predicate, class Values,
class = std::enable_if_t< Concepts::Functor<Predicate, bool(WorldVector)> &&
Concepts::Functor<Values, double(WorldVector)> > >
std::enable_if_t< Concepts::Functor<Predicate, bool(WorldVector)> &&
Concepts::Functor<Values, double(WorldVector)>, int*> = nullptr>
DirichletBC(Predicate&& predicate, Values&& values)
: predicate(std::forward<Predicate>(predicate))
, values(std::forward<Values>(values))
......
......@@ -7,7 +7,7 @@
#include <dune/grid/io/file/vtk/vtkwriter.hh>
#include <dune/grid/io/file/vtk/vtksequencewriter.hh>
#include <dune/geometry/genericgeometry/referenceelements.hh>
#include <dune/geometry/referenceelements.hh>
#include <dune/amdis/Initfile.hpp>
#include <dune/amdis/common/Loops.hpp>
......
......@@ -7,7 +7,7 @@
#include <array>
#include <memory>
#include <dune/common/array.hh>
#include <dune/common/filledarray.hh>
#include <dune/common/fvector.hh>
#include <dune/grid/albertagrid.hh>
......@@ -149,7 +149,7 @@ namespace AMDiS
msg("L = ", L);
auto s = Dune::fill_array<int,dim>(2); // number of cells on coarse mesh in each direction
auto s = Dune::filledArray<std::size_t(dim)>(2); // number of cells on coarse mesh in each direction
Parameters::get(meshName + "->num cells", s);
// TODO: add more parameters for yasp-grid (see constructor)
......@@ -171,7 +171,7 @@ namespace AMDiS
Parameters::get(meshName + "->min corner", lowerleft);
Parameters::get(meshName + "->max corner", upperright);
auto s = Dune::fill_array<int,dim>(2); // number of cells on coarse mesh in each direction
auto s = Dune::filledArray<std::size_t(dim)>(2); // number of cells on coarse mesh in each direction
Parameters::get(meshName + "->num cells", s);
// TODO: add more parameters for yasp-grid (see constructor)
......
......@@ -196,9 +196,25 @@ namespace AMDiS
/// Return the \ref linearSolver
auto getSolver() { return linearSolver; }
void setSolver(std::shared_ptr<LinearSolverType> const& solver_)
{
linearSolver = solver_;
}
/// Return the \ref mesh
auto getMesh() { return mesh; }
void setMesh(std::shared_ptr<Mesh> const& mesh_)
{
mesh = mesh_;
meshView = make_shared<MeshView>(mesh->leafGridView());
createFeSpaces();
createMatricesAndVectors();
createFileWriter();
}
/// Return the \ref meshView
auto getMeshView() { return meshView; }
......
......@@ -275,8 +275,9 @@ namespace AMDiS
rhs->getVector(_r) = 0.0;
}
For<0, nComponents>::loop([this, &nnz, asmMatrix_, asmVector, _r](auto const _c)
For<0, nComponents>::loop([this, &nnz, asmMatrix_, asmVector, r=_r](auto const _c)
{
auto const _r = r;
using MatrixData = typename ProblemStatSeq<Traits>::template MatrixData<_r, _c>;
using VectorData = typename ProblemStatSeq<Traits>::template VectorData<_r>;
......
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