source: palm/trunk/SOURCE/user_init_plant_canopy.f90 @ 4356

Last change on this file since 4356 was 4341, checked in by motisi, 5 years ago

plant_canopy_model: unification of variable names: pc_ variabels now pcm_ variables
removal of bowenratio output
canopy mode 'block' now 'homogeneous'
'read_from_file_3d' now 'read_from_file'
removal of confusing comment lines
replacement of k_wall by topo_top_ind
removal of else-statement in tendency-calculation

  • Property svn:keywords set to Id
File size: 3.6 KB
Line 
1!> @file user_init_plant_canopy.f90
2!------------------------------------------------------------------------------!
3! This file is part of the PALM model system.
4!
5! PALM is free software: you can redistribute it and/or modify it under the
6! terms of the GNU General Public License as published by the Free Software
7! Foundation, either version 3 of the License, or (at your option) any later
8! version.
9!
10! PALM is distributed in the hope that it will be useful, but WITHOUT ANY
11! WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
12! A PARTICULAR PURPOSE.  See the GNU General Public License for more details.
13!
14! You should have received a copy of the GNU General Public License along with
15! PALM. If not, see <http://www.gnu.org/licenses/>.
16!
17! Copyright 1997-2019 Leibniz Universitaet Hannover
18!------------------------------------------------------------------------------!
19!
20! Current revisions:
21! -----------------
22!
23!
24! Former revisions:
25! -----------------
26! $Id: user_init_plant_canopy.f90 4341 2019-12-16 10:43:49Z suehring $
27! Renamed canopy_mode 'block' to 'homogeneous'
28!
29! 4182 2019-08-22 15:20:23Z scharf
30! Corrected "Former revisions" section
31!
32! 3768 2019-02-27 14:35:58Z raasch
33! unused variables commented out to avoid compiler warnings
34!
35! 3655 2019-01-07 16:51:22Z knoop
36! Corrected "Former revisions" section
37!
38! 211 2008-11-11 04:46:24Z raasch
39! Former file user_interface.f90 split into one file per subroutine
40!
41! Description:
42! ------------
43!> Initialisation of the leaf area density array (for scalar grid points) and
44!> the array of the canopy drag coefficient, if the user has not chosen any
45!> of the default cases
46!------------------------------------------------------------------------------!
47 SUBROUTINE user_init_plant_canopy
48 
49
50    USE arrays_3d
51   
52    USE control_parameters
53   
54    USE indices
55   
56    USE kinds
57
58    USE plant_canopy_model_mod
59   
60    USE user
61
62    IMPLICIT NONE
63
64!    INTEGER(iwp) :: i   !< running index
65!    INTEGER(iwp) :: j   !< running index
66
67!
68!-- Here the user-defined grid initializing actions follow:
69
70!
71!-- Set the 3D-array lad_s for user defined canopies
72    SELECT CASE ( TRIM( canopy_mode ) )
73
74       CASE ( 'homogeneous' )
75!
76!--       Not allowed here since this is the standard case used in init_3d_model.
77
78       CASE ( 'user_defined_canopy_1' )
79!
80!--       Here the user can define his own forest topography.
81!--       The following lines contain an example, where the plant canopy extends
82!--       only over the second half of the model domain along x.
83!--       Attention: DO-loops have to include the ghost points (nxlg-nxrg,
84!--       nysg-nyng), because no exchange of ghost point information is intended,
85!--       in order to minimize communication between CPUs.
86!          DO  i = nxlg, nxrg
87!             IF ( i >= INT( ( nx+1 ) / 2 ) ) THEN
88!                DO  j = nysg, nyng
89!                   lad_s(:,j,i) = lad(:)
90!                ENDDO
91!             ELSE
92!                lad_s(:,:,i) = 0.0_wp
93!             ENDIF
94!          ENDDO
95!
96!--       After definition, please
97!--       remove the following three lines!
98          message_string = 'canopy_mode "' // canopy_mode // &
99                           '" not available yet'
100          CALL message( 'user_init_plant_canopy', 'UI0007', 0, 1, 0, 6, 0 )
101         
102       CASE DEFAULT
103!
104!--       The DEFAULT case is reached if the parameter canopy_mode contains a
105!--       wrong character string that is neither recognized in init_3d_model nor
106!--       here in user_init_plant_canopy.
107          message_string = 'unknown canopy_mode "' // canopy_mode // '"'
108          CALL message( 'user_init_plant_canopy', 'UI0008', 1, 2, 0, 6, 0 )
109
110    END SELECT
111
112
113 END SUBROUTINE user_init_plant_canopy
114
Note: See TracBrowser for help on using the repository browser.