Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 5 additions & 9 deletions doc/content/source/tensor_computes/LBMFixedFirstOrderBC.md
Original file line number Diff line number Diff line change
@@ -1,22 +1,18 @@
# LBMFixedFirstOrderBC9Q
# LBMFixedFirstOrderBC

!syntax description /TensorComputes/Solve/LBMFixedFirstOrderBC9Q
!syntax description /TensorComputes/Solve/LBMFixedFirstOrderBC

LBMFixedFirstOrderBC implements Zou\-He velocity boundary conditions at the inlet and outlet for D2Q9, D3Q19 and D3Q27 stencils. The choice of stencil should be indicated in the name of the compute object such as LBMFixedFirstOrderBC9Q for D2Q9.
LBMFixedFirstOrderBC implements Zou\-He velocity boundary conditions at the inlet and outlet for D2Q9, D3Q19 and D3Q27 stencils.

## Overview

Enforces first\-order accurate macroscopic velocity at selected domain faces via Zou\-He formulas.
Choose faces with [!param](/TensorComputes/Solve/LBMFixedFirstOrderBC9Q/boundary) and provide
Choose faces with [!param](/TensorComputes/Solve/LBMFixedFirstOrderBC/boundary) and provide
macroscopic fields as required by the implementation.

## Example Input File Syntax

!listing test/tests/lbm/vertical_velocity_bcs.i block=TensorComputes/Boundary/top
!listing test/tests/lbm/vertical_velocity_bcs.i block=TensorComputes/Boundary/bottom

!syntax parameters /TensorComputes/Solve/LBMFixedFirstOrderBC9Q

!syntax inputs /TensorComputes/Solve/LBMFixedFirstOrderBC9Q

!syntax children /TensorComputes/Solve/LBMFixedFirstOrderBC9Q
!syntax parameters /TensorComputes/Solve/LBMFixedFirstOrderBC
16 changes: 6 additions & 10 deletions doc/content/source/tensor_computes/LBMFixedZerothOrderBC.md
Original file line number Diff line number Diff line change
@@ -1,22 +1,18 @@
# LBMFixedZerothOrderBC9Q
# LBMFixedZerothOrderBC

!syntax description /TensorComputes/Solve/LBMFixedZerothOrderBC9Q
!syntax description /TensorComputes/Solve/LBMFixedZerothOrderBC

LBMFixedZerothOrderBC implements Zou-He pressure boundary conditions at the inlet and outlet for D2Q9, D3Q19 and D3Q27 stencils. The choice of stencil should be indicated in the name of the compute object such as LBMFixedZerothOrderBC9Q for D2Q9.
LBMFixedZerothOrderBC implements Zou-He pressure boundary conditions at the inlet and outlet for D2Q9, D3Q19 and D3Q27 stencils.

## Overview

LBMFixedZerothOrderBC implements Zou\-He pressure boundary conditions at the inlet and outlet for D2Q9, D3Q19 and D3Q27 stencils. The choice of stencil should be indicated in the name of the compute object such as LBMFixedZerothOrderBC9Q for D2Q9.
Choose faces with [!param](/TensorComputes/Solve/LBMFixedZerothOrderBC9Q/boundary) and provide macroscopic fields as
LBMFixedZerothOrderBC implements Zou\-He pressure boundary conditions at the inlet and outlet for D2Q9, D3Q19 and D3Q27 stencils.
Choose faces with [!param](/TensorComputes/Solve/LBMFixedZerothOrderBC/boundary) and provide macroscopic fields as
required by the implementation.

## Example Input File Syntax

!listing test/tests/lbm/vertical_density_bcs.i block=TensorComputes/Boundary/top
!listing test/tests/lbm/vertical_density_bcs.i block=TensorComputes/Boundary/bottom

!syntax parameters /TensorComputes/Solve/LBMFixedZerothOrderBC9Q

!syntax inputs /TensorComputes/Solve/LBMFixedZerothOrderBC9Q

!syntax children /TensorComputes/Solve/LBMFixedZerothOrderBC9Q
!syntax parameters /TensorComputes/Solve/LBMFixedZerothOrderBC
2 changes: 1 addition & 1 deletion examples/lbm/Formula1-aerodynamics/f1.i
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@
[]

[left]
type = LBMFixedFirstOrderBC27Q
type = LBMFixedFirstOrderBC
buffer=f
f=f
value=0.01
Expand Down
2 changes: 1 addition & 1 deletion examples/lbm/Karman-vortex/cylinder.i
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@
boundary = wall
[]
[left]
type = LBMFixedFirstOrderBC9Q
type = LBMFixedFirstOrderBC
buffer=f
f=f
value='Ux'
Expand Down
4 changes: 2 additions & 2 deletions examples/lbm/Pebbles/pebbles.i
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,7 @@
[Boundary]
##### for fluid
[inlet]
type = LBMFixedFirstOrderBC19Q
type = LBMFixedFirstOrderBC
buffer = f
f = f
value = u0
Expand Down Expand Up @@ -293,7 +293,7 @@

##### for temperature
[t_inlet]
type = LBMFixedZerothOrderBC19Q
type = LBMFixedZerothOrderBC
buffer = g
f = g
value = T_C
Expand Down
4 changes: 2 additions & 2 deletions examples/lbm/Rayleigh-Benard/boundary.i
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,15 @@

##### for temperature
[temperature_g_top]
type = LBMFixedZerothOrderBC9Q
type = LBMFixedZerothOrderBC
buffer = g
f = g
value = T_C
boundary = top
[]

[temperature_g_bottom]
type = LBMFixedZerothOrderBC9Q
type = LBMFixedZerothOrderBC
buffer = g
f = g
value = T_H
Expand Down
13 changes: 6 additions & 7 deletions include/tensor_computes/LBMFixedFirstOrderBC.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,20 +13,23 @@
/**
* LBMFixedFirstOrderBC object
*/
template <int dimension>
class LBMFixedFirstOrderBCTempl : public LBMBoundaryCondition
class LBMFixedFirstOrderBC : public LBMBoundaryCondition
{
public:
static InputParameters validParams();

LBMFixedFirstOrderBCTempl(const InputParameters & parameters);
LBMFixedFirstOrderBC(const InputParameters & parameters);

void init() override {};

void topBoundary() override;
void topBoundaryD2Q9();
void bottomBoundary() override;
void bottomBoundaryD2Q9();
void leftBoundary() override;
void leftBoundaryD2Q9();
void rightBoundary() override;
void rightBoundaryD2Q9();
void frontBoundary() override;
void backBoundary() override;
void computeBuffer() override;
Expand All @@ -37,7 +40,3 @@ class LBMFixedFirstOrderBCTempl : public LBMBoundaryCondition
const Real & _value;
const bool _perturb;
};

typedef LBMFixedFirstOrderBCTempl<9> LBMFixedFirstOrderBC9Q;
typedef LBMFixedFirstOrderBCTempl<19> LBMFixedFirstOrderBC19Q;
typedef LBMFixedFirstOrderBCTempl<27> LBMFixedFirstOrderBC27Q;
13 changes: 6 additions & 7 deletions include/tensor_computes/LBMFixedZerothOrderBC.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,18 +13,21 @@
/**
* LBMFixedZerothOrderBC object
*/
template <int dimension>
class LBMFixedZerothOrderBCTempl : public LBMBoundaryCondition
class LBMFixedZerothOrderBC : public LBMBoundaryCondition
{
public:
static InputParameters validParams();

LBMFixedZerothOrderBCTempl(const InputParameters & parameters);
LBMFixedZerothOrderBC(const InputParameters & parameters);

void topBoundary() override;
void topBoundaryD2Q9();
void bottomBoundary() override;
void bottomBoundaryD2Q9();
void leftBoundary() override;
void leftBoundaryD2Q9();
void rightBoundary() override;
void rightBoundaryD2Q9();
void frontBoundary() override;
void backBoundary() override;
void computeBuffer() override;
Expand All @@ -34,7 +37,3 @@ class LBMFixedZerothOrderBCTempl : public LBMBoundaryCondition
const std::array<int64_t, 3> _grid_size;
const Real _value;
};

typedef LBMFixedZerothOrderBCTempl<9> LBMFixedZerothOrderBC9Q;
typedef LBMFixedZerothOrderBCTempl<19> LBMFixedZerothOrderBC19Q;
typedef LBMFixedZerothOrderBCTempl<27> LBMFixedZerothOrderBC27Q;
Loading