Changes between Version 64 and Version 65 of doc/app/userint/output
- Timestamp:
- Oct 28, 2010 1:44:53 PM (14 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
doc/app/userint/output
v64 v65 7 7 1. (horizontally averaged) [#part_1 vertical profiles] 8 8 2. [#part_2 time series] 9 3. [#part_3 2d cross section], [#part_3 3d volume data] or [#part_3 mask data]9 3. [#part_3 2d cross section], [#part_3 3d volume data] or [#part_3 masked data] 10 10 4. [#part_4 dvrp objects] 11 11 5. [#part_5 spectra]\\\\ … … 65 65 This example shows the output of the quantity "square of the u-component" ('''Note:''' this quantity could of course easily be calculated from the u-component by postprocessing the {{{PALM}}} output so that calculation within {{{PALM}}} is not necessarily required). If more than one user-defined quantity shall be output, the following steps have to be carried out in the same way for each of the quantities. 66 66 67 1. The quantity has to be given a unique string identifier, e.g.'' 'u2'.'' This identifier must be different from the identifiers used for the {{{PALM}}} standard output (see list in description of parameter [../../d3par#data_output data_output]). To switch on output of this quantity, the user has to assign the string identifier to the parameter [../../userpar#data_output_user data_output_user], eg.: \\67 1. For output of '''2d cross sections''' and '''3d volume data''', the quantity has to be given a unique string identifier, e.g.'' 'u2'.'' This identifier must be different from the identifiers used for the {{{PALM}}} standard output (see list in description of parameter [../../d3par#data_output data_output]). To switch on output of this quantity, the user has to assign the string identifier to the parameter [../../userpar#data_output_user data_output_user], eg.: \\ 68 68 69 69 {{{ data_output_user = 'u2', 'u2_xy_av' }}} 70 70 71 71 The pure string'' 'u2' ''switches on the output of instantaneous 3d volume data. Output of cross section data and time averaged data is switched on by additionally appending the strings'' '_xy', '_xz', '_yz', ''and/or'' '_av' ''(for a detailed explanation see parameter [../../d3par#data_output data_output]).\\ 72 2. In order to store the quantities' grid point data within PALM, a 3d data array has to be declared in module [../int#user user]: \\ 72 73 2. For output of '''masked data''', the quantity has to be given a unique string identifier, e.g.'' 'u2'.'' This identifier must be different from the identifiers used for the {{{PALM}}} standard output (see list in description of parameter [../../d3par#data_output_masks data_output_masks]). To switch on output of this quantity, the user has to assign the string identifier to the parameter [../../userpar#data_output_masks_user data_output_masks_user], eg.: \\ 74 75 {{{ data_output_masks_user(1,:) = 'u2', }}} 76 77 3. In order to store the quantities' grid point data within PALM, a 3d data array has to be declared in module [../int#user user]: \\ 73 78 74 79 {{{ REAL, DIMENSION(:,:,:), ALLOCATABLE :: u2, u2_av }}} // 75 80 76 81 The second array {{{u2_av}}} is needed in case that output of time averaged data is requested. It is used to store the sum of the data of the respective time levels over which the average has to be carried out. \\ 77 3. The data array has to be allocated in subroutine [../int#user_init user_init]: \\82 4. The data array has to be allocated in subroutine [../int#user_init user_init]: \\ 78 83 79 84 {{{ALLOCATE( u2(nzb:nzt+1,nys-1:nyn+1,nxl-1:nxr+1) ) }}} 80 85 81 4. The quantity has to be given a unit (subroutine [../int#user_check_data_output user_check_data_output]): \\86 5. The quantity has to be given a unit (subroutine [../int#user_check_data_output user_check_data_output]): \\ 82 87 83 88 {{{ CASE ( 'u2' )}}} \\ … … 86 91 Otherwise, {{{PALM}}} will abort. \\ 87 92 88 5. The vertical grid on which the quantity is defined (given by the levels '{{{zu}}}' or '{{{zw}}}', on which the u- or w-component of the velocity are defined) has to be specified for the netCDF output files in subroutine [../int#user_define_netcdf_grid user_define_netcdf_grid]:93 6. The vertical grid on which the quantity is defined (given by the levels '{{{zu}}}' or '{{{zw}}}', on which the u- or w-component of the velocity are defined) has to be specified for the netCDF output files in subroutine [../int#user_define_netcdf_grid user_define_netcdf_grid]: 89 94 90 95 {{{ CASE ( 'u2', 'u2_xy', 'u2_xz', 'u2_yz' ) }}} \\ … … 93 98 As the example shows, this grid has to be defined for the 3d volume data as well as for all of the three cross sections. \\ 94 99 95 6. After each timestep, the quantity has to be calculated at all gridpoints and to be stored. This has to be done in subroutine [../int#user_actions user_actions] at location 'after_integration': \\100 7. After each timestep, the quantity has to be calculated at all gridpoints and to be stored. This has to be done in subroutine [../int#user_actions user_actions] at location 'after_integration': \\ 96 101 97 102 {{{ CASE ( 'after_integration' ) }}} \\ … … 108 113 {{{ ENDDO }}} \\ 109 114 110 7. In case that output of time-averaged data is requested, the sum- and average-operations as well as the allocation of the sum-array have to be carried out in subroutine [../int#user_3d_data_averaging user_3d_data_averaging]: \\115 8. In case that output of time-averaged data is requested, the sum- and average-operations as well as the allocation of the sum-array have to be carried out in subroutine [../int#user_3d_data_averaging user_3d_data_averaging]: \\ 111 116 112 117 {{{ IF ( mode == 'allocate' ) THEN }}} \\ … … 140 145 {{{ ENDDO }}} \\ 141 146 142 8. For output of '''2d cross sections''', the gridpoint data of the quantity has to be resorted to array {{{local_pf}}} in subroutine [../int#user_data_output_2d user_data_output_2d]. Also the vertical grid, on which the quantity is defined, has to be set again: \\147 9. For output of '''2d cross sections''', the gridpoint data of the quantity has to be resorted to array {{{local_pf}}} in subroutine [../int#user_data_output_2d user_data_output_2d]. Also the vertical grid, on which the quantity is defined, has to be set again: \\ 143 148 144 149 {{{ CASE ( 'u2_xy', 'u2_xz', 'u2_yz' ) }}} \\ … … 186 191 Note that {{{two_d = .TRUE.}}} is necessary for output of a 2d data slice. \\ 187 192 188 9. For output of '''3d volume data''', the gridpoint data of the quantity has to be resorted to {{{array local_pf}}} in subroutine [../int#user_data_output_3d user_data_output_3d].:193 10. For output of '''3d volume data''', the gridpoint data of the quantity has to be resorted to {{{array local_pf}}} in subroutine [../int#user_data_output_3d user_data_output_3d].: 189 194 190 195 {{{ CASE ( 'u2' ) }}} \\ … … 209 214 The {{{ELSE}}} case is only needed in case that output of time-averaged data is requested. 210 215 211 1 0. For output of '''masked data''', the gridpoint data of the quantity has to be resorted to {{{array local_pf}}} in subroutine [../int#user_data_output_mask user_data_output_mask].:216 11. For output of '''masked data''', the gridpoint data of the quantity has to be resorted to {{{array local_pf}}} in subroutine [../int#user_data_output_mask user_data_output_mask].: 212 217 213 218 {{{ CASE ( 'u2' ) }}} \\ … … 234 239 The {{{ELSE}}} case is only needed in case that output of time-averaged data is requested. 235 240 236 1 1. In case of job chains, the sum array has to be written to the (binary) restart file (local filename [../../iofiles#BINOUT BINOUT]) in subroutine [../int#user_last_actions user_last_actions]:241 12. In case of job chains, the sum array has to be written to the (binary) restart file (local filename [../../iofiles#BINOUT BINOUT]) in subroutine [../int#user_last_actions user_last_actions]: 237 242 238 243 {{{ IF ( ALLOCATED( u2_av ) ) THEN }}}\\