rsvs3D  0.0.0
Codes for the c++ implementation of the 3D RSVS
voxel.hpp File Reference

Generation of cartesian grids. More...

#include <Eigen>
#include <iostream>
#include <numeric>
#include "arraystructures.hpp"
#include "postprocessing.hpp"

Go to the source code of this file.

Functions

template<class T >
cumsum (const T &matIn, int d)
 template which applies cumulative sum to Eigen Matrix. More...
 
template<class T >
cumprod (const T &matIn, int d)
 template which applies cumulative product to Eigen Matrix. More...
 
int BuildBlockGrid (std::array< int, 3 > &dimGrid, mesh &blockGrid)
 
int BuildBlockGrid (const Eigen::RowVector3i &dimGrid, mesh &blockGrid)
 
int BuildBlockVert (const Eigen::RowVector3i &dimGrid, mesh &blockGrid, int nVert, const Eigen::Matrix3i &edgeProp, const Eigen::RowVector3i &nEdgeDim)
 
int BuildBlockEdge (const Eigen::RowVector3i &dimGrid, mesh &blockGrid, int nEdge, const Eigen::RowVector3i &nEdgeDim, const Eigen::RowVector3i &nSurfDim, const Eigen::Matrix3i &edgeProp, const Eigen::Matrix3i &surfProp)
 
int BuildBlockSurf (const Eigen::RowVector3i &dimGrid, int nSurf, mesh &blockGrid, const Eigen::Matrix3i &surfProp, const Eigen::Matrix3i &edgeProp, const Eigen::RowVector3i &nSurfDim, const Eigen::RowVector3i &nEdgeDim)
 
int BuildBlockVolu (const Eigen::RowVector3i &dimGrid, int nVolu, mesh &blockGrid, const Eigen::RowVector3i &nSurfDim, const Eigen::Matrix3i &surfProp)
 
int Test_BuildBlockGrid_noout ()
 
int Test_MeshOut ()
 
int Test_MeshOut2 ()
 
int Test_MeshOut_Size (Eigen::RowVector3i dimGrid, bool runReOrder=false)
 
int Test_MeshReOrder ()
 

Detailed Description

Generation of cartesian grids.

Definition in file voxel.hpp.

Function Documentation

◆ cumprod()

template<class T >
T cumprod ( const T &  matIn,
int  d 
)

template which applies cumulative product to Eigen Matrix.

Cumprod is applied row-wise for d=0 and col-wise for d=1

Parameters
[in]matInThe matrix input
[in]ddimension to use 0-row wise, 1 col-wise
Template Parameters
TEigen type
Returns
The cumulative product.

Definition at line 99 of file voxel.hpp.

◆ cumsum()

template<class T >
T cumsum ( const T &  matIn,
int  d 
)

template which applies cumulative sum to Eigen Matrix.

Cumprod is applied row-wise for d=0 and col-wise for d=1

Parameters
[in]matInThe matrix input
[in]ddimension to use 0-row wise, 1 col-wise
Template Parameters
TEigen type
Returns
The cumulative sum.

Definition at line 61 of file voxel.hpp.