OpenLB 1.7
Loading...
Searching...
No Matches
superGeometryFaces3D.h
Go to the documentation of this file.
1/* This file is part of the OpenLB library
2 *
3 * Copyright (C) 2013-2018 Mathias Krause, Albert Mink, Adrian Kummerlaender
4 * E-mail contact: info@openlb.net
5 * The most recent release of OpenLB can be downloaded at
6 * <http://www.openlb.net/>
7 *
8 * This program is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU General Public License
10 * as published by the Free Software Foundation; either version 2
11 * of the License, or (at your option) any later version.
12 *
13 * This program is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU General Public License for more details.
17 *
18 * You should have received a copy of the GNU General Public
19 * License along with this program; if not, write to the Free
20 * Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
21 * Boston, MA 02110-1301, USA.
22*/
23
24#ifndef SUPER_GEOMETRY_FACES_3D_H
25#define SUPER_GEOMETRY_FACES_3D_H
26
27#include "superBaseF3D.h"
30
31namespace olb {
32
33
36
39template <typename T>
40class SuperGeometryFaces3D final : public SuperF3D<T> {
41private:
43public:
46 T _latticeL);
48 SuperGeometryFaces3D(SuperGeometry<T,3>& superGeometry, const int material,
49 T _latticeL);
50
52 template<typename DESCRIPTOR>
54 const UnitConverter<T,DESCRIPTOR>& converter)
55 : SuperGeometryFaces3D(std::forward<decltype(indicatorF)>(indicatorF),
56 converter.getConversionFactorLength()) { };
58 template<typename DESCRIPTOR>
59 SuperGeometryFaces3D(SuperGeometry<T,3>& superGeometry, const int material,
60 const UnitConverter<T,DESCRIPTOR>& converter)
61 : SuperGeometryFaces3D(superGeometry.getMaterialIndicator(material), converter) { };
62
63 bool operator() (T output[], const int input[]) override;
64
65};
66
68template <typename T, bool HLBM>
69class SuperGeometryFacesIndicator3D final : public GenericF<T,int> {
70private:
71 SuperGeometry<T,3>& _superGeometry;
73 const int _material;
74 T _latticeL;
75public:
76 SuperGeometryFacesIndicator3D(SuperGeometry<T,3>& superGeometry, SmoothIndicatorF3D<T,T,HLBM>& indicator, const int material,
77 T deltaX);
78 bool operator() (T output[], const int input[]) override;
79};
80
81}
82
83#endif
Smart pointer for managing the various ways of passing functors around.
Definition functorPtr.h:60
GenericF is a base class, that can represent continuous as well as discrete functions.
Definition genericF.h:50
represents all functors that operate on a SuperStructure<T,3> in general
Accumulates the discrete surface of indicated cells facing unit directions and returns the individual...
SuperGeometryFaces3D(FunctorPtr< SuperIndicatorF3D< T > > &&indicatorF, T _latticeL)
Constructor accepting solid cell indicator and custom lattice length.
SuperGeometryFaces3D(FunctorPtr< SuperIndicatorF3D< T > > &&indicatorF, const UnitConverter< T, DESCRIPTOR > &converter)
Constructor accepting solid cell indicator and a unit converter to query lattice length.
SuperGeometryFaces3D(SuperGeometry< T, 3 > &superGeometry, const int material, const UnitConverter< T, DESCRIPTOR > &converter)
Constructor accepting single solid cell material and a unit converter to query lattice length.
bool operator()(T output[], const int input[]) override
functor counts to get the discrete surface for a material no. and SmoothIndicator in direction (1,...
bool operator()(T output[], const int input[]) override
has to be implemented for 'every' derived class
SuperGeometryFacesIndicator3D(SuperGeometry< T, 3 > &superGeometry, SmoothIndicatorF3D< T, T, HLBM > &indicator, const int material, T deltaX)
Representation of a statistic for a parallel 2D geometry.
Base indicator functor (discrete)
Conversion between physical and lattice units, as well as discretization.
Top level namespace for all of OpenLB.