Peano
CCZ4SBH_FV.h
Go to the documentation of this file.
1 // This file is part of the ExaHyPE2 project. For conditions of distribution and
2 // use, please see the copyright notice at www.peano-framework.org
3 #pragma once
4 
5 #include "AbstractCCZ4SBH_FV.h"
6 
8 
9 #include "tarch/logging/Log.h"
10 
11 namespace benchmarks {
12  namespace exahype2 {
13  namespace ccz4 {
14  class CCZ4SBH_FV;
15 #ifdef PureFV
17 
18  void prepareTwoPunctures();
19 #endif
20  } // namespace ccz4
21  } // namespace exahype2
22 } // namespace benchmarks
23 
24 
25 
26 class benchmarks::exahype2::ccz4::CCZ4SBH_FV: public benchmarks::exahype2::ccz4::AbstractCCZ4SBH_FV {
27 private:
28  static tarch::logging::Log _log;
29  static tarch::multicore::BooleanSemaphore _semaphore;
30 
32 
33 public:
37  CCZ4SBH_FV();
38 
39  virtual void initialCondition(
40  double* NOALIAS Q,
41  const tarch::la::Vector<DIMENSIONS, double>& volumeCentre,
42  const tarch::la::Vector<DIMENSIONS, double>& volumeH,
43  bool gridIsConstructed
44  ) override;
45 
55 
62  static bool isCellOverlappingWithBHImpactArea(const peano4::datamanagement::CellMarker& marker);
63 
64  static bool areAllFaceConnectedCellsOverlappingWithBHImpactArea(const peano4::datamanagement::CellMarker& marker);
65 
72  static bool areBothAdjacentCellsOverlappingWithBHImpactArea(const peano4::datamanagement::FaceMarker& marker);
73 
74  static bool isOneAdjacentCellOverlappingWithBHImpactArea(const peano4::datamanagement::FaceMarker& marker);
75 
85  const peano4::datamanagement::CellMarker& marker, int faceNumber
86  );
87 
91  virtual void startTimeStep(
92  double globalMinTimeStamp, double globalMaxTimeStamp, double globalMinTimeStepSize, double globalMaxTimeStepSize
93  ) override;
94 
98  virtual void finishTimeStep() override;
99 
100  void incNumberOfPatches();
101 
102 private:
104  const tarch::la::Vector<DIMENSIONS, double>& cellCentre, const tarch::la::Vector<DIMENSIONS, double>& cellH
105  );
106 };
constexpr double timeStepSize
virtual void initialCondition(double *NOALIAS Q, const tarch::la::Vector< DIMENSIONS, double > &volumeCentre, const tarch::la::Vector< DIMENSIONS, double > &volumeH, bool gridIsConstructed) override
Definition: CCZ4SBH_FV.cpp:59
virtual void startTimeStep(double globalMinTimeStamp, double globalMaxTimeStamp, double globalMinTimeStepSize, double globalMaxTimeStepSize) override
Call superclass and after that report/maintain _numberOfPatches.
Definition: CCZ4SBH_FV.cpp:152
static bool areBothAdjacentCellsOverlappingWithBHImpactArea(const peano4::datamanagement::FaceMarker &marker)
Check two adjacent octants.
Definition: CCZ4SBH_FV.cpp:116
void reduceAdmissibleTimeStepSize(double timeStepSize)
Overwrite limiters time step size.
Definition: CCZ4SBH_FV.cpp:72
static bool isCellOverlappingWithBHImpactArea(const peano4::datamanagement::CellMarker &marker)
Is octant area overlapping with BH impact area.
Definition: CCZ4SBH_FV.cpp:77
static bool areAllFaceConnectedCellsOverlappingWithBHImpactArea(const peano4::datamanagement::CellMarker &marker)
Definition: CCZ4SBH_FV.cpp:83
static tarch::multicore::BooleanSemaphore _semaphore
Definition: CCZ4SBH_FV.h:29
static bool isOneAdjacentCellOverlappingWithBHImpactArea(const peano4::datamanagement::FaceMarker &marker)
Definition: CCZ4SBH_FV.cpp:131
CCZ4SBH_FV()
Initialise the two punctures object if required.
Definition: CCZ4SBH_FV.cpp:57
virtual void finishTimeStep() override
Call superclass and after that report/maintain _numberOfPatches.
Definition: CCZ4SBH_FV.cpp:162
static tarch::logging::Log _log
Definition: CCZ4SBH_FV.h:28
TP::TwoPunctures * twoPunctures
Definition: CCZ4SBH_FV.h:14
Definition: ccz4.py:1