![]() |
OpenLB 1.8.1
|
BlockReduction3D1D reduces the data of a SuperF3D functor to the intersection between a given 3D line3D and the super geometry. More...
#include <blockReduction3D1D.h>
Inheritance diagram for olb::BlockReduction3D1D< T >:
Collaboration diagram for olb::BlockReduction3D1D< T >:Public Member Functions | |
| BlockReduction3D1D (FunctorPtr< SuperF3D< T > > &&f, const LineLattice3D< T > &lattice, BlockDataSyncMode syncMode=BlockDataSyncMode::ReduceAndBcast, BlockDataReductionMode reductionMode=BlockDataReductionMode::Analytical) | |
| Construction using functor and line3D lattice. | |
| BlockReduction3D1D (FunctorPtr< SuperF3D< T > > &&f, const Line3D< T > &line3D, BlockDataSyncMode syncMode=BlockDataSyncMode::ReduceAndBcast, BlockDataReductionMode reductionMode=BlockDataReductionMode::Analytical) | |
| Construction using functor and line3D. | |
| BlockReduction3D1D (FunctorPtr< SuperF3D< T > > &&f, const Line3D< T > &line3D, int resolution=600, BlockDataSyncMode mode=BlockDataSyncMode::ReduceAndBcast) | |
| Construction using functor, line3D and resolution. | |
| BlockReduction3D1D (FunctorPtr< SuperF3D< T > > &&f, const Vector< T, 3 > &origin, const Vector< T, 3 > &direction, int resolution=600, BlockDataSyncMode mode=BlockDataSyncMode::ReduceAndBcast) | |
| Construction using functor, origin, direction and resolution. | |
| bool | operator() (T output[], int i) |
| Custom operator for easier access to 1-dimensional block data. | |
| void | initialize () |
| Initialize rank-local list of plane points to be stored in _blockData. | |
| void | update () |
| Updates and writes the data to _blockData using _rankLocalSubplane. | |
| BlockStructureD< 2 > & | getBlockStructure () override |
| Overload of virtual function from class BlockF2D. | |
| const std::vector< std::tuple< int, int > > & | getRankLocalSubplane () const |
Public Member Functions inherited from olb::LineLattice3D< T > | |
| LineLattice3D (CuboidDecomposition< T, 3 > &geometry, Line3D< T > line3D) | |
| Constructor for automatic discretization. | |
| LineLattice3D (CuboidDecomposition< T, 3 > &geometry, Line3D< T > line3D, int resolution) | |
| Constructor for discretization of a given resolution. | |
| LineLattice3D (CuboidDecomposition< T, 3 > &geometry, Line3D< T > line3D, T h) | |
| Constructor for discretization of a given grid width. | |
| LineLattice3D (const LineLattice3D &)=default | |
| const Line3D< T > & | getLine3D () const |
| Vector< T, 3 > | getPhysR (const int &n) const |
| Transform 1d lattice coordinates to their physical 3d location. | |
| int | getN () const |
| T | getPhysSpacing () const |
| Vector< T, 3 > | getPhysOrigin () const |
| Vector< T, 3 > | getVectorU () const |
Public Member Functions inherited from olb::BlockDataF2D< T, T > | |
| BlockDataF2D (BlockData< 2, T, T > &blockData) | |
| Constructor. | |
| BlockDataF2D (BlockF2D< T > &f) | |
| to store functor data, constuctor creates _blockData with functor data | |
| ~BlockDataF2D () | |
| BlockData< 2, T, T > & | getBlockData () |
| returns _blockData | |
| bool | operator() (T output[], const int input[]) override |
| access to _blockData via its get() | |
Public Member Functions inherited from olb::BlockF2D< T > | |
| void | setBlockStructure (BlockStructureD< 2 > *blockStructure) |
| BlockF2D< T > & | operator- (BlockF2D< T > &rhs) |
| BlockF2D< T > & | operator+ (BlockF2D< T > &rhs) |
| BlockF2D< T > & | operator* (BlockF2D< T > &rhs) |
| BlockF2D< T > & | operator/ (BlockF2D< T > &rhs) |
Public Member Functions inherited from olb::GenericF< T, int > | |
| virtual | ~GenericF ()=default |
| int | getSourceDim () const |
| read only access to member variable _m | |
| int | getTargetDim () const |
| read only access to member variable _n | |
| std::string & | getName () |
| read and write access to name | |
| std::string const & | getName () const |
| read only access to name | |
| virtual bool | operator() (T output[], const int input[])=0 |
| has to be implemented for 'every' derived class | |
| bool | operator() (T output[]) |
| wrapper that call the pure virtual operator() (T output[], const S input[]) from above | |
| bool | operator() (T output[], int input0) |
| bool | operator() (T output[], int input0, int input1) |
| bool | operator() (T output[], int input0, int input1, int input2) |
| bool | operator() (T output[], int input0, int input1, int input2, int input3) |
Additional Inherited Members | |
Public Types inherited from olb::GenericF< T, int > | |
| using | targetType |
| using | sourceType |
Public Attributes inherited from olb::GenericF< T, int > | |
| std::shared_ptr< GenericF< T, int > > | _ptrCalcC |
| memory management, frees resouces (calcClass) | |
Protected Member Functions inherited from olb::BlockDataF2D< T, T > | |
| BlockDataF2D (int nx, int ny, int size=1) | |
Protected Member Functions inherited from olb::BlockF2D< T > | |
| BlockF2D (BlockStructureD< 2 > &blockStructure, int targetDim) | |
| BlockF2D (int targetDim) | |
Protected Member Functions inherited from olb::GenericF< T, int > | |
| GenericF (int targetDim, int sourceDim) | |
Protected Attributes inherited from olb::LineLattice3D< T > | |
| const Line3D< T > | _line3D |
| Vector< T, 3 > | _origin |
| Origin vector of the lattice. | |
| Vector< T, 3 > | _u |
| Direction vector of the lattice, normalized to grid width _h. | |
| T | _h |
| Distance between discrete lattice points. | |
| int | _n |
| Number of lattice points in the direction of _u. | |
Protected Attributes inherited from olb::BlockDataF2D< T, T > | |
| BlockData< 2, T, T > * | _blockData |
| bool | _owning |
Protected Attributes inherited from olb::BlockF2D< T > | |
| BlockStructureD< 2 > * | _blockStructure |
BlockReduction3D1D reduces the data of a SuperF3D functor to the intersection between a given 3D line3D and the super geometry.
This intersection is interpolated at a set of discrete points according to the given resolution and exposed as a 1-dimensional BlockDataF2D functor.
The line3D is parametrized by a origin and a single direction vector u. Definition of line3D using e.g. origin and normal vectors is supported via the line3D interface.
Definition at line 54 of file blockReduction3D1D.h.
| olb::BlockReduction3D1D< T >::BlockReduction3D1D | ( | FunctorPtr< SuperF3D< T > > && | f, |
| const LineLattice3D< T > & | lattice, | ||
| BlockDataSyncMode | syncMode = BlockDataSyncMode::ReduceAndBcast, | ||
| BlockDataReductionMode | reductionMode = BlockDataReductionMode::Analytical ) |
Construction using functor and line3D lattice.
| f | Functor to be reduced as a (non-)owning pointer or reference to SuperF3D<T>. |
| lattice | Line3D lattice parametrization |
| syncMode | Defines MPI synchronization strategy of the interpolated block data. |
| reductionMode | Defines whether data is interpolated or read from discrete lattice locations. Note: BlockDataReductionMode::Analytical imposes restrictions on line3D definition and discretization. |
Definition at line 84 of file blockReduction3D1D.hh.
References olb::Discrete, olb::LineLattice3D< T >::getLine3D(), olb::GenericF< T, int >::getName(), olb::LineLattice3D< T >::getPhysSpacing(), olb::BlockReduction3D1D< T >::initialize(), and olb::BlockReduction3D1D< T >::update().
Here is the call graph for this function:| olb::BlockReduction3D1D< T >::BlockReduction3D1D | ( | FunctorPtr< SuperF3D< T > > && | f, |
| const Line3D< T > & | line3D, | ||
| BlockDataSyncMode | syncMode = BlockDataSyncMode::ReduceAndBcast, | ||
| BlockDataReductionMode | reductionMode = BlockDataReductionMode::Analytical ) |
Construction using functor and line3D.
| f | Functor to be reduced as a (non-)owning pointer or reference to SuperF3D<T>. |
| line3D | Line3D parametrization |
| syncMode | Defines MPI synchronization strategy of the interpolated block data. |
| reductionMode | Defines whether data is interpolated or read from discrete lattice locations. |
Definition at line 121 of file blockReduction3D1D.hh.
| olb::BlockReduction3D1D< T >::BlockReduction3D1D | ( | FunctorPtr< SuperF3D< T > > && | f, |
| const Line3D< T > & | line3D, | ||
| int | resolution = 600, | ||
| BlockDataSyncMode | mode = BlockDataSyncMode::ReduceAndBcast ) |
Construction using functor, line3D and resolution.
| f | Functor to be reduced as a (non-)owning pointer or reference to SuperF3D<T>. |
| line3D | Line3D parametrization |
| resolution | Defines the number of voxel of the longest side. If it equals zero, _h is set to the cuboid geometry's minDeltaR. |
| mode | Defines MPI synchronization strategy of the interpolated block data. |
Definition at line 133 of file blockReduction3D1D.hh.
| olb::BlockReduction3D1D< T >::BlockReduction3D1D | ( | FunctorPtr< SuperF3D< T > > && | f, |
| const Vector< T, 3 > & | origin, | ||
| const Vector< T, 3 > & | direction, | ||
| int | resolution = 600, | ||
| BlockDataSyncMode | mode = BlockDataSyncMode::ReduceAndBcast ) |
Construction using functor, origin, direction and resolution.
| f | Functor to be reduced as a (non-)owning pointer or reference to SuperF3D<T>. |
| direction | Direction vector |
| origin | Origin vector |
| resolution | Defines the number of voxel of the longest side. If it equals zero, _h is set to the cuboid geometry's minDeltaR. |
| mode | Defines MPI synchronization strategy of the interpolated block data. |
Definition at line 144 of file blockReduction3D1D.hh.
|
overridevirtual |
Overload of virtual function from class BlockF2D.
Reimplemented from olb::BlockF2D< T >.
Definition at line 229 of file blockReduction3D1D.hh.
| const std::vector< std::tuple< int, int > > & olb::BlockReduction3D1D< T >::getRankLocalSubplane | ( | ) | const |
Definition at line 235 of file blockReduction3D1D.hh.
| void olb::BlockReduction3D1D< T >::initialize | ( | ) |
Initialize rank-local list of plane points to be stored in _blockData.
Definition at line 161 of file blockReduction3D1D.hh.
References olb::LoadBalancer< T >::isLocal().
Here is the call graph for this function:
Here is the caller graph for this function:| bool olb::BlockReduction3D1D< T >::operator() | ( | T | output[], |
| int | i ) |
Custom operator for easier access to 1-dimensional block data.
Definition at line 154 of file blockReduction3D1D.hh.
| void olb::BlockReduction3D1D< T >::update | ( | ) |
Updates and writes the data to _blockData using _rankLocalSubplane.
Definition at line 183 of file blockReduction3D1D.hh.
References olb::Analytical, olb::singleton::MpiManager::bCast(), olb::Discrete, olb::singleton::mpi(), olb::None, olb::singleton::MpiManager::reduce(), olb::ReduceAndBcast, and olb::ReduceOnly.
Here is the call graph for this function:
Here is the caller graph for this function: