boundary_pressure Subroutine

public subroutine boundary_pressure(mesh, bc, face_id, interior_p, ext_p, is_dirichlet)

Evaluates pressure at a boundary face.

Arguments

Type IntentOptional Attributes Name
type(mesh_t), intent(in) :: mesh
type(bc_set_t), intent(in) :: bc
integer, intent(in) :: face_id
real(kind=rk), intent(in) :: interior_p
real(kind=rk), intent(out) :: ext_p
logical, intent(out) :: is_dirichlet

Called by

proc~~boundary_pressure~~CalledByGraph proc~boundary_pressure mod_bc::boundary_pressure proc~pressure_gradient_cell mod_flow_projection::pressure_gradient_cell proc~pressure_gradient_cell->proc~boundary_pressure proc~compute_momentum_rhs mod_flow_projection::compute_momentum_rhs proc~compute_momentum_rhs->proc~pressure_gradient_cell proc~advance_projection_step mod_flow_projection::advance_projection_step proc~advance_projection_step->proc~compute_momentum_rhs program~lowmach_react_hex lowmach_react_hex program~lowmach_react_hex->proc~advance_projection_step

Source Code

   subroutine boundary_pressure(mesh, bc, face_id, interior_p, ext_p, is_dirichlet)
      type(mesh_t), intent(in) :: mesh
      type(bc_set_t), intent(in) :: bc
      integer, intent(in) :: face_id
      real(rk), intent(in) :: interior_p
      real(rk), intent(out) :: ext_p
      logical, intent(out) :: is_dirichlet

      integer :: patch_id

      patch_id = mesh%faces(face_id)%patch
      if (patch_id <= 0) then
         ext_p = interior_p
         is_dirichlet = .false.
         return
      end if

      select case (bc%patches(patch_id)%pressure_type_id)
      case (bc_dirichlet)
         ext_p = bc%patches(patch_id)%pressure
         is_dirichlet = .true.
      case default
         ext_p = interior_p
         is_dirichlet = .false.
      end select
   end subroutine boundary_pressure