OpenLB 1.7
Loading...
Searching...
No Matches
superLatticeIntegralF2D.h
Go to the documentation of this file.
1/* This file is part of the OpenLB library
2 *
3 * Copyright (C) 2012-2017 Lukas Baron, Tim Dornieden, Mathias J. Krause,
4 * Albert Mink, Benjamin Förster, Adrian Kummerlaender
5 * E-mail contact: info@openlb.net
6 * The most recent release of OpenLB can be downloaded at
7 * <http://www.openlb.net/>
8 *
9 * This program is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU General Public License
11 * as published by the Free Software Foundation; either version 2
12 * of the License, or (at your option) any later version.
13 *
14 * This program is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 * GNU General Public License for more details.
18 *
19 * You should have received a copy of the GNU General Public
20 * License along with this program; if not, write to the Free
21 * Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
22 * Boston, MA 02110-1301, USA.
23*/
24
25#ifndef SUPER_LATTICE_INTEGRAL_F_2D_H
26#define SUPER_LATTICE_INTEGRAL_F_2D_H
27
28#include <vector>
29
30#include "functors/genericF.h"
32#include "superBaseF2D.h"
39#include "core/superLattice2D.h"
40#include "core/vector.h"
41#include "io/ostreamManager.h"
47
48/* Note: Throughout the whole source code directory genericFunctions, the
49 * template parameters for i/o dimensions are:
50 * F: S^m -> T^n (S=source, T=target)
51 */
52
53namespace olb {
54
58
59
61template <typename T, typename DESCRIPTOR>
62class SuperLatticePhysDrag2D final : public SuperLatticePhysF2D<T,DESCRIPTOR> {
63private:
67 SuperSum2D<T,T> _sumF;
68
69 const T _factor;
70public:
72 FunctorPtr<SuperIndicatorF2D<T>>&& indicatorF,
73 const UnitConverter<T,DESCRIPTOR>& converter);
75 SuperGeometry<T,2>& superGeometry, const int material,
76 const UnitConverter<T,DESCRIPTOR>& converter);
77
78 bool operator() (T output[], const int input[]) override;
79};
80
82
85template <typename T, typename DESCRIPTOR>
86class SuperLatticePhysCorrDrag2D final : public SuperLatticePhysF2D<T,DESCRIPTOR> {
87private:
91 SuperSum2D<T,T> _sumF;
92
93 const T _factor;
94public:
96 FunctorPtr<SuperIndicatorF2D<T>>&& indicatorF,
97 const UnitConverter<T,DESCRIPTOR>& converter);
99 SuperGeometry<T,2>& superGeometry, const int material,
100 const UnitConverter<T,DESCRIPTOR>& converter);
101
102 bool operator() (T output[], const int input[]) override;
103};
104
105
106} // end namespace olb
107
108#endif
Smart pointer for managing the various ways of passing functors around.
Definition functorPtr.h:60
Accumulates the discrete surface of indicated cells facing unit directions and returns the individual...
Representation of a statistic for a parallel 2D geometry.
functor to get pointwise phys force acting on a boundary with a given material on local lattice
functor to get pointwise phys force acting on a boundary with a given material on local lattice see: ...
functor to get pointwise phys force acting on a indicated boundary on local lattice
SuperLatticePhysCorrDrag2D(SuperLattice< T, DESCRIPTOR > &sLattice, FunctorPtr< SuperIndicatorF2D< T > > &&indicatorF, const UnitConverter< T, DESCRIPTOR > &converter)
bool operator()(T output[], const int input[]) override
functor to get pointwise phys force acting on a indicated boundary on local lattice
bool operator()(T output[], const int input[]) override
SuperLatticePhysDrag2D(SuperLattice< T, DESCRIPTOR > &sLattice, FunctorPtr< SuperIndicatorF2D< T > > &&indicatorF, const UnitConverter< T, DESCRIPTOR > &converter)
represents all functors that operate on a DESCRIPTOR with output in Phys, e.g. physVelocity(),...
Super class maintaining block lattices for a cuboid decomposition.
SuperSum2D sums all components of f over a indicated subset.
Conversion between physical and lattice units, as well as discretization.
The description of a generic interface for all functor classes – header file.
Top level namespace for all of OpenLB.
Representation of a parallel 2D geometry – header file.
The description of a 2D super lattice – header file.
efficient implementation of a vector class