FVAnisotropicDiffusion

Computes residual for anisotropic diffusion operator for finite volume method.

An anisotropic diffusion term that is discretized using the finite-volume method:

where is the diagonal tensor diffusion coefficient and is the diffusing variable. The discretized form of the equation above over en element is the following:

where denotes the surface vector of face of the element. Furthermore, the face gradient, (\nabla \phi)_f, is determined using a central difference scheme combined with non-orthogonal correction. Lastly, components of the diffusion (diagonal) tensor can be either interpolated to the face using a geometric arithmetic average:

or a harmonic average:

where is the interpolation weight, and subscripts and represent element and neighbor values.

[Mesh<<<{"href": "../../syntax/Mesh/index.html"}>>>]
  [cmg]
    type = CartesianMeshGenerator<<<{"description": "This CartesianMeshGenerator creates a non-uniform Cartesian mesh.", "href": "../meshgenerators/CartesianMeshGenerator.html"}>>>
    dim<<<{"description": "The dimension of the mesh to be generated"}>>> = 2
    dx<<<{"description": "Intervals in the X direction"}>>> = '10 10'
    ix<<<{"description": "Number of grids in all intervals in the X direction (default to all one)"}>>> = '2 2'
    dy<<<{"description": "Intervals in the Y direction (required when dim>1 otherwise ignored)"}>>> = '20'
    iy<<<{"description": "Number of grids in all intervals in the Y direction (default to all one)"}>>> = '4'
    subdomain_id<<<{"description": "Block IDs (default to all zero)"}>>> = '1 2'
  []
[]

[Variables<<<{"href": "../../syntax/Variables/index.html"}>>>]
  [v]
    family<<<{"description": "Specifies the family of FE shape functions to use for this variable"}>>> = MONOMIAL
    order<<<{"description": "Specifies the order of the FE shape function to use for this variable (additional orders not listed are allowed)"}>>> = CONSTANT
    fv = true
  []

  [u]
    order<<<{"description": "Specifies the order of the FE shape function to use for this variable (additional orders not listed are allowed)"}>>> = FIRST
    family<<<{"description": "Specifies the family of FE shape functions to use for this variable"}>>> = LAGRANGE
  []
[]

[Kernels<<<{"href": "../../syntax/Kernels/index.html"}>>>]
  [fem_diff1]
    type = AnisotropicDiffusion<<<{"description": "Anisotropic diffusion kernel $\\nabla \\cdot -\\widetilde{k} \\nabla u$ with weak form given by $(\\nabla \\psi_i, \\widetilde{k} \\nabla u)$.", "href": "../kernels/AnisotropicDiffusion.html"}>>>
    variable<<<{"description": "The name of the variable that this residual object operates on"}>>> = u
    tensor_coeff<<<{"description": "The Tensor to multiply the Diffusion operator by"}>>> = '1 0 0
                    0 10 0
                    0 0 0'
    block<<<{"description": "The list of blocks (ids or names) that this object will be applied"}>>> = 1
  []

  [fem_diff2]
    type = AnisotropicDiffusion<<<{"description": "Anisotropic diffusion kernel $\\nabla \\cdot -\\widetilde{k} \\nabla u$ with weak form given by $(\\nabla \\psi_i, \\widetilde{k} \\nabla u)$.", "href": "../kernels/AnisotropicDiffusion.html"}>>>
    variable<<<{"description": "The name of the variable that this residual object operates on"}>>> = u
    tensor_coeff<<<{"description": "The Tensor to multiply the Diffusion operator by"}>>> = '10 0 0
                    0 10 0
                    0 0 0'
    block<<<{"description": "The list of blocks (ids or names) that this object will be applied"}>>> = 2
  []
[]

[BCs<<<{"href": "../../syntax/BCs/index.html"}>>>]
  [fem_left_bottom]
    type = NeumannBC<<<{"description": "Imposes the integrated boundary condition $\\frac{\\partial u}{\\partial n}=h$, where $h$ is a constant, controllable value.", "href": "../bcs/NeumannBC.html"}>>>
    variable<<<{"description": "The name of the variable that this residual object operates on"}>>> = u
    boundary<<<{"description": "The list of boundary IDs from the mesh where this object applies"}>>> = 'left bottom'
    value<<<{"description": "For a Laplacian problem, the value of the gradient dotted with the normals on the boundary."}>>> = 1
  []
  [fem_top_right]
    type = DirichletBC<<<{"description": "Imposes the essential boundary condition $u=g$, where $g$ is a constant, controllable value.", "href": "../bcs/DirichletBC.html"}>>>
    variable<<<{"description": "The name of the variable that this residual object operates on"}>>> = u
    boundary<<<{"description": "The list of boundary IDs from the mesh where this object applies"}>>> = 'right top'
    value<<<{"description": "Value of the BC"}>>> = 0
  []
[]

[FVKernels<<<{"href": "../../syntax/FVKernels/index.html"}>>>]
  [diff]
    type = FVAnisotropicDiffusion<<<{"description": "Computes residual for anisotropic diffusion operator for finite volume method.", "href": "FVAnisotropicDiffusion.html"}>>>
    variable<<<{"description": "The name of the variable that this residual object operates on"}>>> = v
    coeff<<<{"description": "The diagonal coefficients of a diffusion tensor. A functor is any of the following: a variable, a functor material property, a function, a post-processor, or a number."}>>> = coeff
  []
[]

[FVBCs<<<{"href": "../../syntax/FVBCs/index.html"}>>>]
  [left_bottom]
    type = FVNeumannBC<<<{"description": "Neumann boundary condition for finite volume method.", "href": "../fvbcs/FVNeumannBC.html"}>>>
    variable<<<{"description": "The name of the variable that this boundary condition applies to"}>>> = v
    boundary<<<{"description": "The list of boundary IDs from the mesh where this object applies"}>>> = 'left bottom'
    value<<<{"description": "The value of the flux crossing the boundary."}>>> = 1
  []
  [top_right]
    type = FVDirichletBC<<<{"description": "Defines a Dirichlet boundary condition for finite volume method.", "href": "../fvbcs/FVDirichletBC.html"}>>>
    variable<<<{"description": "The name of the variable that this boundary condition applies to"}>>> = v
    boundary<<<{"description": "The list of boundary IDs from the mesh where this object applies"}>>> = 'right top'
    value<<<{"description": "value to enforce at the boundary face"}>>> = 0
  []
[]

[Materials<<<{"href": "../../syntax/Materials/index.html"}>>>]
  [diff1]
    type = ADGenericVectorFunctorMaterial<<<{"description": "FunctorMaterial object for declaring vector properties that are populated by evaluation of functor (constants, functions, variables, matprops) object.", "href": "../functormaterials/GenericVectorFunctorMaterial.html"}>>>
    prop_names<<<{"description": "The names of the properties this material will have"}>>> = 'coeff'
    prop_values<<<{"description": "The corresponding names of the functors that are going to provide the values for the vector material properties"}>>> = '1 10 1'
    block<<<{"description": "The list of blocks (ids or names) that this object will be applied"}>>> = 1
  []

  [diff2]
    type = ADGenericVectorFunctorMaterial<<<{"description": "FunctorMaterial object for declaring vector properties that are populated by evaluation of functor (constants, functions, variables, matprops) object.", "href": "../functormaterials/GenericVectorFunctorMaterial.html"}>>>
    prop_names<<<{"description": "The names of the properties this material will have"}>>> = 'coeff'
    prop_values<<<{"description": "The corresponding names of the functors that are going to provide the values for the vector material properties"}>>> = '10 10 1'
    block<<<{"description": "The list of blocks (ids or names) that this object will be applied"}>>> = 2
  []
[]

[Executioner<<<{"href": "../../syntax/Executioner/index.html"}>>>]
  type = Steady
  solve_type = 'NEWTON'
  petsc_options_iname = '-pc_type -pc_hypre_type'
  petsc_options_value = 'hypre boomeramg'
[]

[Outputs<<<{"href": "../../syntax/Outputs/index.html"}>>>]
  exodus<<<{"description": "Output the results using the default settings for Exodus output."}>>> = true
[]
(moose/test/tests/fvkernels/fv_anisotropic_diffusion/fv_anisotropic_diffusion.i)

Input Parameters

  • coeffThe diagonal coefficients of a diffusion tensor. A functor is any of the following: a variable, a functor material property, a function, a post-processor, or a number.

    C++ Type:MooseFunctorName

    Unit:(no unit assumed)

    Controllable:No

    Description:The diagonal coefficients of a diffusion tensor. A functor is any of the following: a variable, a functor material property, a function, a post-processor, or a number.

  • variableThe name of the variable that this residual object operates on

    C++ Type:NonlinearVariableName

    Unit:(no unit assumed)

    Controllable:No

    Description:The name of the variable that this residual object operates on

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

  • coeff_interp_methodharmonicSwitch that can select face interpolation method for diffusion coefficients.

    Default:harmonic

    C++ Type:MooseEnum

    Options:average, harmonic

    Controllable:No

    Description:Switch that can select face interpolation method for diffusion coefficients.

  • variable_interp_methodaverageSwitch that can select between face interpolation methods for the variable.

    Default:average

    C++ Type:MooseEnum

    Options:average, skewness-corrected

    Controllable:No

    Description:Switch that can select between face interpolation methods for the variable.

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_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_tagsnontimeThe tag for the vectors this Kernel should fill

    Default:nontime

    C++ Type:MultiMooseEnum

    Options:nontime, time

    Controllable:No

    Description:The tag for the vectors this Kernel should fill

Contribution To Tagged Field Data Parameters

  • boundaries_to_avoidThe set of sidesets to not execute this FVFluxKernel on. This takes precedence over force_boundary_execution to restrict to less external boundaries. By default flux kernels are executed on all internal boundaries and Dirichlet boundary conditions.

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

    Controllable:No

    Description:The set of sidesets to not execute this FVFluxKernel on. This takes precedence over force_boundary_execution to restrict to less external boundaries. By default flux kernels are executed on all internal boundaries and Dirichlet boundary conditions.

  • boundaries_to_forceThe set of sidesets to force execution of this FVFluxKernel on. Setting force_boundary_execution to true is equivalent to listing all external mesh boundaries in this parameter.

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

    Controllable:No

    Description:The set of sidesets to force execution of this FVFluxKernel on. Setting force_boundary_execution to true is equivalent to listing all external mesh boundaries in this parameter.

  • 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.

Boundary Execution Modification 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_layers2The number of layers of elements to ghost.

    Default:2

    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

  • prop_getter_suffixAn optional suffix parameter that can be appended to any attempt to retrieve/get material properties. The suffix will be prepended with a '_' character.

    C++ Type:MaterialPropertyName

    Unit:(no unit assumed)

    Controllable:No

    Description:An optional suffix parameter that can be appended to any attempt to retrieve/get material properties. The suffix will be prepended with a '_' character.

  • use_interpolated_stateFalseFor the old and older state use projected material properties interpolated at the quadrature points. To set up projection use the ProjectedStatefulMaterialStorageAction.

    Default:False

    C++ Type:bool

    Controllable:No

    Description:For the old and older state use projected material properties interpolated at the quadrature points. To set up projection use the ProjectedStatefulMaterialStorageAction.

Material Property Retrieval Parameters