Changeset 3270 for palm/trunk/SOURCE/init_ocean.f90
- Timestamp:
- Sep 24, 2018 6:28:20 AM (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
palm/trunk/SOURCE/init_ocean.f90
r2846 r3270 25 25 ! ------------------ 26 26 ! $Id$ 27 ! bugfix for r2502: wrong calculation of hyp(nzt) in second iterative step 28 ! 29 ! 2846 2018-03-01 08:48:47Z raasch 27 30 ! FORTRAN bugfix for r2845 28 31 ! … … 132 135 !-- First step: Calculate pressure using reference density 133 136 hyp(nzt+1) = surface_pressure * 100.0_wp 134 135 hyp(nzt) = hyp(nzt+1) + rho_surface * g * 0.5_wp * dzu(nzt+1)136 rho_ocean_init(nzt ) = rho_surface137 hyp(nzt) = hyp(nzt+1) + rho_surface * g * 0.5_wp * dzu(nzt+1) 138 rho_ocean_init(nzt) = rho_surface 139 rho_ocean_init(nzt+1) = rho_surface ! only required for output 137 140 138 141 DO k = nzt-1, 1, -1 … … 161 164 rho_reference = rho_reference / ( zw(nzt) - zu(nzb) ) 162 165 163 DO k = nzt, 0, -1 166 hyp(nzt) = hyp(nzt+1) + rho_surface * g * 0.5_wp * dzu(nzt+1) 167 DO k = nzt-1, 0, -1 164 168 hyp(k) = hyp(k+1) + g * 0.5_wp * ( rho_ocean_init(k) & 165 169 + rho_ocean_init(k+1) ) * dzu(k+1)
Note: See TracChangeset
for help on using the changeset viewer.