Commit 1681e00a authored by Praetorius, Simon's avatar Praetorius, Simon
Browse files

renamed path dune/amdis to amdis

parent 91f95d14
// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
// vi: set et ts=4 sw=2 sts=2:
#include <iostream>
#include <dune/amdis/AMDiS.hpp>
#include <dune/amdis/ProblemStat.hpp>
#include <dune/amdis/Terms.hpp>
using namespace AMDiS;
// 1 component with polynomial degree 1
using HeatParam = TestTraits<AMDIS_DIM, 2>;
using HeatProblem = ProblemStat<HeatParam>;
int main(int argc, char** argv)
{
AMDiS::init(argc, argv);
HeatProblem prob("heat");
prob.initialize(INIT_ALL);
AdaptInfo adaptInfo("adapt");
double tau = adaptInfo.getTimestep();
AMDIS_MSG("timestep = " << tau);
using Op = HeatProblem::ElementOperator;
Op opLhs;
opLhs.addZOT( constant(1.0/tau) );
opLhs.addSOT( constant(1.0) );
Op opRhs;
opRhs.addZOT( valueOf(prob.getSolution<0>(), 1.0/tau) );
opRhs.addZOT( eval([](auto const& x) { return -1.0; }) );
prob.addMatrixOperator(opLhs, 0, 0);
prob.addVectorOperator(opRhs, 0);
// set boundary condition
auto predicate = [](auto const& p){ return p[0] < 1.e-8 || p[1] < 1.e-8; };
auto dbcValues = [](auto const& p){ return 0.0; };
prob.addDirichletBC(predicate, 0, 0, dbcValues);
prob.getSolution<0>().getVector() = 0.0;
double t = 0.0;
for (t = adaptInfo.getStartTime();
t < adaptInfo.getEndTime();
t+= adaptInfo.getTimestep())
{
prob.writeFiles(adaptInfo, t);
prob.buildAfterCoarsen(adaptInfo, Flag(0));
prob.solve(adaptInfo);
}
prob.writeFiles(adaptInfo, t);
AMDiS::finalize();
return 0;
}
\ No newline at end of file
#include "AMDiS.hpp"
// AMDiS includes
#include <dune/amdis/Initfile.hpp>
#include <dune/amdis/Output.hpp>
#include <amdis/Initfile.hpp>
#include <amdis/Output.hpp>
namespace AMDiS
{
......
......@@ -4,7 +4,7 @@
#include <string>
#include <iostream>
#include <dune/amdis/Initfile.hpp>
#include <amdis/Initfile.hpp>
namespace AMDiS
{
......
......@@ -8,8 +8,8 @@
#include <vector>
// AMDiS includes
#include <dune/amdis/Output.hpp>
#include <dune/amdis/common/Math.hpp>
#include <amdis/Output.hpp>
#include <amdis/common/Math.hpp>
namespace AMDiS
{
......
#include "AdaptInstationary.hpp"
// AMDiS includes
#include <dune/amdis/AdaptInfo.hpp>
#include <dune/amdis/Flag.hpp>
#include <dune/amdis/Initfile.hpp>
#include <dune/amdis/Output.hpp>
#include <dune/amdis/ProblemIterationInterface.hpp>
#include <dune/amdis/ProblemTimeInterface.hpp>
#include <amdis/AdaptInfo.hpp>
#include <amdis/Flag.hpp>
#include <amdis/Initfile.hpp>
#include <amdis/Output.hpp>
#include <amdis/ProblemIterationInterface.hpp>
#include <amdis/ProblemTimeInterface.hpp>
namespace AMDiS
{
......
......@@ -6,11 +6,11 @@
#include <dune/common/fmatrix.hh>
#include <dune/common/fvector.hh>
#include <dune/amdis/DirichletBC.hpp>
#include <dune/amdis/LinearAlgebra.hpp>
#include <dune/amdis/LocalAssemblerBase.hpp>
#include <dune/amdis/common/Mpl.hpp>
#include <dune/amdis/common/TypeDefs.hpp>
#include <amdis/DirichletBC.hpp>
#include <amdis/LinearAlgebra.hpp>
#include <amdis/LocalAssemblerBase.hpp>
#include <amdis/common/Mpl.hpp>
#include <amdis/common/TypeDefs.hpp>
namespace AMDiS
{
......
#pragma once
#include <dune/functions/functionspacebases/subspacebasis.hh>
#include <dune/amdis/utility/TreePath.hpp>
#include <dune/amdis/utility/Visitor.hpp>
#include <amdis/utility/TreePath.hpp>
#include <amdis/utility/Visitor.hpp>
#include <dune/amdis/common/Math.hpp>
#include <amdis/common/Math.hpp>
namespace AMDiS {
......
......@@ -13,6 +13,7 @@ dune_library_add_sources(amdis SOURCES
ProblemStat.cpp
StandardProblemIteration.cpp
)
link_libraries(amdis)
install(FILES
AdaptBase.hpp
......@@ -50,7 +51,7 @@ install(FILES
ProblemStatTraits.hpp
ProblemTimeInterface.hpp
StandardProblemIteration.hpp
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/dune/amdis)
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/amdis)
add_subdirectory("assembler")
add_subdirectory("common")
......
......@@ -3,8 +3,8 @@
#include <memory>
#include <string>
#include <dune/amdis/common/Utility.hpp>
#include <dune/amdis/Output.hpp>
#include <amdis/common/Utility.hpp>
#include <amdis/Output.hpp>
namespace AMDiS
{
......
......@@ -5,7 +5,7 @@
#include <string>
// AMDiS includes
#include <dune/amdis/CreatorInterface.hpp>
#include <amdis/CreatorInterface.hpp>
namespace AMDiS
{
......
......@@ -5,11 +5,11 @@
#include <type_traits>
#include <vector>
#include <dune/amdis/Output.hpp>
#include <dune/amdis/common/Concepts.hpp>
#include <dune/amdis/common/ValueCategory.hpp>
#include <dune/amdis/utility/RangeType.hpp>
#include <dune/amdis/utility/TreeData.hpp>
#include <amdis/Output.hpp>
#include <amdis/common/Concepts.hpp>
#include <amdis/common/ValueCategory.hpp>
#include <amdis/utility/RangeType.hpp>
#include <amdis/utility/TreeData.hpp>
namespace AMDiS
{
......
......@@ -2,8 +2,8 @@
#include <dune/functions/functionspacebases/interpolate.hh>
#include <dune/functions/functionspacebases/subspacebasis.hh>
#include <dune/amdis/LinearAlgebra.hpp>
#include <dune/amdis/linear_algebra/HierarchicWrapper.hpp>
#include <amdis/LinearAlgebra.hpp>
#include <amdis/linear_algebra/HierarchicWrapper.hpp>
namespace AMDiS
{
......
......@@ -9,12 +9,12 @@
//#include <dune/geometry/referenceelements.hh>
#include <dune/typetree/childextraction.hh>
#include <dune/amdis/Initfile.hpp>
#include <dune/amdis/common/Size.hpp>
#include <dune/amdis/common/ValueCategory.hpp>
#include <dune/amdis/gridfunctions/DOFVectorView.hpp>
#include <dune/amdis/io/FileWriterInterface.hpp>
#include <dune/amdis/utility/Filesystem.hpp>
#include <amdis/Initfile.hpp>
#include <amdis/common/Size.hpp>
#include <amdis/common/ValueCategory.hpp>
#include <amdis/gridfunctions/DOFVectorView.hpp>
#include <amdis/io/FileWriterInterface.hpp>
#include <amdis/utility/Filesystem.hpp>
namespace AMDiS
{
......
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