Colella-Woodward 1984 eq 1.10 monotonic limiter on the parabolic profile in a single cell. Three branches:
Consumer: rdb_ice_transport (sea-ice PR 4b) — SIS2’s
PPM_limit_CW84.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| real(kind=wp), | intent(in) | :: | h_centre | |||
| real(kind=wp), | intent(inout) | :: | h_left | |||
| real(kind=wp), | intent(inout) | :: | h_right |
| Type | Visibility | Attributes | Name | Initial | |||
|---|---|---|---|---|---|---|---|
| real(kind=wp), | private | :: | dh_lr | ||||
| real(kind=wp), | private | :: | h_six |
pure subroutine ppm_cell_limiter(h_centre, h_left, h_right) !$acc routine seq !! Colella-Woodward 1984 eq 1.10 monotonic limiter on the !! parabolic profile in a single cell. Three branches: !! !! 1. Local extremum in cell (h_centre lies outside !! [min(h_left,h_right), max(h_left,h_right)]): flatten !! the parabola — h_left = h_right = h_centre. !! 2. "Overshoot" at the left edge — reset h_left so the !! parabola's minimum/maximum lies at the right edge. !! 3. "Overshoot" at the right edge — symmetric. !! !! Consumer: `rdb_ice_transport` (sea-ice PR 4b) — SIS2's !! `PPM_limit_CW84`. real(wp), intent(in) :: h_centre real(wp), intent(inout) :: h_left, h_right real(wp) :: dh_lr, h_six dh_lr = h_right - h_left h_six = 6.0_wp*(h_centre - 0.5_wp*(h_left + h_right)) if ((h_right - h_centre)*(h_centre - h_left) <= 0.0_wp) then h_left = h_centre h_right = h_centre else if (dh_lr*h_six > dh_lr*dh_lr) then h_left = 3.0_wp*h_centre - 2.0_wp*h_right else if (dh_lr*h_six < -dh_lr*dh_lr) then h_right = 3.0_wp*h_centre - 2.0_wp*h_left end if end subroutine ppm_cell_limiter