[1682] | 1 | !> @file user_init.f90 |
---|
[1036] | 2 | !--------------------------------------------------------------------------------! |
---|
| 3 | ! This file is part of PALM. |
---|
| 4 | ! |
---|
| 5 | ! PALM is free software: you can redistribute it and/or modify it under the terms |
---|
| 6 | ! of the GNU General Public License as published by the Free Software Foundation, |
---|
| 7 | ! either version 3 of the License, or (at your option) any later version. |
---|
| 8 | ! |
---|
| 9 | ! PALM is distributed in the hope that it will be useful, but WITHOUT ANY |
---|
| 10 | ! WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR |
---|
| 11 | ! A PARTICULAR PURPOSE. See the GNU General Public License for more details. |
---|
| 12 | ! |
---|
| 13 | ! You should have received a copy of the GNU General Public License along with |
---|
| 14 | ! PALM. If not, see <http://www.gnu.org/licenses/>. |
---|
| 15 | ! |
---|
[1818] | 16 | ! Copyright 1997-2016 Leibniz Universitaet Hannover |
---|
[1036] | 17 | !--------------------------------------------------------------------------------! |
---|
| 18 | ! |
---|
[484] | 19 | ! Current revisions: |
---|
[211] | 20 | ! ----------------- |
---|
[1800] | 21 | ! |
---|
| 22 | ! |
---|
[211] | 23 | ! Former revisions: |
---|
| 24 | ! ----------------- |
---|
| 25 | ! $Id: user_init.f90 1818 2016-04-06 15:53:27Z raasch $ |
---|
| 26 | ! |
---|
[1800] | 27 | ! 1799 2016-04-05 08:35:55Z gronemeier |
---|
| 28 | ! Bugfix: added dots_num to variable list |
---|
| 29 | ! |
---|
[1784] | 30 | ! 1783 2016-03-06 18:36:17Z raasch |
---|
| 31 | ! netcdf module name changed + related changes |
---|
| 32 | ! |
---|
[1683] | 33 | ! 1682 2015-10-07 23:56:08Z knoop |
---|
| 34 | ! Code annotations made doxygen readable |
---|
| 35 | ! |
---|
[1354] | 36 | ! 1353 2014-04-08 15:21:23Z heinze |
---|
| 37 | ! REAL constants provided with KIND-attribute |
---|
| 38 | ! |
---|
[1321] | 39 | ! 1320 2014-03-20 08:40:49Z raasch |
---|
| 40 | ! revision history before 2012 removed, |
---|
| 41 | ! comment fields (!:) to be used for variable explanations added to |
---|
| 42 | ! all variable declaration statements |
---|
| 43 | ! |
---|
[1037] | 44 | ! 1036 2012-10-22 13:43:42Z raasch |
---|
| 45 | ! code put under GPL (PALM 3.9) |
---|
| 46 | ! |
---|
[226] | 47 | ! 211 2008-11-11 04:46:24Z raasch |
---|
| 48 | ! Former file user_interface.f90 split into one file per subroutine |
---|
| 49 | ! |
---|
[211] | 50 | ! Description: |
---|
| 51 | ! ------------ |
---|
[1682] | 52 | !> Execution of user-defined initializing actions |
---|
[211] | 53 | !------------------------------------------------------------------------------! |
---|
[1682] | 54 | SUBROUTINE user_init |
---|
| 55 | |
---|
[211] | 56 | |
---|
| 57 | USE control_parameters |
---|
[1320] | 58 | |
---|
[211] | 59 | USE indices |
---|
[1320] | 60 | |
---|
| 61 | USE kinds |
---|
| 62 | |
---|
[1783] | 63 | USE netcdf_interface, & |
---|
[1799] | 64 | ONLY: dots_label, dots_unit, dots_num |
---|
[1320] | 65 | |
---|
[211] | 66 | USE pegrid |
---|
[1320] | 67 | |
---|
[211] | 68 | USE user |
---|
| 69 | |
---|
| 70 | IMPLICIT NONE |
---|
| 71 | |
---|
[1682] | 72 | CHARACTER (LEN=20) :: field_char !< |
---|
[211] | 73 | ! |
---|
| 74 | !-- Here the user-defined initializing actions follow: |
---|
| 75 | !-- Sample for user-defined output |
---|
[667] | 76 | ! ALLOCATE( u2(nzb:nzt+1,nysg:nyng,nxlg:nxrg) ) |
---|
[1353] | 77 | ! ALLOCATE( ustvst(nzb:nzt+1,nysg:nyng,nxlg:nxrg) ); ustvst = 0.0_wp |
---|
[211] | 78 | |
---|
| 79 | !-- Sample for user-defined time series |
---|
| 80 | !-- For each time series quantity you have to give a label and a unit, |
---|
| 81 | !-- which will be used for the NetCDF file. They must not contain more than |
---|
| 82 | !-- seven characters. The value of dots_num has to be increased by the |
---|
| 83 | !-- number of new time series quantities. Its old value has to be store in |
---|
| 84 | !-- dots_num_palm. See routine user_statistics on how to output calculate |
---|
| 85 | !-- and output these quantities. |
---|
| 86 | ! dots_label(dots_num+1) = 'abs_umx' |
---|
| 87 | ! dots_unit(dots_num+1) = 'm/s' |
---|
| 88 | ! dots_label(dots_num+2) = 'abs_vmx' |
---|
| 89 | ! dots_unit(dots_num+2) = 'm/s' |
---|
| 90 | ! |
---|
| 91 | ! dots_num_palm = dots_num |
---|
| 92 | ! dots_num = dots_num + 2 |
---|
| 93 | |
---|
| 94 | END SUBROUTINE user_init |
---|
| 95 | |
---|