DamBreak++ Wave Simulator 0.3
DamBreak++ Simulation Framework
Loading...
Searching...
No Matches
Testvs19_ProtoPhysicalAlgorithm.h
Go to the documentation of this file.
1#pragma once
2
3#include <memory>
4
5#include <string>
6// App include
8
9// forward declarations
10namespace dbpp {
11 class FluxAlgorithm;
12 class PhysicalSystem;
14}
15
16namespace Sfx {
17 class Simulation;
18}
19
20namespace Testvs19
21{
37 {
38 public:
44 ProtoPhysicalAlgorithm( std::string aName, dbpp::FluxAlgorithm* aFluxAlgo)
45 : m_name{ std::move(aName) }, m_fluxAlgo{ nullptr } {}
46 // ProtoPhysicalAlgorithm(SweRhsAlgorithm*)
54 const std::shared_ptr<dbpp::FiniteVolumeDiscretization>& aGlbdiscr,
55 Sfx::Simulation* aSim) override final
56 {
57#if 0 // replace lines below by these
58 RhsHLLFluxSrc rhsDiscr{...}
59 LDeltaOperator w_ldeltaOp(rhsDiscr); // rhs operator (spatial terms discretization)
60 ODESolver1D w_odeSolver1d(w_ldeltaOp); // U_t = L(U)
61 w_odeSolver.registerPhysicalSystem(aPhysys); // physical system under study
62 w_odeSolver.solve(... dt);
63
64 auto w_numethod = std::make_shared<dbpp::SemiDiscreteMethod>(&w_odeSolver1d); // numerical method ...
65 // Create the global discretization for this method
66 auto w_gblDiscr = std::make_shared<dbpp::FiniteVolumeDiscretization>(w_numethod);
67#endif
68 [[maybe_unused]] auto startT = aSim->getSimulationStartTime();
69 //[[maybe_unused]] auto stopT = aSim->get;
70 }
71
75 std::string getName() const noexcept { return m_name; }
76 private:
77 std::string m_name;
79 };
80}// End of namespace
Abstract class provide an interface with services to implement physical based algorithm to solve st-V...
Definition Sfx_PhysicalAlgorithm.h:20
Bean that represents a simulation in the framework. Many of the attributes of the simulation bean are...
Definition Sfx_Simulation.h:22
void calculate(dbpp::PhysicalSystem *aPhysys, const std::shared_ptr< dbpp::FiniteVolumeDiscretization > &aGlbdiscr, Sfx::Simulation *aSim) override final
Numerical.
Definition Testvs19_ProtoPhysicalAlgorithm.h:53
std::string getName() const noexcept
Getter.
Definition Testvs19_ProtoPhysicalAlgorithm.h:75
ProtoPhysicalAlgorithm(std::string aName, dbpp::FluxAlgorithm *aFluxAlgo)
Ctor from name and flux algorithm.
Definition Testvs19_ProtoPhysicalAlgorithm.h:44
dbpp::FluxAlgorithm * m_fluxAlgo
Definition Testvs19_ProtoPhysicalAlgorithm.h:78
std::string m_name
Definition Testvs19_ProtoPhysicalAlgorithm.h:77
global discretized domain is defined as a set of all nodes and all elements. PHYSICAL ENTITIES includ...
Definition dbpp_FiniteVolumeDiscretization.h:26
Abstract base class for numerical flux algorithm.
Definition dbpp_FluxAlgorithm.h:24
Physical system made of physical objects under study and described by the state variables....
Definition dbpp_PhysicalSystem.h:32
Definition HydUtils.h:15
Definition Testvs19_BaseRhsPhysicsAlgorithm.cpp:19
Definition DamBreakProb.h:15