chombo-discharge
Loading...
Searching...
No Matches
CD_EBGeometryIF.H
Go to the documentation of this file.
1/*
2 * SPDX-FileCopyrightText: 2021-2026 SINTEF Energy Research
3 *
4 * SPDX-License-Identifier: GPL-3.0-or-later
5 */
6
13#ifndef CD_EBGEOMETRYIF_H
14#define CD_EBGEOMETRYIF_H
15
16// Std includes
17#include <memory>
18
19// Chombo includes
20#include <BaseIF.H>
21#include <IntersectionIF.H>
22
23// EBGeometry includes
24#include <EBGeometry.hpp>
25
26// Our includes
27#include <CD_NamespaceHeader.H>
28
35template <typename T = Real>
36class EBGeometryIF : public BaseIF
37{
38public:
43
50 EBGeometryIF(const std::shared_ptr<EBGeometry::ImplicitFunction<T>>& a_sdf,
51 const bool a_flipInside,
52 const Real a_zCoord = 0.0);
53
58 EBGeometryIF(const EBGeometryIF& a_inputIF);
59
63 virtual ~EBGeometryIF();
64
70 virtual Real
71 value(const RealVect& a_point) const override;
72
77 virtual BaseIF*
78 newImplicitFunction() const override;
79
80protected:
84 std::shared_ptr<const EBGeometry::ImplicitFunction<T>> m_sdf;
85
90
95};
96
97#include <CD_NamespaceFooter.H>
98
100
101#endif
Implementation of CD_EBGeometryIF.H.
Shallow binding of EBGeometry signed distance functions to Chombo.
Definition CD_EBGeometryIF.H:37
virtual ~EBGeometryIF()
Destructor. Does nothing.
Definition CD_EBGeometryIFImplem.H:47
std::shared_ptr< const EBGeometry::ImplicitFunction< T > > m_sdf
Signed distance function.
Definition CD_EBGeometryIF.H:84
EBGeometryIF()
Constructor. Sets shape to nullptr.
Definition CD_EBGeometryIFImplem.H:20
virtual BaseIF * newImplicitFunction() const override
IF factory method.
Definition CD_EBGeometryIFImplem.H:73
Real m_zCoord
z-coordinate through which the object is sliced.
Definition CD_EBGeometryIF.H:94
virtual Real value(const RealVect &a_point) const override
Value function. Returns distance to object.
Definition CD_EBGeometryIFImplem.H:54
bool m_flipInside
Hook for making outside -> inside.
Definition CD_EBGeometryIF.H:89