LinearPWCNSFVMomentumFlux

Momentum flux kernel with porous-specific advection handling.

Description

LinearPWCNSFVMomentumFlux specializes LinearWCNSFVMomentumFlux for momentum equations whose unknown is superficial velocity. The PorousRhieChowMassFlux user object provides the face mass flux and the porosity on each side of the face. The advection contribution assembled into a cell row is scaled by that cell's inverse porosity, so the mass flux transports interstitial velocity.

At a pressure baffle the superficial velocity jumps, so the advection operator does not use the state interpolated across the baffle. Both sides advect the upstream interstitial tangential velocity, and both sides advect the normal velocity recovered from the shared mass flux and the face density. The BernoulliFormLossPressureJump model supplies the reversible Bernoulli pressure jump and any irreversible form loss, as described below.

The stress discretization does not add another baffle loss. Away from baffles it is the face-interpolated stress of LinearWCNSFVMomentumFlux; on a baffle it transmits only the shear traction described in Stress treatment on a pressure baffle. Density and viscosity must vary continuously: they are interpolated to faces, so a step in either property is treated as a steep continuous variation rather than as an interface. Porosity must be positive on every active face.

Advection treatment across a porosity jump

Let be superficial velocity and be interstitial velocity. For momentum component , the conservative porous advection term is

(1)

Applying the product rule separates this term into

(2)

LinearPWCNSFVMomentumFlux uses the approximation

(3)

so is pulled outside the divergence cell by cell. This approximation is exact where porosity is constant. It does not directly discretize the second term in Eq. (2), which contains the porosity gradient and becomes singular at a sharp porosity interface.

For an internal face between cells and , let , with directed from to . The ordinary internal-face contributions are

(4)

where is supplied by the interpolation method selected with "advected_interp_method_name".

On a face that is not a pressure baffle, nothing replaces the omitted porosity-gradient term. Advection treatment on a pressure baffle describes the interface closure used on baffles.

Advection treatment on a pressure baffle

A pressure baffle is an internal face on a boundary of one of the pressure jump models listed in "pressure_jump_models". A baffle usually coincides with a porosity discontinuity, across which the tangential superficial velocity jumps, as described in Stress treatment on a pressure baffle. With equal porosity on both sides, the reversible jump below vanishes and the baffle carries only its form loss.

On a baffle, the shared interpolated state is replaced by a baffle face state built from the face velocities extrapolated from each row's cell with its own velocity gradient,

with and . The gradients come from FVVelocityJumpGreenGaussGradient, so they do not see the jump. Both rows advect the interstitial tangential velocity of the upstream side ( if , otherwise ),

and both rows the normal superficial velocity recovered from the shared mass flux and the face-interpolated density :

(5)

The tangential momentum flux is then the same on both sides, so the baffle is no source of tangential momentum, and an inviscid stream crossing the baffle keeps its interstitial tangential velocity. If each side advected its own extrapolated state instead, the face would act as the source , and an inviscid solution would keep whatever tangential jump the iteration produced. The normal momentum fluxes still differ between the sides through the porosity; the pressure jump below balances them. The normal part satisfies mass conservation exactly and is the same on both rows. Density is assumed to vary smoothly across the baffle, as in BernoulliFormLossPressureJump, so one face density stands in for both sides; a density discontinuity at the baffle is not represented. The tangential face state is exact for a velocity that is linear on each side with a continuous interstitial tangential velocity. The implicit stencil keeps the shared interpolation weights and the difference is deferred to the right-hand side.

On a baffle, the BernoulliFormLossPressureJump model replaces the omitted porosity-gradient term with the reversible Bernoulli pressure jump. With and the owner and non-owner sides, chosen from the mesh as described on that page, the jump is

(6)

where is the face-interpolated density. This closure recovers the steady one-dimensional inviscid Bernoulli balance, but it does not reproduce the omitted term in general multidimensional flow. Any configured irreversible form loss is added to this reversible jump.

Stress treatment across a porosity jump

Let denote superficial velocity, where is interstitial velocity. The porous viscous stress is

(7)

Porosity is taken to be constant within each cell adjacent to a sharp interface. Consequently, on either side ,

(8)

and the corresponding transpose and divergence terms simplify in the same way. Away from pressure baffles, the stress is therefore the standard stress of LinearWCNSFVMomentumFlux, evaluated with gradients of superficial velocity and the face viscosity . One common superficial face velocity is used, so the interstitial velocity jumps with porosity.

The baffle stress in Stress treatment on a pressure baffle is built from half-cell quantities. Consider an internal face between cells and , with unit normal directed from to . Define the two half-cell vectors and distances as

(9)

These projected distances are used when "use_nonorthogonal_correction" is enabled. Otherwise, and . For momentum component , the side-local nonorthogonal corrections expressed using superficial velocity are

(10)

When "use_nonorthogonal_correction" is disabled, both corrections in Eq. (10) are zero. When "use_deviatoric_terms" is enabled, each side also contributes

(11)

For axisymmetric coordinates, the divergence in Eq. (11) includes the cylindrical contribution.

This treatment assumes that porosity is piecewise constant and that its discontinuity is handled as an interface. For porosity that varies smoothly within a cell,

(12)

so the additional porosity-gradient term requires a separate volumetric treatment. Likewise, a baffle model that includes an independent viscous or tangential surface force requires a corresponding traction-jump condition instead of the continuous-viscous-traction assumption used here.

Stress treatment on a pressure baffle

On a pressure baffle the superficial velocity itself jumps: mass conservation keeps continuous, so with continuous density the normal superficial velocity is continuous, but the tangential superficial velocity jumps with porosity. A common superficial face velocity would read this jump as a gradient. A baffle represents an interface that is sharp on the mesh scale, and the viscous (Brinkman) layer on the porous side of such an interface is of the order of the square root of the permeability, much thinner than the adjacent cells. The baffle stress is therefore a shear traction that depends on the kind of fluid on each side. A side of unit porosity is clear fluid; any other side is a porous medium.

  • Between two porous sides, the shear in the Brinkman layers is negligible against the drag, and no traction is transmitted.

  • A clear side shears against the porous side as against a rough wall that moves with the superficial velocity of the porous medium at the interface.

  • Between two clear sides, the traction is the ordinary two-point traction.

Porosity serves here only as an indicator that drag dominates shear on a side. The model holds when the square root of the permeability is much smaller than the cell size, as in packed beds. It does not suit a side of unit porosity that carries a drag term, such as a screen, nor a sparse medium whose Brinkman layer spans the adjacent cells.

With the set of clear sides, the traction is

(13)

where the traction is zero if neither side is clear. The face velocity of a clear side is the two-point value or , in which collects the nonorthogonal corrections of Eq. (10) for all velocity components. The face velocity of a porous side is the extrapolated face state of Advection treatment on a pressure baffle, which the baffle advection also uses. It approximates the porous velocity at the interface to second order; the cell value would leave a traction error of order that does not vanish under refinement, because the velocity difference is divided by the clear half-cell distance. For two clear sides, is the ordinary two-point transmissibility.

No normal viscous stress acts on a baffle face. The BernoulliFormLossPressureJump carries the normal momentum balance, and a normal stress of the interstitial velocity would read the jump of as a gradient. The element row adds and the neighbor row , so momentum is conserved; on a porous side the drag absorbs the traction. The part proportional to is assembled implicitly with the coefficient ; the remainder, including the coupling to the other velocity components, is lagged on the right-hand side. With "use_deviatoric_terms" enabled, each clear side adds its own deviatoric correction explicitly.

Example Input Syntax

In this example, LinearPWCNSFVMomentumFlux assembles the x-momentum equation for superficial velocity in a channel containing porous interfaces.

[LinearFVKernels<<<{"href": "../../syntax/LinearFVKernels/index.html"}>>>]
  [u_advection]
    type = LinearPWCNSFVMomentumFlux<<<{"description": "Momentum flux kernel with porous-specific advection handling.", "href": "LinearPWCNSFVMomentumFlux.html"}>>>
    variable<<<{"description": "The name of the variable whose linear system this object contributes to"}>>> = superficial_u
    advected_interp_method_name<<<{"description": "Name of the FVInterpolationMethod to use for the advected velocity."}>>> = ${advected_interp_method}
    mu<<<{"description": "The diffusion coefficient. A functor is any of the following: a variable, a functor material property, a function, a postprocessor or a number."}>>> = dynamic_viscosity
    u<<<{"description": "The velocity in the x direction."}>>> = superficial_u
    v<<<{"description": "The velocity in the y direction."}>>> = superficial_v
    momentum_component<<<{"description": "The component of the momentum equation that this kernel applies to."}>>> = 'x'
    rhie_chow_user_object<<<{"description": "The rhie-chow user-object which is used to determine the face velocity."}>>> = rc
    use_nonorthogonal_correction<<<{"description": "If the nonorthogonal correction should be used when computing the normal gradient."}>>> = false
  []
[]
(modules/navier_stokes/test/tests/finite_volume/pins/channel-flow/linear-segregated/2d-diagonal-baffle/porous-baffle-straight-diagonal.i)

Input Parameters

  • advected_interp_method_nameName of the FVInterpolationMethod to use for the advected velocity.

    C++ Type:InterpolationMethodName

    Controllable:No

    Description:Name of the FVInterpolationMethod to use for the advected velocity.

  • momentum_componentThe component of the momentum equation that this kernel applies to.

    C++ Type:MooseEnum

    Options:x, y, z

    Controllable:No

    Description:The component of the momentum equation that this kernel applies to.

  • muThe diffusion coefficient. A functor is any of the following: a variable, a functor material property, a function, a postprocessor or a number.

    C++ Type:MooseFunctorName

    Unit:(no unit assumed)

    Controllable:No

    Description:The diffusion coefficient. A functor is any of the following: a variable, a functor material property, a function, a postprocessor or a number.

  • rhie_chow_user_objectThe rhie-chow user-object which is used to determine the face velocity.

    C++ Type:UserObjectName

    Controllable:No

    Description:The rhie-chow user-object which is used to determine the face velocity.

  • uThe velocity in the x direction.

    C++ Type:SolverVariableName

    Unit:(no unit assumed)

    Controllable:No

    Description:The velocity in the x direction.

  • variableThe name of the variable whose linear system this object contributes to

    C++ Type:LinearVariableName

    Unit:(no unit assumed)

    Controllable:No

    Description:The name of the variable whose linear system this object contributes to

Required Parameters

  • blockThe list of blocks (ids or names) that this object will be applied

    C++ Type:std::vector<SubdomainName>

    Controllable:No

    Description:The list of blocks (ids or names) that this object will be applied

  • force_boundary_executionFalseWhether to force execution of this object on all external boundaries.

    Default:False

    C++ Type:bool

    Controllable:No

    Description:Whether to force execution of this object on all external boundaries.

  • use_deviatoric_termsFalseIf deviatoric terms in the stress terms need to be used.

    Default:False

    C++ Type:bool

    Controllable:No

    Description:If deviatoric terms in the stress terms need to be used.

  • use_nonorthogonal_correctionTrueIf the nonorthogonal correction should be used when computing the normal gradient.

    Default:True

    C++ Type:bool

    Controllable:No

    Description:If the nonorthogonal correction should be used when computing the normal gradient.

  • vThe velocity in the y direction.

    C++ Type:SolverVariableName

    Unit:(no unit assumed)

    Controllable:No

    Description:The velocity in the y direction.

  • wThe velocity in the z direction.

    C++ Type:SolverVariableName

    Unit:(no unit assumed)

    Controllable:No

    Description:The velocity in the z direction.

Optional Parameters

  • absolute_value_vector_tagsThe tags for the vectors this residual object should fill with the absolute value of the residual contribution

    C++ Type:std::vector<TagName>

    Controllable:No

    Description:The tags for the vectors this residual object should fill with the absolute value of the residual contribution

  • extra_matrix_tagsThe extra tags for the matrices this Kernel should fill

    C++ Type:std::vector<TagName>

    Controllable:No

    Description:The extra tags for the matrices this Kernel should fill

  • extra_vector_tagsThe extra tags for the vectors this Kernel should fill

    C++ Type:std::vector<TagName>

    Controllable:No

    Description:The extra tags for the vectors this Kernel should fill

  • matrix_onlyFalseWhether this object is only doing assembly to matrices (no vectors)

    Default:False

    C++ Type:bool

    Controllable:No

    Description:Whether this object is only doing assembly to matrices (no vectors)

  • matrix_tagssystemThe tag for the matrices this Kernel should fill

    Default:system

    C++ Type:MultiMooseEnum

    Options:nontime, system

    Controllable:No

    Description:The tag for the matrices this Kernel should fill

  • vector_tagsrhsThe tag for the vectors this Kernel should fill

    Default:rhs

    C++ Type:MultiMooseEnum

    Options:rhs, time

    Controllable:No

    Description:The tag for the vectors this Kernel should fill

Contribution To Tagged Field Data Parameters

  • control_tagsAdds user-defined labels for accessing object parameters via control logic.

    C++ Type:std::vector<std::string>

    Controllable:No

    Description:Adds user-defined labels for accessing object parameters via control logic.

  • enableTrueSet the enabled status of the MooseObject.

    Default:True

    C++ Type:bool

    Controllable:Yes

    Description:Set the enabled status of the MooseObject.

  • implicitTrueDetermines whether this object is calculated using an implicit or explicit form

    Default:True

    C++ Type:bool

    Controllable:No

    Description:Determines whether this object is calculated using an implicit or explicit form

  • seed0The seed for the master random number generator

    Default:0

    C++ Type:unsigned int

    Controllable:No

    Description:The seed for the master random number generator

  • use_displaced_meshFalseWhether or not this object should use the displaced mesh for computation. Note that in the case this is true but no displacements are provided in the Mesh block the undisplaced mesh will still be used.

    Default:False

    C++ Type:bool

    Controllable:No

    Description:Whether or not this object should use the displaced mesh for computation. Note that in the case this is true but no displacements are provided in the Mesh block the undisplaced mesh will still be used.

Advanced Parameters

  • ghost_layers1The number of layers of elements to ghost.

    Default:1

    C++ Type:unsigned short

    Controllable:No

    Description:The number of layers of elements to ghost.

  • use_point_neighborsFalseWhether to use point neighbors, which introduces additional ghosting to that used for simple face neighbors.

    Default:False

    C++ Type:bool

    Controllable:No

    Description:Whether to use point neighbors, which introduces additional ghosting to that used for simple face neighbors.

Parallel Ghosting Parameters

Input Files