Peano
Loading...
Searching...
No Matches
MyObserver.h
Go to the documentation of this file.
1// This file is part of the Peano project. For conditions of distribution and
2// use, please see the copyright notice at www.peano-framework.org
3#ifndef _EXAMPLES_GRID_MYOBSERVER_H_
4#define _EXAMPLES_GRID_MYOBSERVER_H_
5
6
9
10
11namespace examples {
12 namespace grid {
13 class MyObserver;
14 }
15}
16
17
19 #if PeanoDebug>0
21 #else
23 #endif
24{
25 private:
27 public:
28 static constexpr int GridRefinementIterations = 16;
29 static constexpr int StationaryIterations = 4;
30
31 MyObserver(int spacetreeId = -1, int counter=0);
32 virtual ~MyObserver();
33
34 void beginTraversal(
37 ) override;
38
39 void endTraversal(
42 ) override;
43
44 void enterCell(
46 ) override;
47
48
49 void leaveCell(
51 ) override;
52
58 TraversalObserver* clone(int spacetreeId) override;
59
60 std::vector< peano4::grid::GridControlEvent > getGridControlEvents() override;
61};
62
63#endif
MyObserver(int spacetreeId=-1, int counter=0)
void leaveCell(const peano4::grid::GridTraversalEvent &event) override
void beginTraversal(const tarch::la::Vector< Dimensions, double > &x, const tarch::la::Vector< Dimensions, double > &h) override
Begin the traversal.
void endTraversal(const tarch::la::Vector< Dimensions, double > &x, const tarch::la::Vector< Dimensions, double > &h) override
void enterCell(const peano4::grid::GridTraversalEvent &event) override
Event is invoked per cell.
std::vector< peano4::grid::GridControlEvent > getGridControlEvents() override
TraversalObserver * clone(int spacetreeId) override
I use the clone to create one observer object per traversal thread.
static constexpr int GridRefinementIterations
Definition MyObserver.h:28
static constexpr int StationaryIterations
Definition MyObserver.h:29
Observer which pipes the automaton transitions into a VTK file.
This code is taken from the original ExaHyPE project written by colleagues from the University of Tre...
Definition MyObserver.h:11
Simple vector class.
Definition Vector.h:150