This module contains data types, function and routines for gradient computation.
author: Gregorio Gerardo Spinelli
function pointer to get pdf equilibrium from vel and density
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | rho |
density |
||
real(kind=rk), | intent(in) | :: | vel(3) |
velocity |
||
integer, | intent(in) | :: |
size of the stencil |
|||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
|
real(kind=rk), | intent(in), | optional | :: | weight(:) |
weight along iDir |
function pointer to get pdf equilibrium from vel and density along a
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | rho |
density |
||
real(kind=rk), | intent(in) | :: | vel(3) |
velocity |
||
integer, | intent(in) | :: | iDir |
direction of the pdf |
||
real(kind=rk), | intent(in) | :: | cxDirRK(3) |
velocity streaming normal along iDir |
||
real(kind=rk), | intent(in) | :: | weight |
weight along iDir |
function pointer to get pdf equilibrium from vel and density
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | pdf(:) |
|
||
real(kind=rk), | intent(in) | :: | dens |
density |
||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
velocity
function pointer to get pdf equilibrium from vel and density VECTORIZED
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | pdf(:,:) |
|
||
real(kind=rk), | intent(in) | :: | dens(:) |
density |
||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
|
integer, | intent(in) | :: | nSolve |
number of element to compute |
velocity
function pointer to get pdf equilibrium from vel and density
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | vel(:) |
velocity |
||
real(kind=rk), | intent(in) | :: | dens |
density |
momentum
function pointer to get pdf equilibrium from vel and density
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | vel(:) |
velocity |
||
real(kind=rk), | intent(in) | :: | dens |
density |
momentum
function pointer to get 1/rho as a mask regardless incompressibility
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | dens |
density |
inverse of density regardless compressibility
collection of properties of the scheme derived quantities type
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
procedure(get_pdfEq), | public, | nopass, pointer | :: | pdfEq_ptr | => | null() |
function pointer to get pdf equilibrium from vel and density |
procedure(get_pdfEq_iDir), | public, | nopass, pointer | :: | pdfEq_iDir_ptr | => | null() |
function pointer to get pdf equilibrium in a specific direction |
procedure(get_vel_from_pdf), | public, | nopass, pointer | :: | vel_from_pdf_ptr | => | null() |
function pointer to get velocities from pdf |
procedure(get_vel_from_pdf_vectorized), | public, | nopass, pointer | :: | vel_from_pdf_vectorized_ptr | => | null() |
function pointer to get velocities from pdf VECTORIZED |
procedure(get_vector_from_vel_dens), | public, | nopass, pointer | :: | momentum_from_vel_dens_ptr | => | null() |
function pointer to get momentum |
procedure(get_scalar_from_vel_dens), | public, | nopass, pointer | :: | kineticEnergy_from_vel_dens_ptr | => | null() |
function pointer to get kinetic energy |
procedure(get_rho0Inv), | public, | nopass, pointer | :: | rho0Inv_ptr | => | null() |
function pointer to get 1/rho as a mask regardless incompressibility |
This function assigns the pointers for the respective derived function in
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
character(len=labelLen), | intent(in) | :: | label_stencil |
Scheme header information |
||
character(len=labelLen), | intent(in) | :: | label_fluid |
Fluid label information |
getQuantities function
function pointer to get pdf equilibrium from vel and density along a
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | rho |
density |
||
real(kind=rk), | intent(in) | :: | vel(3) |
velocity |
||
integer, | intent(in) | :: | iDir |
direction of the pdf |
||
real(kind=rk), | intent(in) | :: | cxDirRK(3) |
velocity streaming normal along iDir |
||
real(kind=rk), | intent(in) | :: | weight |
weight along iDir |
function pointer to get pdf equilibrium from vel and density along a
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | rho |
density |
||
real(kind=rk), | intent(in) | :: | vel(3) |
velocity |
||
integer, | intent(in) | :: | iDir |
direction of the pdf |
||
real(kind=rk), | intent(in) | :: | cxDirRK(3) |
velocity streaming normal along iDir |
||
real(kind=rk), | intent(in) | :: | weight |
weight along iDir |
function pointer to get pdf equilibrium from vel and density along a
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | rho |
density |
||
real(kind=rk), | intent(in) | :: | vel(3) |
velocity |
||
integer, | intent(in) | :: |
size of the pdf |
|||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
|
real(kind=rk), | intent(in), | optional | :: | weight(:) |
weight along iDir |
function pointer to get pdf equilibrium from vel and density along a
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | rho |
density |
||
real(kind=rk), | intent(in) | :: | vel(3) |
velocity |
||
integer, | intent(in) | :: |
size of the pdf |
|||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
|
real(kind=rk), | intent(in), | optional | :: | weight(:) |
weight along iDir |
This function computes the sigma vector necessary to get the
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | vel(3) |
velocity |
This function computes the equilibrium pdf from velocity
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | rho |
density |
||
real(kind=rk), | intent(in) | :: | vel(3) |
velocity |
||
integer, | intent(in) | :: |
size of the pdf |
|||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
|
real(kind=rk), | intent(in), | optional | :: | weight(:) |
weight along iDir |
This function computes the incompressible equilibrium pdf from velocity
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | rho |
density |
||
real(kind=rk), | intent(in) | :: | vel(3) |
velocity |
||
integer, | intent(in) | :: |
size of the pdf |
|||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
|
real(kind=rk), | intent(in), | optional | :: | weight(:) |
weight along iDir |
This function computes the sigma vector necessary to get the
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | vel(3) |
velocity |
This function computes the equilibrium pdf from velocity
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | rho |
density |
||
real(kind=rk), | intent(in) | :: | vel(3) |
velocity |
||
integer, | intent(in) | :: |
size of the pdf |
|||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
|
real(kind=rk), | intent(in), | optional | :: | weight(:) |
weight along iDir |
This function computes the incompressible equilibrium pdf from velocity
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | rho |
density |
||
real(kind=rk), | intent(in) | :: | vel(3) |
velocity |
||
integer, | intent(in) | :: |
size of the pdf |
|||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
|
real(kind=rk), | intent(in), | optional | :: | weight(:) |
weight along iDir |
This function computes the sigma vector necessary to get the
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | vel(3) |
velocity |
This function computes the equilibrium pdf from velocity
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | rho |
density |
||
real(kind=rk), | intent(in) | :: | vel(3) |
velocity |
||
integer, | intent(in) | :: |
size of the pdf |
|||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
|
real(kind=rk), | intent(in), | optional | :: | weight(:) |
weight along iDir |
This function computes the incompressible equilibrium pdf from velocity
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | rho |
density |
||
real(kind=rk), | intent(in) | :: | vel(3) |
velocity |
||
integer, | intent(in) | :: |
size of the pdf |
|||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
|
real(kind=rk), | intent(in), | optional | :: | weight(:) |
weight along iDir |
function pointer to get pdf equilibrium from vel and density for any stencil
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | pdf(:) |
|
||
real(kind=rk), | intent(in) | :: | dens |
density |
||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
velocity
function pointer to get pdf equilibrium from vel and density for any stencil
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | pdf(:,:) |
|
||
real(kind=rk), | intent(in) | :: | dens(:) |
density |
||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
|
integer, | intent(in) | :: | nSolve |
number of element to compute |
velocity
function pointer to get pdf equilibrium from vel and density for any stencil
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | pdf(:) |
|
||
real(kind=rk), | intent(in) | :: | dens |
density |
||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
velocity
function pointer to get pdf equilibrium from vel and density for any stencil
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | pdf(:,:) |
|
||
real(kind=rk), | intent(in) | :: | dens(:) |
density |
||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
|
integer, | intent(in) | :: | nSolve |
number of element to compute |
velocity
function pointer to get pdf equilibrium from vel and density for d2q9 stencil
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | pdf(:) |
|
||
real(kind=rk), | intent(in) | :: | dens |
density |
||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
velocity
function pointer to get pdf equilibrium from vel and density for any stencil
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | pdf(:,:) |
|
||
real(kind=rk), | intent(in) | :: | dens(:) |
density |
||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
|
integer, | intent(in) | :: | nSolve |
number of element to compute |
velocity
function pointer to get pdf equilibrium from vel and density for d2q9 stencil
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | pdf(:) |
|
||
real(kind=rk), | intent(in) | :: | dens |
density |
||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
velocity
function pointer to get pdf equilibrium from vel and density for any stencil
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | pdf(:,:) |
|
||
real(kind=rk), | intent(in) | :: | dens(:) |
density |
||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
|
integer, | intent(in) | :: | nSolve |
number of element to compute |
velocity
function pointer to get pdf equilibrium from vel and density for d3q19 stencil
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | pdf(:) |
|
||
real(kind=rk), | intent(in) | :: | dens |
density |
||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
velocity
function pointer to get pdf equilibrium from vel and density for any stencil
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | pdf(:,:) |
|
||
real(kind=rk), | intent(in) | :: | dens(:) |
density |
||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
|
integer, | intent(in) | :: | nSolve |
number of element to compute |
velocity
function pointer to get pdf equilibrium from vel and density for d3q19 stencil
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | pdf(:) |
|
||
real(kind=rk), | intent(in) | :: | dens |
density |
||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
velocity
function pointer to get pdf equilibrium from vel and density for any stencil
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | pdf(:,:) |
|
||
real(kind=rk), | intent(in) | :: | dens(:) |
density |
||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
|
integer, | intent(in) | :: | nSolve |
number of element to compute |
velocity
function pointer to get pdf equilibrium from vel and density for d3q27 stencil
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | pdf(:) |
|
||
real(kind=rk), | intent(in) | :: | dens |
density |
||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
velocity
function pointer to get pdf equilibrium from vel and density for any stencil
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | pdf(:,:) |
|
||
real(kind=rk), | intent(in) | :: | dens(:) |
density |
||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
|
integer, | intent(in) | :: | nSolve |
number of element to compute |
velocity
function pointer to get pdf equilibrium from vel and density for d3q27 stencil
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | pdf(:) |
|
||
real(kind=rk), | intent(in) | :: | dens |
density |
||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
velocity
function pointer to get pdf equilibrium from vel and density for any stencil
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | pdf(:,:) |
|
||
real(kind=rk), | intent(in) | :: | dens(:) |
density |
||
real(kind=rk), | intent(in), | optional | :: | cxDirRK(:,:) |
velocity streaming normal along iDir |
|
integer, | intent(in) | :: | nSolve |
number of element to compute |
velocity
function pointer to get momentum from vel and density for any stencil
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | vel(:) |
velocity |
||
real(kind=rk), | intent(in) | :: | dens |
density |
momentum
function pointer to get momentum from vel and density for any stencil
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | vel(:) |
velocity |
||
real(kind=rk), | intent(in) | :: | dens |
density |
momentum
function pointer to get kineticEnergy from vel and density for any stencil
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | vel(:) |
velocity |
||
real(kind=rk), | intent(in) | :: | dens |
density |
kineticEnergy
function pointer to get kineticEnergy from vel and density for any stencil
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | vel(:) |
velocity |
||
real(kind=rk), | intent(in) | :: | dens |
density |
kineticEnergy
function pointer to get kineticEnergy from vel and density for any stencil
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | dens |
density |
kineticEnergy
function pointer to get kineticEnergy from vel and density for any stencil
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(in) | :: | dens |
density |
kineticEnergy