| Type | Visibility | Attributes | Name | Initial | |||
|---|---|---|---|---|---|---|---|
| type(scratch_3d_buffer_t), | public | :: | F_x_face |
East-face tracer flux |
|||
| type(scratch_3d_buffer_t), | public | :: | F_y_face |
North-face counterpart. Shape (nx, ny+1, nz_ml). |
|||
| type(scratch_3d_buffer_t), | public | :: | T_centre |
|
|||
| logical, | public | :: | is_init | = | .false. |
True between |
|
| real(kind=wp), | public | :: | kappa_h | = | 0.0_wp |
Constant horizontal tracer diffusivity (m^2/s). Zero is a no-op — the kernel short-circuits without touching hTr. Stability bound (explicit forward-Euler): kappa_h * dt * (1/dx^2 + 1/dy^2) <= 0.5 |
Counted allocatable footprint of the horizontal tracer diffusion slot (0 when unallocated).
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(ocean_hdiff_tracer_t), | intent(in) | :: | this |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(ocean_hdiff_tracer_t), | intent(inout) | :: | this |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(ocean_hdiff_tracer_t), | intent(inout) | :: | this |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(ocean_hdiff_tracer_t), | intent(inout) | :: | this |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(ocean_hdiff_tracer_t), | intent(inout) | :: | this | |||
| type(hgrid_t), | intent(in) | :: | grid | |||
| integer, | intent(in), | optional | :: | nz_ml |
type :: ocean_hdiff_tracer_t logical :: is_init = .false. !! True between `init` and `destroy`. real(wp) :: kappa_h = 0.0_wp !! Constant horizontal tracer diffusivity (m^2/s). Zero !! is a no-op — the kernel short-circuits without !! touching hTr. Stability bound (explicit forward-Euler): !! kappa_h * dt * (1/dx^2 + 1/dy^2) <= 0.5 type(scratch_3d_buffer_t) :: T_centre !! `T = hTr/h` at cell centres. Shape (nx, ny, nz_ml). !! Filled per tracer at the start of each impl call; !! reused across the F_x / F_y face passes so the !! divergence step reads a consistent snapshot. type(scratch_3d_buffer_t) :: F_x_face !! East-face tracer flux `kappa * h_face * dT/dx`. !! Shape (nx+1, ny, nz_ml). type(scratch_3d_buffer_t) :: F_y_face !! North-face counterpart. Shape (nx, ny+1, nz_ml). contains procedure, non_overridable :: init => ocean_hdiff_tracer_init procedure, non_overridable :: destroy => ocean_hdiff_tracer_destroy procedure, non_overridable :: enter_data => ocean_hdiff_tracer_enter_data procedure, non_overridable :: exit_data => ocean_hdiff_tracer_exit_data procedure, non_overridable :: bytes => ocean_hdiff_tracer_bytes end type ocean_hdiff_tracer_t