- Timestamp:
- Apr 25, 2019 12:33:20 PM (6 years ago)
- Location:
- palm/trunk/SOURCE
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
palm/trunk/SOURCE/average_3d_data.f90
r3773 r3933 25 25 ! ----------------- 26 26 ! $Id$ 27 ! Bugfix in CASE theta_2m*, removal of redundant code 28 ! 29 ! 3773 2019-03-01 08:56:57Z maronga 27 30 ! Added output of theta_2m*_xy_av 28 31 ! … … 440 443 441 444 CASE ( 'theta_2m*' ) 442 IF ( ALLOCATED( tsurf_av ) ) THEN445 IF ( ALLOCATED( pt_2m_av ) ) THEN 443 446 DO i = nxlg, nxrg 444 447 DO j = nysg, nyng … … 448 451 CALL exchange_horiz_2d( pt_2m_av, nbgp ) 449 452 ENDIF 450 453 451 454 CASE ( 't*' ) 452 455 IF ( ALLOCATED( ts_av ) ) THEN … … 512 515 ENDIF 513 516 514 CASE ( 'theta_2m' )515 IF ( ALLOCATED( pt_2m_av ) ) THEN516 DO i = nxlg, nxrg517 DO j = nysg, nyng518 pt_2m_av(j,i) = pt_2m_av(j,i) / REAL( average_count_3d, KIND=wp )519 ENDDO520 ENDDO521 CALL exchange_horiz_2d( pt_2m_av, nbgp )522 ENDIF523 524 517 CASE ( 'w' ) 525 518 IF ( ALLOCATED( w_av ) ) THEN -
palm/trunk/SOURCE/check_parameters.f90
r3885 r3933 25 25 ! ----------------- 26 26 ! $Id$ 27 ! Alphabetical resorting in CASE, condense settings for theta_2m* into one IF clause 28 ! 29 ! 3885 2019-04-11 11:29:34Z kanani 27 30 ! Changes related to global restructuring of location messages and introduction 28 31 ! of additional debug messages … … 3077 3080 CONTINUE 3078 3081 3079 CASE ( 'ghf*', 'lwp*', 'ol*', 'qsws*', 'r_a*', 'theta_2m*', & 3080 'shf*', 'ssws*', 't*', 'tsurf*', 'us*', 'z0*', 'z0h*', 'z0q*' ) 3082 CASE ( 'ghf*', 'lwp*', 'ol*', 'qsws*', 'r_a*', & 3083 'shf*', 'ssws*', 't*', 'theta_2m*', 'tsurf*', 'us*', & 3084 'z0*', 'z0h*', 'z0q*' ) 3081 3085 IF ( k == 0 .OR. data_output(i)(ilen-2:ilen) /= '_xy' ) THEN 3082 3086 message_string = 'illegal value for data_output: "' // & … … 3117 3121 CALL message( 'check_parameters', 'PA0361', 1, 2, 0, 6, 0 ) 3118 3122 ENDIF 3119 3120 3121 3123 ! 3122 3124 !-- Activate calculation of 2m temperature if output is requested 3123 3125 IF ( TRIM( var ) == 'theta_2m*' ) THEN 3124 3126 do_output_at_2m = .TRUE. 3125 ENDIF3126 3127 unit = 'K' 3128 ENDIF 3127 3129 3128 3130 IF ( TRIM( var ) == 'ghf*' ) unit = 'W/m2' 3129 3131 IF ( TRIM( var ) == 'lwp*' ) unit = 'kg/m2' 3130 3132 IF ( TRIM( var ) == 'ol*' ) unit = 'm' 3131 IF ( TRIM( var ) == 'theta_2m*' ) unit = 'K'3132 3133 IF ( TRIM( var ) == 'qsws*' ) unit = 'kgm/kgs' 3133 IF ( TRIM( var ) == 'r_a*' ) unit = 's/m' 3134 IF ( TRIM( var ) == 'r_a*' ) unit = 's/m' 3134 3135 IF ( TRIM( var ) == 'shf*' ) unit = 'K*m/s' 3135 3136 IF ( TRIM( var ) == 'ssws*' ) unit = 'kg/m2*s' 3136 3137 IF ( TRIM( var ) == 't*' ) unit = 'K' 3137 IF ( TRIM( var ) == 'tsurf*' ) unit = 'K' 3138 IF ( TRIM( var ) == 'tsurf*' ) unit = 'K' 3138 3139 IF ( TRIM( var ) == 'us*' ) unit = 'm/s' 3139 3140 IF ( TRIM( var ) == 'z0*' ) unit = 'm' -
palm/trunk/SOURCE/land_surface_model_mod.f90
r3885 r3933 25 25 ! ----------------- 26 26 ! $Id$ 27 ! Remove unused subroutine and allocation of pt_2m, this is done in surface_mod 28 ! now (surfaces%pt_2m) 29 ! 30 ! 27 31 ! Changes related to global restructuring of location messages and introduction 28 32 ! of additional debug messages … … 1017 1021 !-- Public functions 1018 1022 PUBLIC lsm_boundary_condition, lsm_check_data_output, & 1019 lsm_check_data_output_pr, lsm_calc_pt_near_surface,&1023 lsm_check_data_output_pr, & 1020 1024 lsm_check_parameters, lsm_define_netcdf_grid, lsm_3d_data_averaging,& 1021 1025 lsm_data_output_2d, lsm_data_output_3d, lsm_energy_balance, & … … 1038 1042 END INTERFACE lsm_boundary_condition 1039 1043 1040 INTERFACE lsm_calc_pt_near_surface1041 MODULE PROCEDURE lsm_calc_pt_near_surface1042 END INTERFACE lsm_calc_pt_near_surface1043 1044 1044 INTERFACE lsm_check_data_output 1045 1045 MODULE PROCEDURE lsm_check_data_output … … 5057 5057 ALLOCATE ( surf_lsm_h%r_s(1:surf_lsm_h%ns) ) 5058 5058 ALLOCATE ( surf_lsm_h%r_canopy_min(1:surf_lsm_h%ns) ) 5059 ALLOCATE ( surf_lsm_h%pt_2m(1:surf_lsm_h%ns) )5060 5059 ALLOCATE ( surf_lsm_h%vegetation_surface(1:surf_lsm_h%ns) ) 5061 5060 ALLOCATE ( surf_lsm_h%water_surface(1:surf_lsm_h%ns) ) … … 7322 7321 END SUBROUTINE calc_z0_water_surface 7323 7322 7324 7325 !------------------------------------------------------------------------------!7326 ! Description:7327 ! ------------7328 !> Calculates 2m temperature for data output at coarse resolution7329 !------------------------------------------------------------------------------!7330 SUBROUTINE lsm_calc_pt_near_surface7331 7332 IMPLICIT NONE7333 7334 INTEGER(iwp) :: i, j, k, m !< running indices7335 7336 7337 DO m = 1, surf_lsm_h%ns7338 7339 i = surf_lsm_h%i(m)7340 j = surf_lsm_h%j(m)7341 k = surf_lsm_h%k(m)7342 7343 surf_lsm_h%pt_2m(m) = surf_lsm_h%pt_surface(m) + surf_lsm_h%ts(m) / kappa &7344 * ( log( 2.0_wp / surf_lsm_h%z0h(m) ) &7345 - psi_h( 2.0_wp / surf_lsm_h%ol(m) ) &7346 + psi_h( surf_lsm_h%z0h(m) / surf_lsm_h%ol(m) ) )7347 7348 ENDDO7349 7350 END SUBROUTINE lsm_calc_pt_near_surface7351 7352 7353 7354 7323 ! 7355 7324 !-- Integrated stability function for heat and moisture -
palm/trunk/SOURCE/sum_up_3d_data.f90
r3773 r3933 25 25 ! ----------------- 26 26 ! $Id$ 27 ! Formatting 28 ! 29 ! 3773 2019-03-01 08:56:57Z maronga 27 30 ! Added output of theta_2m*_xy_av 28 31 ! … … 940 943 ELSEIF ( match_lsm .AND. .NOT. match_usm ) THEN 941 944 m = surf_lsm_h%end_index(j,i) 942 pt_2m_av(j,i) = pt_2m_av(j,i) + &945 pt_2m_av(j,i) = pt_2m_av(j,i) + & 943 946 surf_lsm_h%pt_2m(m) 944 947 ELSEIF ( match_usm ) THEN -
palm/trunk/SOURCE/surface_mod.f90
r3833 r3933 26 26 ! ----------------- 27 27 ! $Id$ 28 ! Add (de)allocation of pt_2m, 29 ! bugfix: initialize pt_2m 30 ! 31 ! 3833 2019-03-28 15:04:04Z forkel 28 32 ! added USE chem_gasphase_mod (chem_modules will not transport nvar and nspec anymore) 29 33 ! … … 1321 1325 !-- Salinity surface flux 1322 1326 IF ( ocean_mode ) DEALLOCATE ( surfaces%sasws ) 1327 ! 1328 !-- 2-m potential temperature (for output quantity theta_2m*) 1329 IF ( do_output_at_2m ) DEALLOCATE ( surfaces%pt_2m ) 1323 1330 1324 1331 END SUBROUTINE deallocate_surface_attributes_h … … 1449 1456 !-- Salinity surface flux 1450 1457 IF ( ocean_mode ) ALLOCATE ( surfaces%sasws(1:surfaces%ns) ) 1458 ! 1459 !-- 2-m potential temperature (for output quantity theta_2m*) 1460 IF ( do_output_at_2m ) THEN 1461 ALLOCATE ( surfaces%pt_2m(1:surfaces%ns) ) 1462 surfaces%pt_2m = -9999.0_wp !< output array (for theta_2m*) must be initialized here, 1463 !< otherwise simulation crash at do2d_at_begin with spinup=.F. 1464 ENDIF 1451 1465 1452 1466 END SUBROUTINE allocate_surface_attributes_h -
palm/trunk/SOURCE/urban_surface_mod.f90
r3921 r3933 28 28 ! ----------------- 29 29 ! $Id$ 30 ! Remove allocation of pt_2m, this is done in surface_mod now (surfaces%pt_2m) 31 ! 32 ! 3921 2019-04-18 14:21:10Z suehring 30 33 ! Undo accidentally commented initialization 31 34 ! … … 1160 1163 ALLOCATE ( surf_usm_h%qsws_eb(1:surf_usm_h%ns) ) 1161 1164 ALLOCATE ( surf_usm_h%pt_10cm(1:surf_usm_h%ns) ) 1162 ALLOCATE ( surf_usm_h%pt_2m(1:surf_usm_h%ns) )1163 1165 1164 1166 !
Note: See TracChangeset
for help on using the changeset viewer.