DamBreak++ Wave Simulator 0.3
DamBreak++ Simulation Framework
Loading...
Searching...
No Matches
dbpp_FirstDerivative.h
Go to the documentation of this file.
1#pragma once
2
3// numeric include
4#include <valarray>
5// SfxBase19 include
6#include "include/Sfx_DefineTypes.h"
7#include "include/Sfx_UniversalConstants.h"
8
9namespace dbpp
10{
15 {
16 public:
20 enum class eBCtype
21 {
24 };
25 public:
30 FirstDerivative(eBCtype aBcTyp) : m_bcType{ aBcTyp }, m_dx{1.} {}
37 std::valarray<double> d1x( const std::valarray<double>& aArray, float64 aDx);
38
39 void setBCtype() {}
45 float64 getDx() const { return m_dx; }
50 short getDerivativeOrder() const { return 2; }
51
52 private:
55 };
56} // End of namespace
float64 m_dx
Definition dbpp_FirstDerivative.h:54
void setBCtype()
Definition dbpp_FirstDerivative.h:39
FirstDerivative(eBCtype aBcTyp)
ctor
Definition dbpp_FirstDerivative.h:30
std::valarray< double > d1x(const std::valarray< double > &aArray, float64 aDx)
second order derivative (central difference)
Definition dbpp_FirstDerivative.cpp:6
eBCtype
Definition dbpp_FirstDerivative.h:21
@ noncentered
Definition dbpp_FirstDerivative.h:23
@ periodic
Definition dbpp_FirstDerivative.h:22
short getDerivativeOrder() const
derivative order
Definition dbpp_FirstDerivative.h:50
eBCtype m_bcType
Definition dbpp_FirstDerivative.h:53
float64 getDx() const
grid spacing
Definition dbpp_FirstDerivative.h:45
eBCtype getBCtype()
Definition dbpp_FirstDerivative.h:40
Definition DamBreakProb.h:15
double float64
Definition dbpp_LDeltaOperator.h:12