chombo-discharge
Loading...
Searching...
No Matches
CD_SphereArray.H
Go to the documentation of this file.
1/* chombo-discharge
2 * Copyright © 2022 SINTEF Energy Research.
3 * Please refer to Copyright.txt and LICENSE in the chombo-discharge root directory.
4 */
5
12#ifndef CD_SphereArray_H
13#define CD_SphereArray_H
14
15// Chombo includes
16#include <BaseIF.H>
17
18// Our includes
19#include <EBGeometry.hpp>
20#include <CD_NamespaceHeader.H>
21
22using AABB = EBGeometry::BoundingVolumes::AABBT<Real>;
23using Vec3 = EBGeometry::Vec3T<Real>;
24using SDF = EBGeometry::SignedDistanceFunction<Real>;
25using Sphere = EBGeometry::SphereSDF<Real>;
26
30class SphereArray : public BaseIF
31{
32public:
36 SphereArray() = delete;
37
49 const RealVect a_loCenter,
52 const bool a_useFast,
53 const bool a_flipInside,
54 const Real a_zCoord = 0.0);
55
60
64 virtual ~SphereArray();
65
70 virtual Real
71 value(const RealVect& a_point) const override;
72
76 virtual BaseIF*
77 newImplicitFunction() const override;
78
79protected:
83 static constexpr size_t K = 4;
84
89
94
99
104};
105
106#include <CD_NamespaceFooter.H>
107
108#endif
A Cartesian array of spheres.
Definition CD_SphereArray.H:31
bool m_flipInside
Make inside to outside.
Definition CD_SphereArray.H:93
virtual Real value(const RealVect &a_point) const override
Value function.
Definition CD_SphereArray.cpp:88
std::shared_ptr< EBGeometry::ImplicitFunction< Real > > m_fastUnion
Union that uses bounding volume hierarchy acceleration.
Definition CD_SphereArray.H:103
virtual ~SphereArray()
Destructor (does nothing)
Definition CD_SphereArray.cpp:82
SphereArray()=delete
Disallowed (for now)
std::shared_ptr< EBGeometry::ImplicitFunction< Real > > m_slowUnion
Standard union ala Chombo.
Definition CD_SphereArray.H:98
bool m_useFast
Switch for using fast or slow union.
Definition CD_SphereArray.H:88
virtual BaseIF * newImplicitFunction() const override
Factory method – calls the copy constructor.
Definition CD_SphereArray.cpp:115
static constexpr size_t K
Tree degree for BVH accelerator.
Definition CD_SphereArray.H:83
Base class for a tracer particle solver. This solver can advance particles in a pre-defined velocity ...
Definition CD_TracerParticleSolver.H:37
TracerParticleSolver()
Default constructor.
Definition CD_TracerParticleSolverImplem.H:25