Changeset 153 for palm/trunk/SOURCE
- Timestamp:
- Mar 19, 2008 9:41:30 AM (17 years ago)
- Location:
- palm/trunk/SOURCE
- Files:
-
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
palm/trunk/SOURCE/check_parameters.f90
r151 r153 4 4 ! Actual revisions: 5 5 ! ----------------- 6 ! Leaf area density (LAD) explicitly set to its surface value at k=0 6 7 ! Case of reading data for recycling included in initializing_actions, 7 8 ! check of turbulent_inflow and calculation of recycling_plane … … 955 956 956 957 IF ( .NOT. ocean ) THEN 958 959 lad(0) = lad_surface 957 960 958 961 lad_vertical_gradient_level_ind(1) = 0 -
palm/trunk/SOURCE/header.f90
r151 r153 371 371 372 372 WRITE ( io, 280 ) canopy_mode, pch_index, drag_coefficient 373 IF ( passive_scalar ) THEN 374 WRITE ( io, 281 ) scalar_exchange_coefficient, & 375 leaf_surface_concentration 376 ENDIF 377 378 ! 379 !-- Heat flux at the top of vegetation 380 WRITE ( io, 282 ) cthf 373 381 374 382 ! … … 397 405 ENDDO 398 406 399 WRITE ( io, 28 1) TRIM( coordinates ), TRIM( learde ), &407 WRITE ( io, 283 ) TRIM( coordinates ), TRIM( learde ), & 400 408 TRIM( gradients ), TRIM( slices ) 401 409 … … 1379 1387 ' Canopy top: ',I4 / & 1380 1388 ' Leaf drag coefficient: ',F6.2 /) 1381 281 FORMAT (/ ' Characteristic levels of the leaf area density:'// & 1389 281 FORMAT (/ ' Scalar_exchange_coefficient: ',F6.2 / & 1390 ' Scalar concentration at leaf surfaces in kg/m**3: ',F6.2 /) 1391 282 FORMAT (' Predefined constant heatflux at the top of the vegetation: ',F6.2,' K m/s') 1392 283 FORMAT (/ ' Characteristic levels of the leaf area density:'// & 1382 1393 ' Height: ',A,' m'/ & 1383 1394 ' Leaf area density: ',A,' m**2/m**3'/ & -
palm/trunk/SOURCE/init_3d_model.f90
r152 r153 7 7 ! Actual revisions: 8 8 ! ----------------- 9 ! Further amendments to and modifications in the initialisation of the plant 10 ! canopy model 9 11 ! Allocation of hom_sum moved to parin, initialization of spectrum_x|y directly 10 12 ! after allocating theses arrays, … … 90 92 INTEGER, DIMENSION(:,:), ALLOCATABLE :: ngp_2dh_outer_l, & 91 93 ngp_2dh_s_inner_l 94 95 REAL :: a, b 92 96 93 97 REAL, DIMENSION(1:2) :: volume_flow_area_l, volume_flow_initial_l … … 248 252 lad_w(nzb:nzt+1,nys-1:nyn+1,nxl-1:nxr+1), & 249 253 cdc(nzb:nzt+1,nys-1:nyn+1,nxl-1:nxr+1) ) 254 255 IF ( passive_scalar ) THEN 256 ALLOCATE ( sls(nzb:nzt+1,nys-1:nyn+1,nxl-1:nxr+1), & 257 sec(nzb:nzt+1,nys-1:nyn+1,nxl-1:nxr+1) ) 258 ENDIF 259 260 IF ( cthf /= 0.0 ) THEN 261 ALLOCATE ( lai(nzb:nzt+1,nys-1:nyn+1,nxl-1:nxr+1), & 262 canopy_heat_flux(nzb:nzt+1,nys-1:nyn+1,nxl-1:nxr+1) ) 263 ENDIF 264 250 265 ENDIF 251 266 … … 1078 1093 lad_s(:,j,i) = lad(:) 1079 1094 cdc(:,j,i) = drag_coefficient 1095 IF ( passive_scalar ) THEN 1096 sls(:,j,i) = leaf_surface_concentration 1097 sec(:,j,i) = scalar_exchange_coefficient 1098 ENDIF 1080 1099 ENDDO 1081 1100 ENDDO … … 1096 1115 CALL exchange_horiz( cdc ) 1097 1116 1117 IF ( passive_scalar ) THEN 1118 CALL exchange_horiz( sls ) 1119 CALL exchange_horiz( sec ) 1120 ENDIF 1121 1122 ! 1123 !-- Sharp boundaries of the plant canopy in horizontal directions 1124 !-- In vertical direction the interpolation is retained, as the leaf 1125 !-- area density is initialised by prescribing a vertical profile 1126 !-- consisting of piecewise linear segments. The upper boundary 1127 !-- of the plant canopy is now defined by lad_w(pch_index,:,:) = 0.0. 1128 1098 1129 DO i = nxl, nxr 1099 1130 DO j = nys, nyn 1100 1131 DO k = nzb, nzt+1 1101 lad_u(k,j,i) = 0.5 * ( lad_s(k,j,i-1) + lad_s(k,j,i) ) 1102 lad_v(k,j,i) = 0.5 * ( lad_s(k,j-1,i) + lad_s(k,j,i) ) 1132 IF ( lad_s(k,j,i) > 0.0 ) THEN 1133 lad_u(k,j,i) = lad_s(k,j,i) 1134 lad_u(k,j,i+1) = lad_s(k,j,i) 1135 lad_v(k,j,i) = lad_s(k,j,i) 1136 lad_v(k,j+1,i) = lad_s(k,j,i) 1137 ENDIF 1103 1138 ENDDO 1104 1139 DO k = nzb, nzt … … 1108 1143 ENDDO 1109 1144 1110 lad_w(nzt+1,:,:) = lad_w(nzt,:,:) 1145 lad_w(pch_index,:,:) = 0.0 1146 lad_w(nzt+1,:,:) = lad_w(nzt,:,:) 1111 1147 1112 1148 CALL exchange_horiz( lad_u ) 1113 1149 CALL exchange_horiz( lad_v ) 1114 1150 CALL exchange_horiz( lad_w ) 1115 1151 1152 ! 1153 !-- Initialisation of the canopy heat source distribution 1154 IF ( cthf /= 0.0 ) THEN 1155 ! 1156 !-- Piecewise evaluation of the leaf area index by 1157 !-- integration of the leaf area density 1158 lai(:,:,:) = 0.0 1159 DO i = nxl-1, nxr+1 1160 DO j = nys-1, nyn+1 1161 DO k = pch_index-1, 0, -1 1162 lai(k,j,i) = lai(k+1,j,i) + & 1163 ( 0.5 * ( lad_w(k+1,j,i) + & 1164 lad_s(k+1,j,i) ) * & 1165 ( zw(k+1) - zu(k+1) ) ) + & 1166 ( 0.5 * ( lad_w(k,j,i) + & 1167 lad_s(k+1,j,i) ) * & 1168 ( zu(k+1) - zw(k) ) ) 1169 ENDDO 1170 ENDDO 1171 ENDDO 1172 1173 ! 1174 !-- Evaluation of the upward kinematic vertical heat flux within the 1175 !-- canopy 1176 DO i = nxl-1, nxr+1 1177 DO j = nys-1, nyn+1 1178 DO k = 0, pch_index 1179 canopy_heat_flux(k,j,i) = cthf * & 1180 exp( -0.6 * lai(k,j,i) ) 1181 ENDDO 1182 ENDDO 1183 ENDDO 1184 1185 ! 1186 !-- The near surface heat flux is derived from the heat flux 1187 !-- distribution within the canopy 1188 shf(:,:) = canopy_heat_flux(0,:,:) 1189 1190 IF ( ASSOCIATED( shf_m ) ) shf_m = shf 1191 1192 ENDIF 1193 1116 1194 ENDIF 1117 1195 -
palm/trunk/SOURCE/modules.f90
r151 r153 5 5 ! Actual revisions: 6 6 ! ----------------- 7 ! +canopy_heat_flux, cthf, lai, 8 ! +leaf_surface_concentration, scalar_exchange_coefficient, sec, sls 7 9 ! +hor_index_bounds, hor_index_bounds_previous_run, id_inflow, 8 10 ! inflow_damping_*, mean_inflow_profiles, numprocs_previous_run, nx_on_file, … … 135 137 136 138 REAL, DIMENSION(:,:,:), ALLOCATABLE :: & 137 c dc, d, diss, lad_s, lad_u, lad_v, lad_w, l_wall, tend,&138 u_m_l, u_m_n, u_m_r, u_m_s, v_m_l, v_m_n, v_m_r, v_m_s, w_m_l,&139 w_m_n, w_m_r, w_m_s139 canopy_heat_flux, cdc, d, diss, lad_s, lad_u, lad_v, lad_w, lai, & 140 l_wall, sec, sls, tend, u_m_l, u_m_n, u_m_r, u_m_s, v_m_l, v_m_n, & 141 v_m_r, v_m_s, w_m_l, w_m_n, w_m_r, w_m_s 140 142 141 143 REAL, DIMENSION(:,:,:), ALLOCATABLE, TARGET :: & … … 375 377 building_height = 50.0, building_length_x = 50.0, & 376 378 building_length_y = 50.0, building_wall_left = 9999999.9, & 377 building_wall_south = 9999999.9, c fl_factor = -1.0, &379 building_wall_south = 9999999.9, cthf = 0.0, cfl_factor = -1.0, & 378 380 cos_alpha_surface, disturbance_amplitude = 0.25, & 379 381 disturbance_energy_limit = 0.01, & … … 396 398 f = 0.0, fs = 0.0, g = 9.81, inflow_damping_height = 9999999.9, & 397 399 inflow_damping_width = 9999999.9, kappa = 0.4, km_constant = -1.0,& 398 km_damp_max = -1.0, lad_surface = 0.0, long_filter_factor = 0.0, & 400 km_damp_max = -1.0, lad_surface = 0.0, & 401 leaf_surface_concentration = 0.0, long_filter_factor = 0.0, & 399 402 maximum_cpu_time_allowed = 0.0, molecular_viscosity = 1.461E-5, & 400 403 old_dt = 1.0E-10, omega = 7.29212E-5, omega_sor = 1.8, & … … 412 415 rif_max = 1.0, & 413 416 rif_min = -5.0, roughness_length = 0.1, sa_surface = 35.0, & 417 scalar_exchange_coefficient = 0.0, & 414 418 simulated_time = 0.0, simulated_time_at_begin, sin_alpha_surface, & 415 419 skip_time_data_output = 0.0, skip_time_data_output_av = 9999999.9,& -
palm/trunk/SOURCE/parin.f90
r151 r153 4 4 ! Actual revisions: 5 5 ! ----------------- 6 ! +cthf 7 ! +leaf_surface_concentration, scalar_exchange_coefficient 6 8 ! +inflow_damping_height, inflow_damping_width, recycling_width, 7 9 ! turbulent_inflow in inipar … … 82 84 building_length_y, building_wall_left, & 83 85 building_wall_south, canopy_mode, cloud_droplets, cloud_physics, & 84 conserve_volume_flow, c ut_spline_overshoot, damp_level_1d, &86 conserve_volume_flow, cthf, cut_spline_overshoot, damp_level_1d, & 85 87 dissipation_1d, drag_coefficient, dt, dt_pr_1d, & 86 88 dt_run_control_1d, dx, dy, dz, dz_max, dz_stretch_factor, & … … 91 93 initializing_actions, km_constant, km_damp_max, lad_surface, & 92 94 lad_vertical_gradient, lad_vertical_gradient_level, & 93 long_filter_factor, loop_optimization, mixing_length_1d, & 94 momentum_advec, netcdf_precision, nsor_ini, nx, ny, & 95 leaf_surface_concentration, long_filter_factor, & 96 loop_optimization, mixing_length_1d, momentum_advec, & 97 netcdf_precision, nsor_ini, nx, ny, & 95 98 nz, ocean, omega, outflow_damping_width, overshoot_limit_e, & 96 99 overshoot_limit_pt, overshoot_limit_u, overshoot_limit_v, & … … 102 105 random_generator, random_heatflux, recycling_width, rif_max, & 103 106 rif_min, roughness_length, sa_surface, sa_vertical_gradient, & 104 sa_vertical_gradient_level, scalar_advec, statistic_regions, & 107 sa_vertical_gradient_level, scalar_advec, & 108 scalar_exchange_coefficient, statistic_regions, & 105 109 surface_heatflux, surface_pressure, surface_scalarflux, & 106 110 surface_waterflux, s_surface, s_surface_initial_change, & -
palm/trunk/SOURCE/plant_canopy_model.f90
r142 r153 4 4 ! Actual revisions: 5 5 ! ----------------- 6 ! Consideration of heat sources within the forest canopy which represent the 7 ! rate of heat input into the air from the forest leaves 8 ! 9 ! Evaluation of sinks and sources for scalar concentration due to canopy 10 ! elements 11 ! 6 12 ! Bugfix: remove IF statement in plant_canopy_model_ij 7 13 ! … … 15 21 ! Description: 16 22 ! ------------ 17 ! Evaluation of the drag due to vegetation 23 ! Evaluation of sinks and sources of momentum, heat and scalar concentration 24 ! due to canopy elements 18 25 !------------------------------------------------------------------------------! 19 26 … … 59 66 v(k,j,i) + & 60 67 v(k,j+1,i) + & 61 v(k,j+1,i +1) ) &68 v(k,j+1,i-1) ) & 62 69 / 4.0 )**2 + & 63 70 ( ( w(k-1,j,i-1) + & … … 120 127 121 128 ! 129 !-- potential temperature 130 CASE ( 4 ) 131 DO i = nxl, nxr 132 DO j = nys, nyn 133 DO k = nzb_s_inner(j,i)+1, pch_index 134 tend(k,j,i) = tend(k,j,i) + & 135 ( canopy_heat_flux(k,j,i) - & 136 canopy_heat_flux(k-1,j,i) ) / & 137 dzw(k) 138 ENDDO 139 ENDDO 140 ENDDO 141 142 ! 143 !-- scalar concentration 144 CASE ( 5 ) 145 DO i = nxl, nxr 146 DO j = nys, nyn 147 DO k = nzb_s_inner(j,i)+1, pch_index 148 tend(k,j,i) = tend(k,j,i) - & 149 sec(k,j,i) * lad_s(k,j,i) * & 150 SQRT( ( ( u(k,j,i) + & 151 u(k,j,i+1) ) & 152 / 2.0 )**2 + & 153 ( ( v(k,j,i) + & 154 v(k,j+1,i) ) & 155 / 2.0 )**2 + & 156 ( ( w(k-1,j,i) + & 157 w(k,j,i) ) & 158 / 2.0 )**2 ) * & 159 ( q(k,j,i) - sls(k,j,i) ) 160 ENDDO 161 ENDDO 162 ENDDO 163 164 ! 122 165 !-- sgs-tke 123 CASE ( 4)166 CASE ( 6 ) 124 167 DO i = nxl, nxr 125 168 DO j = nys, nyn … … 180 223 v(k,j,i) + & 181 224 v(k,j+1,i) + & 182 v(k,j+1,i +1) ) &225 v(k,j+1,i-1) ) & 183 226 / 4.0 )**2 + & 184 227 ( ( w(k-1,j,i-1) + & … … 232 275 233 276 ! 277 !-- potential temperature 278 CASE ( 4 ) 279 DO k = nzb_s_inner(j,i)+1, pch_index 280 tend(k,j,i) = tend(k,j,i) + & 281 ( canopy_heat_flux(k,j,i) - & 282 canopy_heat_flux(k-1,j,i) ) / & 283 dzw(k) 284 ENDDO 285 286 287 ! 288 !-- scalar concentration 289 CASE ( 5 ) 290 DO k = nzb_s_inner(j,i)+1, pch_index 291 tend(k,j,i) = tend(k,j,i) - & 292 sec(k,j,i) * lad_s(k,j,i) * & 293 SQRT( ( ( u(k,j,i) + & 294 u(k,j,i+1) ) & 295 / 2.0 )**2 + & 296 ( ( v(k,j,i) + & 297 v(k,j+1,i) ) & 298 / 2.0 )**2 + & 299 ( ( w(k-1,j,i) + & 300 w(k,j,i) ) & 301 / 2.0 )**2 ) * & 302 ( q(k,j,i) - sls(k,j,i) ) 303 ENDDO 304 305 ! 234 306 !-- sgs-tke 235 CASE ( 4)307 CASE ( 6 ) 236 308 DO k = nzb_s_inner(j,i)+1, pch_index 237 309 tend(k,j,i) = tend(k,j,i) - & -
palm/trunk/SOURCE/prognostic_equations.f90
r139 r153 4 4 ! Actual revisions: 5 5 ! ----------------- 6 ! 6 ! add call of plant_canopy_model in the prognostic equation for 7 ! the potential temperature 8 ! add call of plant_canopy_model in the prognostic equation for 9 ! the concentration of a passive scalar 7 10 ! 8 11 ! Former revisions: … … 422 425 CALL impact_of_latent_heat( i, j ) 423 426 ENDIF 427 428 ! 429 !-- Consideration of heat sources within the plant canopy 430 IF ( plant_canopy .AND. ( cthf /= 0.0 ) ) THEN 431 CALL plant_canopy_model( i, j, 4 ) 432 ENDIF 433 424 434 CALL user_actions( i, j, 'pt-tendency' ) 425 435 … … 612 622 CALL calc_precipitation( i, j ) 613 623 ENDIF 624 625 ! 626 !-- Sink or source of scalar concentration due to canopy elements 627 IF ( plant_canopy ) CALL plant_canopy_model( i, j, 5 ) 628 614 629 CALL user_actions( i, j, 'q-tendency' ) 615 630 … … 754 769 ! 755 770 !-- Additional sink term for flows through plant canopies 756 IF ( plant_canopy ) CALL plant_canopy_model( i, j, 4)771 IF ( plant_canopy ) CALL plant_canopy_model( i, j, 6 ) 757 772 758 773 CALL user_actions( i, j, 'e-tendency' ) … … 1034 1049 CALL impact_of_latent_heat( i, j ) 1035 1050 ENDIF 1051 1052 ! 1053 !-- Consideration of heat sources within the plant canopy 1054 IF ( plant_canopy .AND. ( cthf /= 0.0 ) ) THEN 1055 CALL plant_canopy_model( i, j, 4 ) 1056 ENDIF 1057 1036 1058 CALL user_actions( i, j, 'pt-tendency' ) 1037 1059 … … 1142 1164 CALL calc_precipitation( i, j ) 1143 1165 ENDIF 1166 1167 ! 1168 !-- Sink or source of scalar concentration due to canopy elements 1169 IF ( plant_canopy ) CALL plant_canopy_model( i, j, 5 ) 1170 1171 1144 1172 CALL user_actions( i, j, 'q-tendency' ) 1145 1173 … … 1219 1247 ! 1220 1248 !-- Additional sink term for flows through plant canopies 1221 IF ( plant_canopy ) CALL plant_canopy_model( i, j, 4)1249 IF ( plant_canopy ) CALL plant_canopy_model( i, j, 6 ) 1222 1250 1223 1251 CALL user_actions( i, j, 'e-tendency' ) … … 1582 1610 CALL impact_of_latent_heat 1583 1611 ENDIF 1612 1613 ! 1614 !-- Consideration of heat sources within the plant canopy 1615 IF ( plant_canopy .AND. ( cthf /= 0.0 ) ) THEN 1616 CALL plant_canopy_model( 4 ) 1617 ENDIF 1618 1619 1584 1620 CALL user_actions( 'pt-tendency' ) 1585 1621 … … 1782 1818 CALL calc_precipitation 1783 1819 ENDIF 1820 1821 ! 1822 !-- Sink or source of scalar concentration due to canopy elements 1823 IF ( plant_canopy ) CALL plant_canopy_model( 5 ) 1824 1784 1825 CALL user_actions( 'q-tendency' ) 1785 1826 … … 1919 1960 ! 1920 1961 !-- Additional sink term for flows through plant canopies 1921 IF ( plant_canopy ) CALL plant_canopy_model( 4)1962 IF ( plant_canopy ) CALL plant_canopy_model( 6 ) 1922 1963 CALL user_actions( 'e-tendency' ) 1923 1964 -
palm/trunk/SOURCE/read_var_list.f90
r151 r153 4 4 ! Actual revisions: 5 5 ! ----------------- 6 ! +cthf, leaf_surface_concentration, scalar_exchange_coefficient 6 7 ! +numprocs_previous_run, hor_index_bounds_previous_run, inflow_damping_factor, 7 8 ! inflow_damping_height, inflow_damping_width, mean_inflow_profiles, … … 233 234 CASE ( 'conserve_volume_flow' ) 234 235 READ ( 13 ) conserve_volume_flow 236 CASE ( 'cthf' ) 237 READ ( 13 ) cthf 235 238 CASE ( 'current_timestep_number' ) 236 239 READ ( 13 ) current_timestep_number … … 312 315 CASE ( 'last_dt_change' ) 313 316 READ ( 13 ) last_dt_change 317 CASE ( 'leaf_surface_concentration' ) 318 READ ( 13 ) leaf_surface_concentration 314 319 CASE ( 'long_filter_factor' ) 315 320 READ ( 13 ) long_filter_factor … … 417 422 CASE ( 'scalar_advec' ) 418 423 READ ( 13 ) scalar_advec 424 CASE ( 'scalar_exchange_coefficient' ) 425 READ ( 13 ) scalar_exchange_coefficient 419 426 CASE ( 'simulated_time' ) 420 427 READ ( 13 ) simulated_time -
palm/trunk/SOURCE/write_var_list.f90
r151 r153 4 4 ! Actual revisions: 5 5 ! ----------------- 6 ! +cthf, leaf_surface_concentration, scalar_exchange_coefficient 6 7 ! +numprocs, hor_index_bounds, inflow_damping_height, inflow_damping_width, 7 8 ! mean_inflow_profiles, recycling_width, turbulent_inflow, … … 155 156 WRITE ( 14 ) 'current_timestep_number ' 156 157 WRITE ( 14 ) current_timestep_number 158 WRITE ( 14 ) 'cthf ' 159 WRITE ( 14 ) cthf 157 160 WRITE ( 14 ) 'cut_spline_overshoot ' 158 161 WRITE ( 14 ) cut_spline_overshoot … … 231 234 WRITE ( 14 ) 'last_dt_change ' 232 235 WRITE ( 14 ) last_dt_change 236 WRITE ( 14 ) 'leaf_surface_concentration ' 237 WRITE ( 14 ) leaf_surface_concentration 233 238 WRITE ( 14 ) 'long_filter_factor ' 234 239 WRITE ( 14 ) long_filter_factor … … 333 338 WRITE ( 14 ) 'scalar_advec ' 334 339 WRITE ( 14 ) scalar_advec 340 WRITE ( 14 ) 'scalar_exchange_coefficient ' 341 WRITE ( 14 ) scalar_exchange_coefficient 335 342 WRITE ( 14 ) 'simulated_time ' 336 343 WRITE ( 14 ) simulated_time
Note: See TracChangeset
for help on using the changeset viewer.