- Timestamp:
- Nov 28, 2007 10:03:58 AM (17 years ago)
- Location:
- palm/trunk
- Files:
-
- 1 added
- 14 edited
Legend:
- Unmodified
- Added
- Removed
-
palm/trunk/DOC/app/chapter_3.5.1.html
r130 r138 81 81 within the category “initialisation”.</p><p>See 82 82 also <tt><font style="font-size: 10pt;" size="2"><font face="Cumberland, monospace"><a href="#user_init_3d_model">user_init_3d_model</a>.</font></font></tt></p> 83 </td> </tr> <tr> <td style="vertical-align: top;"><tt><font style="font-size: 10pt;" size="2">DEFAULT</font></tt> 83 </td> </tr> <tr><td><tt><font style="font-size: 10pt;" size="2">DEFAULT</font></tt> 84 case of <tt><font style="font-size: 10pt;" size="2">SELECT 85 CASE( TRIM(canopy_mode) ) </font></tt>command in the 86 middle of <tt><font style="font-size: 10pt;" size="2">init_3d_model.f90</font></tt></td><td><a name="user_init_plant_canopy"></a><code>user_init_plant_canopy</code></td><td>User-defined initilisation of the plant canopy model.<br><br>Here, the user can define the two three-dimensional arrays <code>lad_s and cdc </code>that 87 stand for the leaf area density and the canopy drag coefficient. By 88 this, the user can configure a plant canopy. This requires 89 definition of at least one 90 new <a href="chapter_4.1.html#canopy_mode">canopy_mode</a> in the <tt><font style="font-size: 10pt;" size="2">SELECT CASE( TRIM(canopy_mode) ) </font></tt>command 91 in <tt><font style="font-size: 10pt;" size="2">user_init_plant_canopy</font></tt>. 92 Note that the <a href="chapter_4.1.html#canopy_mode">canopy_mode</a> <span style="font-style: italic;">'block'</span> is<span style="font-style: italic;"></span> not allowed here since it is the standard case used in the 93 calling routine <tt><font style="font-size: 10pt;" size="2">init_3d_model</font></tt>. </td></tr><tr> <td style="vertical-align: top;"><tt><font style="font-size: 10pt;" size="2">DEFAULT</font></tt> 84 94 case of <tt><font style="font-size: 10pt;" size="2">SELECT 85 95 CASE( TRIM(topography) ) </font></tt>command in the -
palm/trunk/DOC/app/chapter_4.1.html
r134 r138 2100 2100 2101 2101 2102 <tr> 2102 <tr><td><a name="canopy_mode"></a><span style="font-weight: bold;">canopy_mode</span></td><td>C * 20</td><td><span style="font-style: italic;">'block'</span></td><td>Canopy mode.<br><br><font color="#000000"> 2103 Besides using the default value, that will create a horizontally 2104 homogeneous plant canopy that extends over the total horizontal 2105 extension of the model domain, the user may add code to the user 2106 interface subroutine <a href="chapter_3.5.1.html#user_init_plant_canopy">user_init_plant_canopy</a> 2107 to allow further canopy modes. <br><br>The setting of <a href="#canopy_mode">canopy_mode</a> becomes only active, if <a href="#plant_canopy">plant_canopy</a> has been set <span style="font-style: italic;">.T.</span> and a non-zero <a href="#drag_coefficient">drag_coefficient</a> has been defined.</font></td></tr><tr> 2103 2108 2104 2109 … … 2621 2626 2622 2627 2623 <tr> 2628 <tr><td><a name="drag_coefficient"></a><span style="font-weight: bold;">drag_coefficient</span></td><td>R</td><td><span style="font-style: italic;">0.0</span></td><td>Drag coefficient used in the plant canopy model.<br><br>This parameter has to be non-zero, if the parameter <a href="#plant_canopy">plant_canopy</a> is set <span style="font-style: italic;">.T.</span>.</td></tr><tr> 2624 2629 2625 2630 … … 4695 4700 4696 4701 4697 <tr> 4702 <tr><td><a name="lad_surface"></a><span style="font-weight: bold;">lad_surface</span></td><td>R</td><td><span style="font-style: italic;">0.0</span></td><td>Surface value of the leaf area density (in m<sup>2</sup>/m<sup>3</sup>).<br><br>This 4703 parameter assigns the value of the leaf area density <span style="font-weight: bold;">lad</span> at the surface (k=0)<b>.</b> Starting from this value, 4704 the leaf area density profile is constructed with <a href="chapter_4.1.html#lad_vertical_gradient">lad_vertical_gradient</a> 4705 and <a href="chapter_4.1.html#lad_vertical_gradient_level">lad_vertical_gradient_level 4706 </a>.</td></tr><tr><td><a name="lad_vertical_gradient"></a><span style="font-weight: bold;">lad_vertical_gradient</span></td><td>R (10)</td><td><span style="font-style: italic;">10 * 0.0</span></td><td>Gradient(s) of the leaf area density (in m<sup>2</sup>/m<sup>4</sup>).<br><br><p>This leaf area density gradient 4707 holds starting from the height 4708 level defined by <a href="chapter_4.1.html#lad_vertical_gradient_level">lad_vertical_gradient_level</a> 4709 (precisely: for all uv levels k where zu(k) > lad_vertical_gradient_level, lad(k) is set: lad(k) = lad(k-1) + dzu(k) * <b>lad_vertical_gradient</b>) 4710 up to the level defined by <a href="#pch_index">pch_index</a>. Above that level lad(k) will automatically set to 0.0. A total of 10 different gradients for 11 height intervals (10 intervals 4711 if <a href="chapter_4.1.html#lad_vertical_gradient_level">lad_vertical_gradient_level</a>(1) 4712 = <i>0.0</i>) can be assigned. The leaf area density at the surface is 4713 assigned via <a href="chapter_4.1.html#lad_surface">lad_surface</a>. 4714 </p></td></tr><tr><td><a name="lad_vertical_gradient_level"></a><span style="font-weight: bold;">lad_vertical_gradient_level</span></td><td>R (10)</td><td><span style="font-style: italic;">10 * 0.0</span></td><td>Height level from which on the gradient 4715 of the leaf area density defined by <a href="chapter_4.1.html#lad_vertical_gradient">lad_vertical_gradient_level</a> 4716 is effective (in m).<br><br>The height levels have to be assigned in ascending order. The 4717 default values result in a leaf area density that is constant with height uup to the top of the plant canopy layer defined by <a href="#pch_index">pch_index</a>. For the piecewise construction of temperature profiles see <a href="chapter_4.1.html#lad_vertical_gradient">lad_vertical_gradient</a>.</td></tr><tr> 4698 4718 4699 4719 … … 7095 7115 7096 7116 7097 <tr> 7117 <tr><td><a name="pch_index"></a><span style="font-weight: bold;">pch_index</span></td><td>I</td><td><span style="font-style: italic;">0</span></td><td>Grid point index (scalar) of the upper boundary of the plant canopy layer.<br><br>Above <span style="font-weight: bold;">pch_index</span> the arrays of leaf area density and drag_coeffient are automatically set to zero in case of <a href="#plant_canopy">plant_canopy</a> = .T.. Up to <span style="font-weight: bold;">pch_index</span> a leaf area density profile can be prescribed by using the parameters <a href="#lad_surface">lad_surface</a>, <a href="#lad_vertical_gradient">lad_vertical_gradient</a> and <a href="#lad_vertical_gradient_level">lad_vertical_gradient_level</a>.</td></tr><tr> 7098 7118 7099 7119 … … 7162 7182 7163 7183 7164 <tr> 7184 <tr><td><a name="plant_canopy"></a><span style="font-weight: bold;">plant_canopy</span></td><td>L</td><td><span style="font-style: italic;">.F.</span></td><td>Switch for the plant_canopy_model.<br><br>If <span style="font-weight: bold;">plant_canopy</span> is set <span style="font-style: italic;">.T.</span>, the plant canopy model of Watanabe (2004, BLM 112, 307-341) is used. <br>The 7185 impact of a plant canopy on a turbulent flow is considered by an 7186 additional drag term in the momentum equations and an additional sink 7187 term in the prognostic equation for the subgrid-scale TKE. These 7188 additional terms are dependent on the leaf drag coefficient (see <a href="#drag_coefficient">drag_coefficient</a>) and the leaf area density (see <a href="#lad_surface">lad_surface</a>, <a href="#lad_vertical_gradient">lad_vertical_gradient</a>, <a href="#lad_vertical_gradient_level">lad_vertical_gradient_level</a>). <br>By default, a horizontally homogeneous plant canopy is prescribed, if <span style="font-weight: bold;">plant_canopy</span> is set <span style="font-style: italic;">.T.</span>. However, the user can define other types of plant canopies (see <a href="#canopy_mode">canopy_mode</a>).<br><br><span style="font-weight: bold;">plant_canopy</span> = <span style="font-style: italic;">.T. </span>is only allowed together with a non-zero <a href="#drag_coefficient">drag_coefficient</a>.</td></tr><tr> 7165 7189 7166 7190 -
palm/trunk/DOC/app/chapter_4.6.html
r127 r138 1405 1405 1406 1406 1407 <tr> 1407 <tr><td><b><b><a href="chapter_4.2.html#fcl_factor"><b>canopy_mode</b></a></b></b></td><td>I</td><td>C * 20</td><td><span style="font-style: italic;">'block'</span></td><td>Canopy mode</td></tr><tr> 1408 1408 1409 1409 … … 2664 2664 2665 2665 2666 <tr> 2666 <tr><td><a href="chapter_4.1.html#drag_coefficient"><span style="font-weight: bold;">drag_coefficient</span></a></td><td>I</td><td>R</td><td><span style="font-style: italic;">0.0</span></td><td>Drag coefficient used in the plant canopy model.</td></tr><tr> 2667 2667 2668 2668 … … 5184 5184 5185 5185 5186 <tr> 5186 <tr><td><b><a href="chapter_4.1.html#lad_surface"><b>lad_surface</b></a></b></td><td>I</td><td>R</td><td><span style="font-style: italic;">0.0</span></td><td>Surface value of the leaf area density (in m<sup>2</sup>/m<sup>3</sup>)</td></tr><tr><td><b><a href="chapter_4.1.html#lad_vertical_gradient"><b>lad_vertical_gradient</b></a></b></td><td>I</td><td>R (10)</td><td><span style="font-style: italic;">10 * 0.0</span></td><td>Gradient(s) of the leaf area density (in m<sup>2</sup>/m<sup>4</sup>)</td></tr><tr><td><b><b><a href="chapter_4.1.html#lad_vertical_gradient_level"><b>lad_vertical_gradient_level</b></a></b></b></td><td>I</td><td>R (10)</td><td><span style="font-style: italic;">10 * 0.0</span></td><td>Height level from which on the gradient 5187 of the leaf area density defined by <a href="chapter_4.1.html#lad_vertical_gradient">lad_vertical_gradient_level</a> 5188 is effective (in m).</td></tr><tr> 5187 5189 5188 5190 … … 6993 6995 6994 6996 6995 <tr valign="top">6997 <tr><td><b><a href="chapter_4.1.html#pch_index"><b>pch_index</b></a></b></td><td>I</td><td>I</td><td><code></code><i>0 </i></td><td>Grid point index (scalar) of the upper boundary of the plant canopy layer</td></tr><tr valign="top"> 6996 6998 6997 6999 … … 7229 7231 7230 7232 7231 <tr> 7233 <tr><td><b><a href="chapter_4.1.html#plant_canopy"><b>plant_canopy</b></a></b></td><td>I</td><td>L</td><td><i>.F.</i></td><td>Parameter to switch on the plant canopy model</td></tr><tr> 7232 7234 7233 7235 -
palm/trunk/SOURCE/CURRENT_MODIFICATIONS
r137 r138 1 1 New: 2 2 --- 3 4 Plant canopy model of Watanabe (2004,BLM 112,307-341) added. 5 It can be switched on by the inipar parameter plant_canopy. 6 The inipar parameter canopy_mode can be used to prescribe a 7 plant canopy type. The default case is a homogeneous plant 8 canopy. Heterogeneous distributions of the leaf area 9 density and the canopy drag coefficient can be defined in the 10 new routine user_init_plant_canopy (user_interface). 11 The inipar parameters lad_surface, lad_vertical_gradient and 12 lad_vertical_gradient_level can be used in order to 13 prescribe the vertical profile of leaf area density. The 14 inipar parameter drag_coefficient determines the canopy 15 drag coefficient. 16 Finally, the inipar parameter pch_index determines the 17 index of the upper boundary of the plant canopy. 3 18 4 19 Allow new case bc_uv_t = 'dirichlet_0' for channel flow. … … 15 30 advec_particles after the end of this loop. 16 31 17 advec_particles, check_parameters, data_output_dvrp, header, init_3d_model, init_grid, init_particles, init_pegrid, modules, package_parin, read_var_list, user_interface, write_var_list32 advec_particles, check_parameters, data_output_dvrp, header, init_3d_model, init_grid, init_particles, init_pegrid, modules, package_parin, parin, plant_canopy_model, read_var_list, read_3d_binary, user_interface, write_var_list, write_3d_binary 18 33 19 34 -
palm/trunk/SOURCE/Makefile
r102 r138 4 4 # Actual revisions: 5 5 # ----------------- 6 # +plant_canopy_model 7 # 6 8 # +surface_coupler 7 9 # … … 59 61 local_flush.f90 local_getenv.f90 local_stop.f90 local_system.f90 local_tremain.f90 \ 60 62 local_tremain_ini.f90 modules.f90 netcdf.f90 package_parin.f90 \ 61 palm.f90 parin.f90 particle_boundary_conds.f90 poisfft.f90 \ 63 palm.f90 parin.f90 particle_boundary_conds.f90 \ 64 plant_canopy_model.f90 poisfft.f90 \ 62 65 poisfft_hybrid.f90 poismg.f90 prandtl_fluxes.f90 pres.f90 print_1d.f90 \ 63 66 production_e.f90 prognostic_equations.f90 random_function.f90 \ … … 89 92 interaction_droplets_ptq.o local_flush.o local_getenv.o local_stop.o \ 90 93 local_system.o local_tremain.o local_tremain_ini.o modules.o netcdf.o \ 91 package_parin.o palm.o parin.o particle_boundary_conds.o poisfft.o \ 94 package_parin.o palm.o parin.o particle_boundary_conds.o \ 95 plant_canopy_model.o poisfft.o \ 92 96 poisfft_hybrid.o poismg.o prandtl_fluxes.o pres.o print_1d.o \ 93 97 production_e.o prognostic_equations.o random_function.o random_gauss.o \ … … 201 205 parin.o: modules.o 202 206 particle_boundary_conds.o: modules.o 207 plant_canopy_model.o: modules.o 203 208 poisfft.o: modules.o fft_xy.o 204 209 poisfft_hybrid.o: modules.o fft_xy.o … … 212 217 buoyancy.o calc_precipitation.o calc_radiation.o coriolis.o \ 213 218 diffusion_e.o diffusion_s.o diffusion_u.o diffusion_v.o diffusion_w.o \ 214 eqn_state_seawater.o impact_of_latent_heat.o production_e.o \ 219 eqn_state_seawater.o impact_of_latent_heat.o \ 220 plant_canopy_model.o production_e.o \ 215 221 user_interface.o 216 222 random_gauss.o: random_function.o -
palm/trunk/SOURCE/check_parameters.f90
r132 r138 4 4 ! Actual revisions: 5 5 ! ----------------- 6 ! Plant canopy added 6 7 ! Allow new case bc_uv_t = 'dirichlet_0' for channel flow. 7 8 ! Multigrid solver allows topography, checking of dt_sort_particles … … 592 593 ENDIF 593 594 595 IF ( plant_canopy .AND. ( drag_coefficient == 0.0 ) ) THEN 596 IF ( myid == 0 ) PRINT*, '+++ check_parameters: plant_canopy = TRUE', & 597 'requires a non-zero drag_coefficient' 598 CALL local_stop 599 ENDIF 600 594 601 ! 595 602 !-- In case of no model continuation run, check initialising parameters and … … 605 612 IF ( ocean ) sa_init = sa_surface 606 613 IF ( passive_scalar ) q_init = s_surface 614 IF ( plant_canopy ) lad = 0.0 607 615 608 616 ! … … 934 942 ENDIF 935 943 936 ENDIF 937 944 ! 945 !-- If required compute the profile of leaf area density used in the plant canopy model 946 IF ( plant_canopy ) THEN 947 948 i = 1 949 gradient = 0.0 950 951 IF ( .NOT. ocean ) THEN 952 953 lad_vertical_gradient_level_ind(1) = 0 954 DO k = 1, pch_index 955 IF ( lad_vertical_gradient_level(i) < zu(k) .AND. & 956 lad_vertical_gradient_level(i) >= 0.0 ) THEN 957 gradient = lad_vertical_gradient(i) 958 lad_vertical_gradient_level_ind(i) = k - 1 959 i = i + 1 960 IF ( i > 10 ) THEN 961 IF ( myid == 0 ) THEN 962 PRINT*, '+++ user_init_3d_model: upper bound 10 of array', & 963 ' "lad_vertical_gradient_level" exceeded' 964 ENDIF 965 CALL local_stop 966 ENDIF 967 ENDIF 968 IF ( gradient /= 0.0 ) THEN 969 IF ( k /= 1 ) THEN 970 lad(k) = lad(k-1) + dzu(k) * gradient 971 ELSE 972 lad(k) = lad_surface + 0.5 * dzu(k) *gradient 973 ENDIF 974 ELSE 975 lad(k) = lad(k-1) 976 ENDIF 977 ENDDO 978 979 ENDIF 980 981 ! 982 !-- In case of no given leaf area density gradients, choose a vanishing gradient 983 IF ( lad_vertical_gradient_level(1) == -9999999.9 ) THEN 984 lad_vertical_gradient_level(1) = 0.0 985 ENDIF 986 987 ENDIF 988 989 ENDIF 990 938 991 ! 939 992 !-- Compute Coriolis parameter -
palm/trunk/SOURCE/header.f90
r132 r138 78 78 CHARACTER (LEN=70) :: char1, char2, coordinates, gradients, dopr_chr, & 79 79 do2d_xy, do2d_xz, do2d_yz, do3d_chr, & 80 run_classification, slices, temperatures, &80 run_classification, slices, temperatures, learde, & 81 81 ugcomponent, vgcomponent 82 82 CHARACTER (LEN=85) :: roben, runten … … 364 364 365 365 END SELECT 366 367 IF ( plant_canopy ) THEN 368 369 WRITE ( io, 280 ) canopy_mode, pch_index, drag_coefficient 370 371 ! 372 !-- Leaf area density profile 373 !-- Building output strings, starting with surface value 374 WRITE ( learde, '(F6.2)' ) lad_surface 375 gradients = '------' 376 slices = ' 0' 377 coordinates = ' 0.0' 378 i = 1 379 DO WHILE ( lad_vertical_gradient_level_ind(i) /= -9999 ) 380 381 WRITE (coor_chr,'(F7.2)') lad(lad_vertical_gradient_level_ind(i)) 382 learde = TRIM( learde ) // ' ' // TRIM( coor_chr ) 383 384 WRITE (coor_chr,'(F7.2)') lad_vertical_gradient(i) 385 gradients = TRIM( gradients ) // ' ' // TRIM( coor_chr ) 386 387 WRITE (coor_chr,'(I7)') lad_vertical_gradient_level_ind(i) 388 slices = TRIM( slices ) // ' ' // TRIM( coor_chr ) 389 390 WRITE (coor_chr,'(F7.1)') lad_vertical_gradient_level(i) 391 coordinates = TRIM( coordinates ) // ' ' // TRIM( coor_chr ) 392 393 i = i + 1 394 ENDDO 395 396 WRITE ( io, 281 ) TRIM( coordinates ), TRIM( learde ), & 397 TRIM( gradients ), TRIM( slices ) 398 399 ENDIF 366 400 367 401 ! … … 1333 1367 ' Horizontal index bounds (l/r/s/n): ',I4,' / ',I4,' / ',I4, & 1334 1368 ' / ',I4) 1369 280 FORMAT (//' Vegetation canopy (drag) model:'/ & 1370 ' ------------------------------'// & 1371 ' Canopy mode: ', A / & 1372 ' Canopy top: ',I4 / & 1373 ' Leaf drag coefficient: ',F6.2 /) 1374 281 FORMAT (/ ' Characteristic levels of the leaf area density:'// & 1375 ' Height: ',A,' m'/ & 1376 ' Leaf area density: ',A,' m**2/m**3'/ & 1377 ' Gradient: ',A,' m**2/m**4'/ & 1378 ' Gridpoint: ',A) 1379 1335 1380 300 FORMAT (//' Boundary conditions:'/ & 1336 1381 ' -------------------'// & -
palm/trunk/SOURCE/init_3d_model.f90
r132 r138 235 235 236 236 ! 237 !-- 3D-arrays for the leaf area density and the canopy drag coefficient 238 IF ( plant_canopy ) THEN 239 ALLOCATE ( lad_s(nzb:nzt+1,nys-1:nyn+1,nxl-1:nxr+1), & 240 lad_u(nzb:nzt+1,nys-1:nyn+1,nxl-1:nxr+1), & 241 lad_v(nzb:nzt+1,nys-1:nyn+1,nxl-1:nxr+1), & 242 lad_w(nzb:nzt+1,nys-1:nyn+1,nxl-1:nxr+1), & 243 cdc(nzb:nzt+1,nys-1:nyn+1,nxl-1:nxr+1) ) 244 ENDIF 245 246 ! 237 247 !-- 4D-array for storing the Rif-values at vertical walls 238 248 IF ( topography /= 'flat' ) THEN … … 923 933 'problem' 924 934 CALL local_stop 935 ENDIF 936 937 ! 938 !-- Initialization of the leaf area density 939 IF ( plant_canopy ) THEN 940 941 SELECT CASE ( TRIM( canopy_mode ) ) 942 943 CASE( 'block' ) 944 945 DO i = nxl-1, nxr+1 946 DO j = nys-1, nyn+1 947 lad_s(:,j,i) = lad(:) 948 cdc(:,j,i) = drag_coefficient 949 ENDDO 950 ENDDO 951 952 CASE DEFAULT 953 954 ! 955 !-- The DEFAULT case is reached either if the parameter 956 !-- canopy mode contains a wrong character string or if the 957 !-- user has coded a special case in the user interface. 958 !-- There, the subroutine user_init_plant_canopy checks 959 !-- which of these two conditions applies. 960 CALL user_init_plant_canopy 961 962 END SELECT 963 964 CALL exchange_horiz( lad_s ) 965 CALL exchange_horiz( cdc ) 966 967 DO i = nxl, nxr 968 DO j = nys, nyn 969 DO k = nzb, nzt+1 970 lad_u(k,j,i) = 0.5 * ( lad_s(k,j,i-1) + lad_s(k,j,i) ) 971 lad_v(k,j,i) = 0.5 * ( lad_s(k,j-1,i) + lad_s(k,j,i) ) 972 ENDDO 973 DO k = nzb, nzt 974 lad_w(k,j,i) = 0.5 * ( lad_s(k+1,j,i) + lad_s(k,j,i) ) 975 ENDDO 976 ENDDO 977 ENDDO 978 979 lad_w(nzt+1,:,:) = lad_w(nzt,:,:) 980 981 CALL exchange_horiz( lad_u ) 982 CALL exchange_horiz( lad_v ) 983 CALL exchange_horiz( lad_w ) 984 925 985 ENDIF 926 986 -
palm/trunk/SOURCE/modules.f90
r132 r138 5 5 ! Actual revisions: 6 6 ! ----------------- 7 ! +drag_coefficient, pch_index, lad_surface, lad_vertical_gradient, 8 ! lad_vertical_gradient_level, plant_canopy, lad, lad_s, lad_u, lad_v, 9 ! lad_w, cdc, lad_vertical_gradient_level_ind, canopy_mode 10 ! 7 11 ! +dt_sort_particles, ngp_2dh_s_inner, time_sort_particles, flags, 8 12 ! wall_flags_1..10, wall_humidityflux(0:4), wall_qflux(0:4), … … 107 111 108 112 REAL, DIMENSION(:), ALLOCATABLE :: & 109 ddzu, dd2zu, dzu, ddzw, dzw, hyp, km_damp_x, km_damp_y, l _grid,&113 ddzu, dd2zu, dzu, ddzw, dzw, hyp, km_damp_x, km_damp_y, lad, l_grid, & 110 114 pt_init, q_init, rdf, sa_init, ug, u_init, u_nzb_p1_for_vfc, vg, & 111 115 v_init, v_nzb_p1_for_vfc, zu, zw … … 126 130 127 131 REAL, DIMENSION(:,:,:), ALLOCATABLE :: & 128 d, diss, l_wall, tend, u_m_l, u_m_n, u_m_r, u_m_s, v_m_l, v_m_n, & 129 v_m_r, v_m_s, w_m_l, w_m_n, w_m_r, w_m_s 132 cdc, d, diss, lad_s, lad_u, lad_v, lad_w, l_wall, tend, & 133 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, & 134 w_m_n, w_m_r, w_m_s 130 135 131 136 REAL, DIMENSION(:,:,:), ALLOCATABLE, TARGET :: & … … 259 264 bc_sa_t = 'neumann', & 260 265 bc_uv_b = 'dirichlet', bc_uv_t = 'dirichlet', & 266 canopy_mode = 'block', & 261 267 coupling_mode = 'uncoupled', & 262 268 coupling_mode_remote = 'uncoupled', & … … 307 313 do2d_xz_time_count(0:1), do2d_yz_time_count(0:1), & 308 314 do3d_no(0:1) = 0, do3d_time_count(0:1), & 315 lad_vertical_gradient_level_ind(10) = -9999, & 316 pch_index = 0, & 309 317 pt_vertical_gradient_level_ind(10) = -9999, & 310 318 q_vertical_gradient_level_ind(10) = -9999, & … … 340 348 outflow_l = .FALSE., outflow_n = .FALSE., outflow_r = .FALSE., & 341 349 outflow_s = .FALSE., passive_scalar = .FALSE., & 350 plant_canopy = .FALSE., & 342 351 prandtl_layer = .TRUE., precipitation = .FALSE., & 343 352 profil_output = .FALSE., radiation = .FALSE., & … … 365 374 disturbance_level_b = -9999999.9, & 366 375 disturbance_level_t = -9999999.9, & 376 drag_coefficient = 0.0, & 367 377 dt = -1.0, dt_averaging_input = 0.0, & 368 378 dt_averaging_input_pr = 9999999.9, dt_coupling = 9999999.9, & … … 379 389 end_time = 0.0, & 380 390 f = 0.0, fs = 0.0, g = 9.81, kappa = 0.4, km_constant = -1.0, & 381 km_damp_max = -1.0, l ong_filter_factor = 0.0, &391 km_damp_max = -1.0, lad_surface = 0.0, long_filter_factor = 0.0, & 382 392 maximum_cpu_time_allowed = 0.0, molecular_viscosity = 1.461E-5, & 383 393 old_dt = 1.0E-10, omega = 7.29212E-5, omega_sor = 1.8, & … … 419 429 420 430 REAL :: do2d_xy_last_time(0:1) = -1.0, do2d_xz_last_time(0:1) = -1.0, & 421 do2d_yz_last_time(0:1) = -1.0, pt_vertical_gradient(10) = 0.0, & 431 do2d_yz_last_time(0:1) = -1.0, & 432 lad_vertical_gradient(10) = 0.0, & 433 lad_vertical_gradient_level(10) = -9999999.9, & 434 pt_vertical_gradient(10) = 0.0, & 422 435 pt_vertical_gradient_level(10) = -9999999.9, & 423 436 q_vertical_gradient(10) = 0.0, & -
palm/trunk/SOURCE/parin.f90
r110 r138 4 4 ! Actual revisions: 5 5 ! ----------------- 6 ! 6 ! +canopy_mode 7 ! +drag_coefficient, lad_surface, lad_vertical_gradient, 8 ! +lad_vertical_gradient_level, pch_index, plant_canopy 9 ! +allocation of leaf area density field 10 ! 7 11 ! 8 12 ! Former revisions: … … 70 74 bc_ns, bc_p_b, bc_p_t, bc_pt_b, bc_pt_t, bc_q_b, & 71 75 bc_q_t,bc_s_b, bc_s_t, bc_sa_t, bc_uv_b, bc_uv_t, & 72 bottom_salinityflux, building_height, &73 building_length_ x, building_length_y, building_wall_left, &74 building_wall_south, c loud_droplets, cloud_physics, &76 bottom_salinityflux, building_height, building_length_x, & 77 building_length_y, building_wall_left, & 78 building_wall_south, canopy_mode, cloud_droplets, cloud_physics, & 75 79 conserve_volume_flow, cut_spline_overshoot, damp_level_1d, & 76 dissipation_1d, d t, dt_pr_1d, dt_run_control_1d, dx, dy, dz, &77 d z_max, dz_stretch_factor, dz_stretch_level, e_init, e_min, &78 end_time_1d, &79 fft_method,galilei_transformation, grid_matching, humidity, &80 dissipation_1d, drag_coefficient, dt, dt_pr_1d, & 81 dt_run_control_1d, dx, dy, dz, dz_max, dz_stretch_factor, & 82 dz_stretch_level, e_init, e_min, end_time_1d, fft_method, & 83 galilei_transformation, grid_matching, humidity, & 80 84 inflow_disturbance_begin, inflow_disturbance_end, & 81 initializing_actions, km_constant, km_damp_max, & 85 initializing_actions, km_constant, km_damp_max, lad_surface, & 86 lad_vertical_gradient, lad_vertical_gradient_level, & 82 87 long_filter_factor, loop_optimization, mixing_length_1d, & 83 88 momentum_advec, netcdf_precision, npex, npey, nsor_ini, nx, ny, & 84 89 nz, ocean, omega, outflow_damping_width, overshoot_limit_e, & 85 90 overshoot_limit_pt, overshoot_limit_u, overshoot_limit_v, & 86 overshoot_limit_w, passive_scalar, p hi, prandtl_layer, &87 p recipitation, pt_reference, pt_surface, &88 pt_surface _initial_change, pt_vertical_gradient, &91 overshoot_limit_w, passive_scalar, pch_index, phi, & 92 plant_canopy, prandtl_layer, precipitation, pt_reference, & 93 pt_surface, pt_surface_initial_change, pt_vertical_gradient, & 89 94 pt_vertical_gradient_level, q_surface, q_surface_initial_change, & 90 95 q_vertical_gradient, q_vertical_gradient_level, radiation, & … … 242 247 hom = 0.0 243 248 249 IF ( plant_canopy ) THEN 250 ALLOCATE( lad(0:nz+1) ) 251 lad(:) = 0.0 252 ENDIF 253 244 254 ENDIF 245 255 -
palm/trunk/SOURCE/prognostic_equations.f90
r129 r138 4 4 ! Actual revisions: 5 5 ! ----------------- 6 ! add call of subroutines that evaluate the canopy drag terms 6 7 ! add wall_*flux to parameter list of calls of diffusion_s 7 8 ! … … 80 81 USE diffusion_w_mod 81 82 USE impact_of_latent_heat_mod 83 USE plant_canopy_model_mod 82 84 USE production_e_mod 83 85 USE user_actions_mod … … 160 162 CALL coriolis( i, j, 1 ) 161 163 IF ( sloping_surface ) CALL buoyancy( i, j, pt, pt_reference, 1, 4 ) 164 165 ! 166 !-- Drag by plant canopy 167 IF ( plant_canopy ) CALL plant_canopy_model( i, j, 1 ) 162 168 CALL user_actions( i, j, 'u-tendency' ) 163 169 … … 227 233 ENDIF 228 234 CALL coriolis( i, j, 2 ) 235 236 ! 237 !-- Drag by plant canopy 238 IF ( plant_canopy ) CALL plant_canopy_model( i, j, 2 ) 239 229 240 CALL user_actions( i, j, 'v-tendency' ) 230 241 … … 303 314 ENDIF 304 315 ENDIF 316 317 ! 318 !-- Drag by plant canopy 319 IF ( plant_canopy ) CALL plant_canopy_model( i, j, 3 ) 320 305 321 CALL user_actions( i, j, 'w-tendency' ) 306 322 … … 732 748 ENDIF 733 749 CALL production_e( i, j ) 750 751 ! 752 !-- Additional sink term for flows through plant canopies 753 IF ( plant_canopy ) CALL plant_canopy_model( i, j, 4 ) 754 734 755 CALL user_actions( i, j, 'e-tendency' ) 735 756 … … 833 854 IF ( sloping_surface ) CALL buoyancy( i, j, pt, pt_reference, 1, & 834 855 4 ) 856 857 ! 858 !-- Drag by plant canopy 859 IF ( plant_canopy ) CALL plant_canopy_model( i, j, 1 ) 860 835 861 CALL user_actions( i, j, 'u-tendency' ) 836 862 … … 882 908 ENDIF 883 909 CALL coriolis( i, j, 2 ) 910 911 ! 912 !-- Drag by plant canopy 913 IF ( plant_canopy ) CALL plant_canopy_model( i, j, 2 ) 914 884 915 CALL user_actions( i, j, 'v-tendency' ) 885 916 … … 938 969 ENDIF 939 970 ENDIF 971 972 ! 973 !-- Drag by plant canopy 974 IF ( plant_canopy ) CALL plant_canopy_model( i, j, 3 ) 975 940 976 CALL user_actions( i, j, 'w-tendency' ) 941 977 … … 1177 1213 ENDIF 1178 1214 CALL production_e( i, j ) 1215 1216 ! 1217 !-- Additional sink term for flows through plant canopies 1218 IF ( plant_canopy ) CALL plant_canopy_model( i, j, 4 ) 1219 1179 1220 CALL user_actions( i, j, 'e-tendency' ) 1180 1221 … … 1269 1310 CALL coriolis( 1 ) 1270 1311 IF ( sloping_surface ) CALL buoyancy( pt, pt_reference, 1, 4 ) 1312 1313 ! 1314 !-- Drag by plant canopy 1315 IF ( plant_canopy ) CALL plant_canopy_model( 1 ) 1316 1271 1317 CALL user_actions( 'u-tendency' ) 1272 1318 … … 1340 1386 ENDIF 1341 1387 CALL coriolis( 2 ) 1388 1389 ! 1390 !-- Drag by plant canopy 1391 IF ( plant_canopy ) CALL plant_canopy_model( 2 ) 1342 1392 CALL user_actions( 'v-tendency' ) 1343 1393 … … 1420 1470 ENDIF 1421 1471 ENDIF 1472 1473 ! 1474 !-- Drag by plant canopy 1475 IF ( plant_canopy ) CALL plant_canopy_model( 3 ) 1476 1422 1477 CALL user_actions( 'w-tendency' ) 1423 1478 … … 1858 1913 ENDIF 1859 1914 CALL production_e 1915 1916 ! 1917 !-- Additional sink term for flows through plant canopies 1918 IF ( plant_canopy ) CALL plant_canopy_model( 4 ) 1860 1919 CALL user_actions( 'e-tendency' ) 1861 1920 -
palm/trunk/SOURCE/read_var_list.f90
r116 r138 4 4 ! Actual revisions: 5 5 ! ----------------- 6 ! +canopy_mode 7 ! +drag_coefficient, lad, lad_surface, lad_vertical_gradient, 8 ! lad_vertical_gradient_level, lad_vertical_gradient_level_ind, 9 ! pch_index, plant_canopy 10 ! 6 11 ! +time_sort_particles 7 12 ! … … 186 191 CASE ( 'building_wall_south' ) 187 192 READ ( 13 ) building_wall_south 193 CASE ( 'canopy_mode' ) 194 READ ( 13 ) canopy_mode 188 195 CASE ( 'cloud_droplets' ) 189 196 READ ( 13 ) cloud_droplets … … 200 207 CASE ( 'dissipation_1d' ) 201 208 READ ( 13 ) dissipation_1d 209 CASE ( 'drag_coefficient' ) 210 READ ( 13 ) drag_coefficient 202 211 CASE ( 'dt_fixed' ) 203 212 READ ( 13 ) dt_fixed … … 244 253 CASE ( 'km_damp_max' ) 245 254 READ ( 13 ) km_damp_max 255 CASE ( 'lad' ) 256 READ ( 13 ) lad 257 CASE ( 'lad_surface' ) 258 READ ( 13 ) lad_surface 259 CASE ( 'lad_vertical_gradient' ) 260 READ ( 13 ) lad_vertical_gradient 261 CASE ( 'lad_vertical_gradient_level' ) 262 READ ( 13 ) lad_vertical_gradient_level 263 CASE ( 'lad_vertical_gradient_level_in' ) 264 READ ( 13 ) lad_vertical_gradient_level_ind 246 265 CASE ( 'last_dt_change' ) 247 266 READ ( 13 ) last_dt_change … … 288 307 CASE ( 'passive_scalar' ) 289 308 READ ( 13 ) passive_scalar 309 CASE ( 'pch_index' ) 310 READ ( 13 ) pch_index 290 311 CASE ( 'phi' ) 291 312 READ ( 13 ) phi 313 CASE ( 'plant_canopy' ) 314 READ ( 13 ) plant_canopy 292 315 CASE ( 'prandtl_layer' ) 293 316 READ ( 13 ) prandtl_layer -
palm/trunk/SOURCE/user_interface.f90
r136 r138 4 4 ! Actual revisions: 5 5 ! ----------------- 6 ! new subroutine user_init_plant_canopy 7 ! 6 8 ! new subroutine user_data_output_dvrp 7 9 ! +argument gls in user_init_grid … … 293 295 294 296 END SUBROUTINE user_init_grid 297 298 299 300 SUBROUTINE user_init_plant_canopy 301 302 !------------------------------------------------------------------------------! 303 ! 304 ! Description: 305 ! ------------ 306 ! Initialisation of the leaf area density array (for scalar grid points) and 307 ! the array of the canopy drag coefficient, if the user has not chosen any 308 ! of the default cases 309 !------------------------------------------------------------------------------! 310 311 USE arrays_3d 312 USE control_parameters 313 USE indices 314 USE user 315 316 IMPLICIT NONE 317 318 INTEGER :: i, j 319 320 ! 321 !-- Here the user-defined grid initializing actions follow: 322 323 ! 324 !-- Set the 3D-arrays lad_s and cdc for user defined canopies 325 SELECT CASE ( TRIM( canopy_mode ) ) 326 327 CASE ( 'block' ) 328 ! 329 !-- Not allowed here since this is the standard case used in init_3d_model. 330 331 CASE ( 'user_defined_canopy_1' ) 332 ! 333 !-- Here the user can define his own topography. 334 !-- The following lines contain an example in that the 335 !-- plant canopy extends only over the second half of the 336 !-- model domain along x 337 ! DO i = nxl-1, nxr+1 338 ! IF ( i >= INT(nx+1/2) ) THEN 339 ! DO j = nys-1, nyn+1 340 ! lad_s(:,j,i) = lad(:) 341 ! cdc(:,j,i) = drag_coefficient 342 ! ENDDO 343 ! ELSE 344 ! lad_s(:,:,i) = 0.0 345 ! cdc(:,:,i) = 0.0 346 ! ENDIF 347 ! ENDDO 348 !-- After definition, please 349 !-- remove the following three lines! 350 PRINT*, '+++ user_init_plant_canopy: canopy_mode "', & 351 canopy_mode, '" not available yet' 352 353 CASE DEFAULT 354 ! 355 !-- The DEFAULT case is reached if the parameter canopy_mode contains a 356 !-- wrong character string that is neither recognized in init_3d_model nor 357 !-- here in user_init_plant_canopy. 358 PRINT*, '+++ user_init_plant_canopy: unknown canopy_mode "', & 359 canopy_mode, '"' 360 CALL local_stop 361 362 END SELECT 363 364 365 END SUBROUTINE user_init_plant_canopy 295 366 296 367 -
palm/trunk/SOURCE/write_var_list.f90
r116 r138 4 4 ! Actual revisions: 5 5 ! ----------------- 6 ! +canopy_mode 7 ! +drag_coefficient, lad, lad_surface, lad_vertical_gradient, 8 ! lad_vertical_gradient_level, lad_vertical_gradient_level_ind, 9 ! pch_index, plant_canopy 10 ! 6 11 ! +time_sort_particles 7 12 ! … … 132 137 WRITE ( 14 ) 'building_wall_south ' 133 138 WRITE ( 14 ) building_wall_south 139 WRITE ( 14 ) 'canopy_mode ' 140 WRITE ( 14 ) canopy_mode 134 141 WRITE ( 14 ) 'cloud_droplets ' 135 142 WRITE ( 14 ) cloud_droplets … … 146 153 WRITE ( 14 ) 'dissipation_1d ' 147 154 WRITE ( 14 ) dissipation_1d 155 WRITE ( 14 ) 'drag_coefficient ' 156 WRITE ( 14 ) drag_coefficient 148 157 WRITE ( 14 ) 'dt_fixed ' 149 158 WRITE ( 14 ) dt_fixed … … 190 199 WRITE ( 14 ) 'km_damp_max ' 191 200 WRITE ( 14 ) km_damp_max 201 WRITE ( 14 ) 'lad ' 202 WRITE ( 14 ) lad 203 WRITE ( 14 ) 'lad_surface ' 204 WRITE ( 14 ) lad_surface 205 WRITE ( 14 ) 'lad_vertical_gradient ' 206 WRITE ( 14 ) lad_vertical_gradient 207 WRITE ( 14 ) 'lad_vertical_gradient_level ' 208 WRITE ( 14 ) lad_vertical_gradient_level 209 WRITE ( 14 ) 'lad_vertical_gradient_level_in' 210 WRITE ( 14 ) lad_vertical_gradient_level_ind 192 211 WRITE ( 14 ) 'last_dt_change ' 193 212 WRITE ( 14 ) last_dt_change … … 234 253 WRITE ( 14 ) 'passive_scalar ' 235 254 WRITE ( 14 ) passive_scalar 255 WRITE ( 14 ) 'pch_index ' 256 WRITE ( 14 ) pch_index 236 257 WRITE ( 14 ) 'phi ' 237 258 WRITE ( 14 ) phi 259 WRITE ( 14 ) 'plant_canopy ' 260 WRITE ( 14 ) plant_canopy 238 261 WRITE ( 14 ) 'prandtl_layer ' 239 262 WRITE ( 14 ) prandtl_layer
Note: See TracChangeset
for help on using the changeset viewer.