bkgnd_henyey_conflicts_profile Function

public pure function bkgnd_henyey_conflicts_profile(bkgnd_henyey, bkgnd_profile) result(conflict)

.true. when both background schemes are selected at once.

Bryan-Lewis and Henyey are MUTUALLY EXCLUSIVE, matching the reference code, which calls its check_bkgnd_scheme guard once from each scheme’s block and FATALs when a scheme was already selected. Henyey scales the SCALAR background; composing it with the Bryan-Lewis depth profile would also scale the deep asymptote, which stands for abyssal / internal-tide mixing over rough topography — not the open-ocean internal-wave continuum Henyey describes, and not equatorially suppressed in nature.

A pure predicate rather than an inline .and. in validate_config so the RULE is unit-testable: the guard sites themselves are error stop / logger paths a unit test cannot reach without a subprocess harness, which left the rule as a mutation-survivable hole. Same shape as pseudo_salt_conflicts_restore / lateral_closure_conflicts_smag_ah.

Arguments

Type IntentOptional Attributes Name
logical, intent(in) :: bkgnd_henyey

&ocean_vmix_nml bkgnd_henyey.

logical, intent(in) :: bkgnd_profile

&ocean_vmix_nml bkgnd_profile (Bryan-Lewis).

Return Value logical


Called by

proc~~bkgnd_henyey_conflicts_profile~~CalledByGraph proc~bkgnd_henyey_conflicts_profile bkgnd_henyey_conflicts_profile proc~configure_ocean_vmix configure_ocean_vmix proc~configure_ocean_vmix->proc~bkgnd_henyey_conflicts_profile proc~validate_config validate_config proc~validate_config->proc~bkgnd_henyey_conflicts_profile proc~build_pending_handle build_pending_handle proc~build_pending_handle->proc~validate_config proc~engine_setup engine_setup proc~engine_setup->proc~configure_ocean_vmix proc~complete_ocean_create complete_ocean_create proc~complete_ocean_create->proc~engine_setup proc~driver_run_ocean driver_run_ocean proc~driver_run_ocean->proc~engine_setup proc~driver_validate driver_validate proc~driver_validate->proc~engine_setup 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_from_string->proc~complete_ocean_create proc~rdb_ocean_create_pending rdb_ocean_create_pending proc~rdb_ocean_create_pending->proc~build_pending_handle proc~driver_run driver_run proc~driver_run->proc~driver_run_ocean proc~rdb_ocean_create_finalize rdb_ocean_create_finalize proc~rdb_ocean_create_finalize->proc~complete_ocean_create

Source Code

   pure function bkgnd_henyey_conflicts_profile(bkgnd_henyey, bkgnd_profile) result(conflict)
      !! `.true.` when both background schemes are selected at once.
      !!
      !! Bryan-Lewis and Henyey are MUTUALLY EXCLUSIVE, matching the
      !! reference code, which calls its `check_bkgnd_scheme` guard once
      !! from each scheme's block and FATALs when a scheme was already
      !! selected.  Henyey scales the SCALAR background; composing it with
      !! the Bryan-Lewis depth profile would also scale the deep asymptote,
      !! which stands for abyssal / internal-tide mixing over rough
      !! topography — not the open-ocean internal-wave continuum Henyey
      !! describes, and not equatorially suppressed in nature.
      !!
      !! A `pure` predicate rather than an inline `.and.` in
      !! `validate_config` so the RULE is unit-testable: the guard sites
      !! themselves are `error stop` / logger paths a unit test cannot
      !! reach without a subprocess harness, which left the rule as a
      !! mutation-survivable hole.  Same shape as
      !! `pseudo_salt_conflicts_restore` / `lateral_closure_conflicts_smag_ah`.
      logical, intent(in) :: bkgnd_henyey
         !! `&ocean_vmix_nml bkgnd_henyey`.
      logical, intent(in) :: bkgnd_profile
         !! `&ocean_vmix_nml bkgnd_profile` (Bryan-Lewis).
      logical :: conflict

      conflict = bkgnd_henyey .and. bkgnd_profile
   end function bkgnd_henyey_conflicts_profile