forked from idaholab/moose
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Hybrid channel flow test (idaholab#24055)
- Loading branch information
Showing
3 changed files
with
208 additions
and
0 deletions.
There are no files selected for viewing
200 changes: 200 additions & 0 deletions
200
modules/navier_stokes/test/tests/finite_volume/ins/lid-driven/channel-hybrid.i
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,200 @@ | ||
mu = 1.1 | ||
rho = 1.1 | ||
|
||
[Mesh] | ||
[gen] | ||
type = GeneratedMeshGenerator | ||
dim = 2 | ||
xmin = 0 | ||
xmax = 10 | ||
ymin = -1 | ||
ymax = 1 | ||
nx = 100 | ||
ny = 20 | ||
[] | ||
[] | ||
|
||
[Variables] | ||
[u] | ||
family = MONOMIAL | ||
[] | ||
[v] | ||
family = MONOMIAL | ||
[] | ||
[pressure][] | ||
[] | ||
|
||
[Kernels] | ||
[momentum_x_convection] | ||
type = ADConservativeAdvection | ||
variable = u | ||
velocity = 'velocity' | ||
advected_quantity = 'rhou' | ||
[] | ||
[momentum_x_diffusion] | ||
type = MatDiffusion | ||
variable = u | ||
diffusivity = 'mu' | ||
[] | ||
[momentum_x_pressure] | ||
type = DGMomentumPressure | ||
variable = u | ||
pressure = pressure | ||
component = 0 | ||
[] | ||
[momentum_y_convection] | ||
type = ADConservativeAdvection | ||
variable = v | ||
velocity = 'velocity' | ||
advected_quantity = 'rhov' | ||
[] | ||
[momentum_y_diffusion] | ||
type = MatDiffusion | ||
variable = v | ||
diffusivity = 'mu' | ||
[] | ||
[momentum_y_pressure] | ||
type = DGMomentumPressure | ||
variable = v | ||
pressure = pressure | ||
component = 1 | ||
[] | ||
[mass] | ||
type = CGMass | ||
variable = pressure | ||
velocity = velocity | ||
[] | ||
[] | ||
|
||
[DGKernels] | ||
[momentum_x_convection] | ||
type = ADDGConvection | ||
variable = u | ||
velocity = 'velocity' | ||
advected_quantity = 'rhou' | ||
[] | ||
[momentum_x_diffusion] | ||
type = DGDiffusion | ||
variable = u | ||
sigma = 6 | ||
epsilon = -1 | ||
diff = 'mu' | ||
[] | ||
[momentum_y_convection] | ||
type = ADDGConvection | ||
variable = v | ||
velocity = 'velocity' | ||
advected_quantity = 'rhov' | ||
[] | ||
[momentum_y_diffusion] | ||
type = DGDiffusion | ||
variable = v | ||
sigma = 6 | ||
epsilon = -1 | ||
diff = 'mu' | ||
[] | ||
[] | ||
|
||
[Functions] | ||
[v_inlet] | ||
type = ParsedVectorFunction | ||
expression_x = '1' | ||
[] | ||
[] | ||
|
||
[BCs] | ||
[u_walls] | ||
type = DGFunctionDiffusionDirichletBC | ||
boundary = 'bottom top' | ||
variable = u | ||
sigma = 6 | ||
epsilon = -1 | ||
function = '0' | ||
diff = 'mu' | ||
[] | ||
[v_walls] | ||
type = DGFunctionDiffusionDirichletBC | ||
boundary = 'bottom top' | ||
variable = v | ||
sigma = 6 | ||
epsilon = -1 | ||
function = '0' | ||
diff = 'mu' | ||
[] | ||
[u_in] | ||
type = ADDGConvectionBC | ||
boundary = 'left' | ||
variable = u | ||
velocity_function = v_inlet | ||
primal_dirichlet_value = 1 | ||
rho = 'rho' | ||
[] | ||
[v_in] | ||
type = ADDGConvectionBC | ||
boundary = 'left' | ||
variable = v | ||
velocity_function = v_inlet | ||
primal_dirichlet_value = 0 | ||
rho = 'rho' | ||
[] | ||
[p_in] | ||
type = ADDGConvectionBC | ||
boundary = 'left' | ||
variable = pressure | ||
velocity_function = v_inlet | ||
# Have to switch sign because we multiplied the mass equation weak | ||
# form by -1 in order to get a symmetric matrix | ||
primal_dirichlet_value = -1 | ||
[] | ||
[u_out] | ||
type = ADDGConvectionBC | ||
boundary = 'right' | ||
variable = u | ||
velocity_mat_prop = 'velocity' | ||
advected_quantity = 'rhou' | ||
[] | ||
[v_out] | ||
type = ADDGConvectionBC | ||
boundary = 'right' | ||
variable = v | ||
velocity_mat_prop = 'velocity' | ||
advected_quantity = 'rhov' | ||
[] | ||
[p_out] | ||
type = DirichletBC | ||
variable = pressure | ||
boundary = 'right' | ||
value = 0 | ||
[] | ||
[] | ||
|
||
[Materials] | ||
[const] | ||
type = ADGenericConstantMaterial | ||
prop_names = 'rho' | ||
prop_values = '${rho}' | ||
[] | ||
[const_reg] | ||
type = GenericConstantMaterial | ||
prop_names = 'mu' | ||
prop_values = '${mu}' | ||
[] | ||
[vel] | ||
type = CGDGMaterial | ||
u = u | ||
v = v | ||
rho = 'rho' | ||
[] | ||
[] | ||
|
||
[Executioner] | ||
type = Steady | ||
solve_type = 'NEWTON' | ||
petsc_options_iname = '-pc_type -pc_factor_shift_type' | ||
petsc_options_value = 'lu NONZERO' | ||
nl_rel_tol = 1e-12 | ||
[] | ||
|
||
[Outputs] | ||
exodus = true | ||
[] |
Binary file added
BIN
+263 KB
modules/navier_stokes/test/tests/finite_volume/ins/lid-driven/gold/channel-hybrid_out.e
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters