mantaflow  0.10
A framework for fluid simulation
commonkernels.h
Go to the documentation of this file.
1 
2 /******************************************************************************
3  *
4  * MantaFlow fluid solver framework
5  * Copyright 2011 Tobias Pfaff, Nils Thuerey
6  *
7  * This program is free software, distributed under the terms of the
8  * GNU General Public License (GPL)
9  * http://www.gnu.org/licenses
10  *
11  * Common grid kernels
12  *
13  ******************************************************************************/
14 
15 #ifndef _COMMONKERNELS_H
16 #define _COMMONKERNELS_H
17 
18 #include "general.h"
19 #include "kernel.h"
20 #include "grid.h"
21 
22 namespace Manta {
23 
26 void InvertCheckFluid (FlagGrid& flags, Grid<Real>& grid) {}
27 
28 
31 double GridSumSqr (Grid<Real>& grid) {}
32 
33 
36 void CurlOp (const Grid<Vec3>& grid, Grid<Vec3>& dst) {}
37 ;
38 
41 void DivergenceOpMAC(Grid<Real>& div, const MACGrid& grid) {}
42 
43 
46 void GradientOpMAC(MACGrid& gradient, const Grid<Real>& grid) {}
47 
48 
51 void GradientOp(Grid<Vec3>& gradient, const Grid<Real>& grid) {}
52 
53 
56 void LaplaceOp(Grid<Real>& laplace, const Grid<Real>& grid) {}
57 
58 
61 void GetShiftedComponent(const Grid<Vec3>& grid, Grid<Real>& comp, int dim) {}
62 ;
63 
66 void GetComponent(const Grid<Vec3>& grid, Grid<Real>& comp, int dim) {}
67 ;
68 
71 void GridNorm(Grid<Real>& n, const Grid<Vec3>& grid) {}
72 ;
73 
76 void SetComponent(Grid<Vec3>& grid, const Grid<Real>& comp, int dim) {}
77 ;
78 
81 void GetCentered(Grid<Vec3>& center, const MACGrid& vel) {}
82 ;
83 
86 void GetMAC(MACGrid& vel, const Grid<Vec3>& center) {}
87 ;
88 
91 void FillInBoundary(Grid<Vec3>& grid, int g) {}
92 
93 
94 
95 // ****************************************************************************
96 
97 // helper functions for converting mex data to manta grids and back (for matlab integration)
98 
99 // MAC grids
101 void kn_conv_mex_in_to_MAC(const double *p_lin_array, MACGrid *p_result) {}
102 
103 
105 void kn_conv_MAC_to_mex_out(const MACGrid *p_mac, double *p_result) {}
106 
107 
108 // Vec3 Grids
110 void kn_conv_mex_in_to_Vec3(const double *p_lin_array, Grid<Vec3> *p_result) {}
111 
112 
114 void kn_conv_Vec3_to_mex_out(const Grid<Vec3> *p_Vec3, double *p_result) {}
115 
116 
117 // Real Grids
119 void kn_conv_mex_in_to_Real(const double *p_lin_array, Grid<Real> *p_result) {}
120 
121 
123 void kn_conv_Real_to_mex_out(const Grid<Real> *p_grid, double *p_result) {}
124 
125 
126 
127 } // namespace
128 #endif
129 
130 
Definition: commonkernels.h:22
void GradientOp(Grid< Vec3 > &gradient, const Grid< Real > &grid)
Definition: commonkernels.h:51
Definition: grid.h:267
void DivergenceOpMAC(Grid< Real > &div, const MACGrid &grid)
Definition: commonkernels.h:41
void CurlOp(const Grid< Vec3 > &grid, Grid< Vec3 > &dst)
Definition: commonkernels.h:36
Definition: grid.h:229
void GetComponent(const Grid< Vec3 > &grid, Grid< Real > &comp, int dim)
Definition: commonkernels.h:66
double GridSumSqr(Grid< Real > &grid)
Definition: commonkernels.h:31
void SetComponent(Grid< Vec3 > &grid, const Grid< Real > &comp, int dim)
Definition: commonkernels.h:76
void GradientOpMAC(MACGrid &gradient, const Grid< Real > &grid)
Definition: commonkernels.h:46
void LaplaceOp(Grid< Real > &laplace, const Grid< Real > &grid)
Definition: commonkernels.h:56
void GridNorm(Grid< Real > &n, const Grid< Vec3 > &grid)
Definition: commonkernels.h:71
void GetCentered(Grid< Vec3 > &center, const MACGrid &vel)
Definition: commonkernels.h:81
void GetShiftedComponent(const Grid< Vec3 > &grid, Grid< Real > &comp, int dim)
Definition: commonkernels.h:61
void InvertCheckFluid(FlagGrid &flags, Grid< Real > &grid)
Definition: commonkernels.h:26
void FillInBoundary(Grid< Vec3 > &grid, int g)
Definition: commonkernels.h:91
void GetMAC(MACGrid &vel, const Grid< Vec3 > &center)
Definition: commonkernels.h:86