Skip to content
Snippets Groups Projects
Commit 231259dc authored by Elias Pipping's avatar Elias Pipping Committed by Elias Pipping
Browse files

New test case

parent a9b6986b
No related branches found
No related tags found
No related merge requests found
...@@ -63,7 +63,7 @@ ...@@ -63,7 +63,7 @@
#include <dune/tectonic/mydirectionalconvexfunction.hh> #include <dune/tectonic/mydirectionalconvexfunction.hh>
#include <dune/grid/io/file/vtk/vtkwriter.hh> #include <dune/grid/io/file/vtk/vtkwriter.hh>
int const dim = 3; int const dim = 2;
template <class GridView> template <class GridView>
void setup_boundary(GridView const &gridView, void setup_boundary(GridView const &gridView,
...@@ -113,7 +113,8 @@ void assemble_neumann(GridView const &gridView, FEBasis const &feBasis, ...@@ -113,7 +113,8 @@ void assemble_neumann(GridView const &gridView, FEBasis const &feBasis,
BoundaryPatch<GridView> neumannBoundary(gridView, neumannNodes); BoundaryPatch<GridView> neumannBoundary(gridView, neumannNodes);
LocalVectorType SampleVector(0); LocalVectorType SampleVector(0);
// FIXME: random values (time-dependent) // FIXME: random values (time-dependent)
SampleVector[0] = 10 * sqrt(time); SampleVector[0] =
(time <= 0.5) ? sin(time * 2 * M_PI) * 1e3 : (time - 0.5) * 2 * 1e4;
SampleVector[1] = 0; SampleVector[1] = 0;
ConstantFunction<LocalVectorType, LocalVectorType> fNeumann(SampleVector); ConstantFunction<LocalVectorType, LocalVectorType> fNeumann(SampleVector);
NeumannBoundaryAssembler<GridType, LocalVectorType> neumannBoundaryAssembler( NeumannBoundaryAssembler<GridType, LocalVectorType> neumannBoundaryAssembler(
...@@ -298,7 +299,9 @@ int main(int argc, char *argv[]) { ...@@ -298,7 +299,9 @@ int main(int argc, char *argv[]) {
Dune::BlockVector<Dune::FieldVector<double, 1>> s4_old( Dune::BlockVector<Dune::FieldVector<double, 1>> s4_old(
grid->size(grid->maxLevel(), dim)); grid->size(grid->maxLevel(), dim));
s4_old = 50; // FIXME: magic value (-500 is still workable; -1000 is not) s4_old = parset.get<double>("state.initial"); // FIXME: magic value (-500 is
// still workable; -1000 is
// not)
VectorType u1_diff(grid->size(grid->maxLevel(), dim)); VectorType u1_diff(grid->size(grid->maxLevel(), dim));
u1_diff = 0.0; // Has to be zero! u1_diff = 0.0; // Has to be zero!
......
# -*- mode:conf -*- # -*- mode:conf -*-
timesteps = 100 timesteps = 30
verbose = false verbose = false
printFrictionalBoundary = false printFrictionalBoundary = false
printProgress = true printProgress = false
printDifference = false printDifference = false
writeVTK = false writeVTK = false
[state] [state]
enable = true enable = true
iterations = 6 iterations = 5
initial = 10
[grid] [grid]
refinements = 3 refinements = 3
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment