Changeset 4601 for palm/trunk/SOURCE
- Timestamp:
- Jul 14, 2020 12:06:09 PM (4 years ago)
- Location:
- palm/trunk/SOURCE
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
palm/trunk/SOURCE/chemistry_model_mod.f90
r4581 r4601 21 21 ! Current revisions: 22 22 ! ----------------- 23 ! 24 ! 23 ! 24 ! 25 25 ! Former revisions: 26 26 ! ----------------- 27 27 ! $Id$ 28 ! - Bugfix in variable name separation in profile-output initialization 29 ! - Bugfix in counting the number of chemistry profiles 30 ! 31 ! 4581 2020-06-29 08:49:58Z suehring 28 32 ! Enable output of resolved-scale vertical fluxes of chemical species. 29 33 ! … … 1109 1113 cs_pr_count_sp = cs_pr_count_sp + 1 1110 1114 cs_pr_index_sp(cs_pr_count_sp) = lsp 1111 dopr_index(var_count) = pr_palm + cs_pr_count_sp + cs_pr_count_fl_sgs + cs_pr_count_fl_res 1115 dopr_index(var_count) = pr_palm + cs_pr_count_sp + & 1116 cs_pr_count_fl_sgs + cs_pr_count_fl_res 1112 1117 dopr_unit = 'ppm' 1113 1118 IF ( spec_name(1:2) == 'PM') THEN 1114 1119 dopr_unit = 'kg m-3' 1115 1120 ENDIF 1116 hom(:,2, 1121 hom(:,2,dopr_index(var_count),:) = SPREAD( zu, 2, statistic_regions+1 ) 1117 1122 unit = dopr_unit 1118 1123 … … 1125 1130 IF ( TRIM( variable(1:5) ) == 'kc_w"' ) THEN 1126 1131 DO lsp = 1, nspec 1127 index_start = INDEX( TRIM( variable ), TRIM( chem_species(lsp)%name ) )1128 1132 index_end = LEN( TRIM( variable ) ) - 1 1129 IF ( index_start /= 0 ) THEN 1130 spec_name = TRIM( variable(index_start:index_end) ) 1131 IF ( TRIM( spec_name ) == TRIM( chem_species(lsp)%name ) ) THEN 1132 cs_pr_count_fl_sgs = cs_pr_count_fl_sgs + 1 1133 cs_pr_index_fl_sgs(cs_pr_count_fl_sgs) = lsp 1134 dopr_index(var_count) = pr_palm + cs_pr_count_sp + & 1135 cs_pr_count_fl_sgs + & 1136 cs_pr_count_fl_res 1137 dopr_unit = 'm ppm s-1' 1138 IF ( spec_name(1:2) == 'PM') THEN 1139 dopr_unit = 'kg m-2 s-1' 1140 ENDIF 1141 hom(:,2, dopr_index(var_count),:) = SPREAD( zu, 2, statistic_regions+1 ) 1142 unit = dopr_unit 1143 1144 hom_index_fl_sgs(cs_pr_count_fl_sgs) = dopr_index(var_count) 1133 index_start = 6 1134 spec_name = TRIM( variable(index_start:index_end) ) 1135 IF ( TRIM( spec_name ) == TRIM( chem_species(lsp)%name ) ) THEN 1136 cs_pr_count_fl_sgs = cs_pr_count_fl_sgs + 1 1137 cs_pr_index_fl_sgs(cs_pr_count_fl_sgs) = lsp 1138 dopr_index(var_count) = pr_palm + cs_pr_count_sp + & 1139 cs_pr_count_fl_sgs + & 1140 cs_pr_count_fl_res 1141 dopr_unit = 'm ppm s-1' 1142 IF ( spec_name(1:2) == 'PM') THEN 1143 dopr_unit = 'kg m-2 s-1' 1145 1144 ENDIF 1145 hom(:,2,dopr_index(var_count),:) = SPREAD( zu, 2, statistic_regions+1 ) 1146 unit = dopr_unit 1147 1148 hom_index_fl_sgs(cs_pr_count_fl_sgs) = dopr_index(var_count) 1146 1149 ENDIF 1147 1150 ENDDO … … 1152 1155 spec_name = TRIM( variable(6:) ) 1153 1156 DO lsp = 1, nspec 1154 index_start = INDEX( TRIM( variable ), TRIM( chem_species(lsp)%name ) )1157 index_start = 6 1155 1158 index_end = LEN( TRIM( variable ) ) - 1 1156 IF ( index_start /= 0 ) THEN 1157 spec_name = TRIM( variable(index_start:index_end) ) 1158 IF ( TRIM( spec_name ) == TRIM( chem_species(lsp)%name ) ) THEN 1159 cs_pr_count_fl_res = cs_pr_count_fl_res + 1 1160 cs_pr_index_fl_res(cs_pr_count_fl_res) = lsp 1161 dopr_index(var_count) = pr_palm + cs_pr_count_sp + & 1162 cs_pr_count_fl_sgs + & 1163 cs_pr_count_fl_res 1164 dopr_unit = 'm ppm s-1' 1165 IF ( spec_name(1:2) == 'PM') THEN 1166 dopr_unit = 'kg m-2 s-1' 1167 ENDIF 1168 hom(:,2, dopr_index(var_count),:) = SPREAD( zu, 2, statistic_regions+1 ) 1169 unit = dopr_unit 1170 1171 hom_index_fl_res(cs_pr_count_fl_res) = dopr_index(var_count) 1159 spec_name = TRIM( variable(index_start:index_end) ) 1160 IF ( TRIM( spec_name ) == TRIM( chem_species(lsp)%name ) ) THEN 1161 cs_pr_count_fl_res = cs_pr_count_fl_res + 1 1162 cs_pr_index_fl_res(cs_pr_count_fl_res) = lsp 1163 dopr_index(var_count) = pr_palm + cs_pr_count_sp + & 1164 cs_pr_count_fl_sgs + & 1165 cs_pr_count_fl_res 1166 dopr_unit = 'm ppm s-1' 1167 IF ( spec_name(1:2) == 'PM') THEN 1168 dopr_unit = 'kg m-2 s-1' 1172 1169 ENDIF 1170 hom(:,2, dopr_index(var_count),:) = SPREAD( zu, 2, statistic_regions+1 ) 1171 unit = dopr_unit 1172 1173 hom_index_fl_res(cs_pr_count_fl_res) = dopr_index(var_count) 1173 1174 ENDIF 1174 1175 ENDDO … … 2710 2711 i = 1 2711 2712 2712 DO WHILE ( data_output_pr(i) /= ' ' .AND. i <= 100 ) 2713 2713 DO WHILE ( data_output_pr(i) /= ' ' .AND. i <= SIZE( data_output_pr ) ) 2714 2714 IF ( TRIM( data_output_pr(i)(1:3) ) == 'kc_' ) THEN 2715 2715 max_pr_cs_tmp = max_pr_cs_tmp+1 -
palm/trunk/SOURCE/init_grid.f90
r4564 r4601 20 20 ! Current revisions: 21 21 ! ----------------- 22 ! 23 ! 22 ! 23 ! 24 24 ! Former revisions: 25 25 ! ----------------- 26 26 ! $Id$ 27 ! Minor formatting adjustments 28 ! 29 ! 4564 2020-06-12 14:03:36Z raasch 27 30 ! Vertical nesting method of Huq et al. (2019) removed 28 31 ! … … 281 284 'dz_stretch_level_end + 1 = ', & 282 285 number_stretch_level_end+1 283 286 CALL message( 'init_grid', 'PA0156', 1, 2, 0, 6, 0 ) 284 287 ENDIF 285 288 … … 294 297 'dz_stretch_level_start = ', & 295 298 number_stretch_level_start 296 299 CALL message( 'init_grid', 'PA0211', 1, 2, 0, 6, 0 ) 297 300 ENDIF 298 301 … … 307 310 'values for dz_stretch_level_end = ', & 308 311 number_stretch_level_end 309 312 CALL message( 'init_grid', 'PA0216', 1, 2, 0, 6, 0 ) 310 313 ENDIF 311 314 … … 345 348 IF ( ANY( min_dz_stretch_level_end(1:number_stretch_level_start) > & 346 349 dz_stretch_level_end(1:number_stretch_level_start) ) ) THEN 347 message_string= 'Each dz_stretch_level_end has to be larger ' //&348 'than its corresponding value for &' //&349 'dz_stretch_level_start + 4*MAX(dz(n),dz(n+1)) '//&350 351 350 message_string= 'Each dz_stretch_level_end has to be larger ' // & 351 'than its corresponding value for &' // & 352 'dz_stretch_level_start + 4*MAX(dz(n),dz(n+1)) '// & 353 'to allow for smooth grid stretching' 354 CALL message( 'init_grid', 'PA0224', 1, 2, 0, 6, 0 ) 352 355 ENDIF 353 356 … … 359 362 WRITE( message_string, * ) 'Each dz_stretch_level_start has to be ',& 360 363 'larger than ', dz(1) * 1.5 361 364 CALL message( 'init_grid', 'PA0226', 1, 2, 0, 6, 0 ) 362 365 ENDIF 363 366 -
palm/trunk/SOURCE/surface_data_output_mod.f90
r4600 r4601 25 25 ! ----------------- 26 26 ! $Id$ 27 ! Minor simplification in name creation for IO variables in restart files. 28 ! 29 ! 4600 2020-07-13 18:50:12Z suehring 27 30 ! - Change: adjustmens for mpi-io - surface data is transformed to a 2D-based surface array 28 31 ! before writing. … … 4701 4704 4702 4705 DO nv = 1, dosurf_no(1) 4703 IF ( nv < 10 ) WRITE( dum, '(I1)') nv 4704 IF ( nv < 100 .AND. nv >= 10 ) WRITE( dum, '(I2)') nv 4705 IF ( nv < 1000 .AND. nv >= 100 ) WRITE( dum, '(I3)') nv 4706 WRITE( dum, '(I3.3)' ) nv 4706 4707 4707 4708 CALL rd_mpi_io_check_array( 'surfaces%var_av' // TRIM( dum ), found = array_found ) … … 4954 4955 ENDDO 4955 4956 4956 IF ( nv < 10 ) WRITE( dum, '(I1)') nv 4957 IF ( nv < 100 .AND. nv >= 10 ) WRITE( dum, '(I2)') nv 4958 IF ( nv < 1000 .AND. nv >= 100 ) WRITE( dum, '(I3)') nv 4957 WRITE( dum, '(I3.3)' ) nv 4959 4958 4960 4959 CALL wrd_mpi_io_surface( 'surfaces%var_av' // TRIM( dum ), surf_out )
Note: See TracChangeset
for help on using the changeset viewer.