pyLBM.stencil.Velocity

class pyLBM.stencil.Velocity(dim=None, num=None, vx=None, vy=None, vz=None)

Create a velocity.

Parameters:

dim : int, optional

The dimension of the velocity.

num : int, optional

The number of the velocity in the numbering convention of Lattice-Boltzmann scheme.

vx : int, optional

The x component of the velocity vector.

vy : int, optional

The y component of the velocity vector.

vz : int, optional

The z component of the velocity vector.

Notes

(Source code)

Examples

Create a velocity with the dimension and the number

>>> v = Velocity(dim = 1, num = 2)
>>> v
velocity 2
 vx: -1

Create a velocity with a direction

>>> v = Velocity(vx=1, vy=1)
>>> v
velocity 5
 vx: 1
 vy: 1

Attributes

v velocity
dim (int) The dimension of the velocity.
num The number of the velocity in the numbering convention of Lattice-Boltzmann scheme.
vx (int) The x component of the velocity vector.
vy (int) The y component of the velocity vector.
vz (int) The z component of the velocity vector.

Methods

get_symmetric([axis]) return the symmetric velocity.
set_symmetric() create the symetric velocity.