leith_biharm_is_inert Function

public pure function leith_biharm_is_inert(code, c_leith_bi) result(inert)

.true. iff the Leith-biharmonic closure is selected but its coefficient is <= 0 (PR-6 fail-loud). ν₄ is linear in c_leith_bi, so c_leith_bi <= 0 makes the whole closure a provable no-op — the user asked for biharmonic dissipation and got none. Returns .false. for any other closure (they do not read c_leith_bi, so the guard must not fire on them). Promotes the previous configure-time warning to an abort.

Arguments

Type IntentOptional Attributes Name
integer, intent(in) :: code
real(kind=wp), intent(in) :: c_leith_bi

Return Value logical


Called by

proc~~leith_biharm_is_inert~~CalledByGraph proc~leith_biharm_is_inert leith_biharm_is_inert proc~validate_config validate_config proc~validate_config->proc~leith_biharm_is_inert proc~build_pending_handle build_pending_handle proc~build_pending_handle->proc~validate_config proc~rdb_ocean_create_from_string rdb_ocean_create_from_string proc~rdb_ocean_create_from_string->proc~build_pending_handle proc~rdb_ocean_create_pending rdb_ocean_create_pending proc~rdb_ocean_create_pending->proc~build_pending_handle

Source Code

   pure function leith_biharm_is_inert(code, c_leith_bi) result(inert)
      !! `.true.` iff the Leith-biharmonic closure is selected but its
      !! coefficient is <= 0 (PR-6 fail-loud).  ν₄ is linear in
      !! `c_leith_bi`, so `c_leith_bi <= 0` makes the whole closure a
      !! provable no-op — the user asked for biharmonic dissipation and
      !! got none.  Returns `.false.` for any other closure (they do not
      !! read `c_leith_bi`, so the guard must not fire on them).  Promotes
      !! the previous configure-time warning to an abort.
      integer, intent(in) :: code
      real(wp), intent(in) :: c_leith_bi
      logical :: inert
      inert = (code == LMIX_LEITH_BIHARM) .and. (c_leith_bi <= 0.0_wp)
   end function leith_biharm_is_inert