Index: palm/trunk/SOURCE/init_3d_model.f90
===================================================================
--- palm/trunk/SOURCE/init_3d_model.f90	(revision 4186)
+++ palm/trunk/SOURCE/init_3d_model.f90	(revision 4187)
@@ -25,4 +25,8 @@
 ! -----------------
 ! $Id$
+! Deallocate temporary string array since it may be re-used to read different 
+! input data in other modules
+! 
+! 4186 2019-08-23 16:06:14Z suehring
 ! Design change, use variables defined in netcdf_data_input_mod to read netcd
 ! variables rather than define local ones.
@@ -1594,5 +1598,7 @@
                            
 !
-!--    Finally, close the input file.
+!--    Finally, close the input file and deallocate temporary arrays
+       DEALLOCATE( vars_pids )
+       
        CALL close_input_file( pids_id )
 #endif
Index: palm/trunk/SOURCE/land_surface_model_mod.f90
===================================================================
--- palm/trunk/SOURCE/land_surface_model_mod.f90	(revision 4186)
+++ palm/trunk/SOURCE/land_surface_model_mod.f90	(revision 4187)
@@ -25,4 +25,7 @@
 ! -----------------
 ! $Id$
+! Adjust message call in case of local checks
+! 
+! 4182 2019-08-22 15:20:23Z scharf
 ! Corrected "Former revisions" section
 ! 
@@ -1289,5 +1292,5 @@
           message_string = 'pavement-surfaces are not allowed in ' //           &
                            'combination with a non-default setting of dz_soil'
-          CALL message( 'lsm_check_parameters', 'PA0999', 2, 2, 0, 6, 0 )
+          CALL message( 'lsm_check_parameters', 'PA0316', 2, 2, 0, 6, 0 )
        ENDIF
     ENDIF
@@ -3169,5 +3172,5 @@
                                  'so that information given in ',              &
                                  'vegetation_pars at this point is neglected.' 
-                CALL message( 'land_surface_model_mod', 'PA0999', 0, 0, 0, 6, 0 )
+                CALL message( 'land_surface_model_mod', 'PA0436', 0, 0, myid, 6, 0 )
              ELSE
 
@@ -3245,5 +3248,5 @@
                                  'so that information given in ',              &
                                  'vegetation_pars at this point is neglected.' 
-                   CALL message( 'land_surface_model_mod', 'PA0999', 0, 0, 0, 6, 0 )
+                   CALL message( 'land_surface_model_mod', 'PA0437', 0, 0, myid, 6, 0 )
                 ELSE
 
@@ -3461,5 +3464,5 @@
                               'so that information given in ',                 &
                               'water_pars at this point is neglected.' 
-                CALL message( 'land_surface_model_mod', 'PA0999', 0, 0, 0, 6, 0 )
+                CALL message( 'land_surface_model_mod', 'PA0645', 0, 0, myid, 6, 0 )
              ELSE
                 IF ( water_pars_f%pars_xy(ind_w_temp,j,i) /=                   &
@@ -3517,6 +3520,6 @@
                               'so that information given in ',                 &
                               'water_pars at this point is neglected.' 
-                   CALL message( 'land_surface_model_mod', 'PA0999',           &
-                                  0, 0, 0, 6, 0 )
+                   CALL message( 'land_surface_model_mod', 'PA0646',           &
+                                  0, 0, myid, 6, 0 )
                 ELSE
 
@@ -3824,5 +3827,5 @@
                               'so that information given in ',                 &
                               'pavement_pars at this point is neglected.' 
-                CALL message( 'land_surface_model_mod', 'PA0999', 0, 0, 0, 6, 0 )
+                CALL message( 'land_surface_model_mod', 'PA0647', 0, 0, myid, 6, 0 )
              ELSE
                 IF ( pavement_pars_f%pars_xy(ind_p_z0,j,i) /=                  &
@@ -3883,5 +3886,5 @@
                                  'so that information given in ',              &
                                  'pavement_pars at this point is neglected.' 
-                   CALL message( 'land_surface_model_mod', 'PA0999', 0, 0, 0, 6, 0 )
+                   CALL message( 'land_surface_model_mod', 'PA0670', 0, 0, myid, 6, 0 )
                 ELSE
 
@@ -4303,5 +4306,5 @@
                             'than its saturation value at (k,j,i) ', k,        &
                             surf_lsm_h%i(m), surf_lsm_h%j(m)
-                      CALL message( 'lsm_init', 'PA0458', 2, 2, 0, 6, 0 )
+                      CALL message( 'lsm_init', 'PA0458', 2, 2, myid, 6, 0 )
                    ENDIF               
                 ENDDO
@@ -4319,5 +4322,5 @@
                             'its saturation value at (k,j,i) ', k,             &
                             surf_lsm_v(l)%i(m), surf_lsm_v(l)%j(m)
-                         CALL message( 'lsm_init', 'PA0458', 2, 2, 0, 6, 0 )                   
+                         CALL message( 'lsm_init', 'PA0458', 2, 2, myid, 6, 0 )                   
                       ENDIF
                    ENDDO
@@ -4581,5 +4584,5 @@
           message_string = 'For non-pavement surfaces the combination ' //     &
                            ' lai = 0.0 and c_veg = 1.0 is not allowed.'
-          CALL message( 'lsm_rrd_local', 'PA0999', 2, 2, 0, 6, 0 )
+          CALL message( 'lsm_rrd_local', 'PA0671', 2, 2, 0, 6, 0 )
        ENDIF
 
@@ -4590,5 +4593,5 @@
              message_string = 'For non-pavement surfaces the combination ' //  &
                               ' lai = 0.0 and c_veg = 1.0 is not allowed.'
-             CALL message( 'lsm_rrd_local', 'PA0999', 2, 2, 0, 6, 0 )
+             CALL message( 'lsm_rrd_local', 'PA0672', 2, 2, 0, 6, 0 )
           ENDIF
        ENDDO
@@ -4607,5 +4610,5 @@
                             surf_lsm_h%i(m), surf_lsm_h%j(m)
              CALL message( 'land_surface_model_mod', 'PA0503',                 &
-                            0, 0, 0, 6, 0 )
+                            0, 0, myid, 6, 0 )
           ENDIF
           IF ( surf_lsm_h%z0h(m) > 0.5_wp * surf_lsm_h%z_mo(m) )  THEN
@@ -4619,5 +4622,5 @@
                             surf_lsm_h%i(m), surf_lsm_h%j(m)
              CALL message( 'land_surface_model_mod', 'PA0507',                 &
-                            0, 0, 0, 6, 0 )
+                            0, 0, myid, 6, 0 )
           ENDIF
        ENDDO
@@ -4635,5 +4638,5 @@
                             surf_lsm_v(l)%j(m)+surf_lsm_v(l)%joff
                 CALL message( 'land_surface_model_mod', 'PA0503',              &
-                            0, 0, 0, 6, 0 )
+                            0, 0, myid, 6, 0 )
              ENDIF
              IF ( surf_lsm_v(l)%z0h(m) > 0.5_wp * surf_lsm_v(l)%z_mo(m) )  THEN
@@ -4648,5 +4651,5 @@
                             surf_lsm_v(l)%j(m)+surf_lsm_v(l)%joff
                 CALL message( 'land_surface_model_mod', 'PA0507',              &
-                            0, 0, 0, 6, 0 )
+                            0, 0, myid, 6, 0 )
              ENDIF
           ENDDO
@@ -6982,5 +6985,5 @@
                             surf_lsm_h%i(m), surf_lsm_h%j(m)
                 CALL message( 'land_surface_model_mod', 'PA0508',              &
-                              0, 0, 0, 6, 0 )
+                              0, 0, myid, 6, 0 )
              ENDIF
   
@@ -6994,5 +6997,5 @@
                             surf_lsm_h%i(m), surf_lsm_h%j(m)
                 CALL message( 'land_surface_model_mod', 'PA0508',              &
-                              0, 0, 0, 6, 0 )
+                              0, 0, myid, 6, 0 )
              ENDIF
              
@@ -7006,5 +7009,5 @@
                             surf_lsm_h%i(m), surf_lsm_h%j(m)
                 CALL message( 'land_surface_model_mod', 'PA0508',              &
-                              0, 0, 0, 6, 0 )
+                              0, 0, myid, 6, 0 )
              ENDIF
   
Index: palm/trunk/SOURCE/plant_canopy_model_mod.f90
===================================================================
--- palm/trunk/SOURCE/plant_canopy_model_mod.f90	(revision 4186)
+++ palm/trunk/SOURCE/plant_canopy_model_mod.f90	(revision 4187)
@@ -27,4 +27,7 @@
 ! -----------------
 ! $Id$
+! Give specific error numbers instead of PA0999
+! 
+! 4182 2019-08-22 15:20:23Z scharf
 ! Corrected "Former revisions" section
 ! 
@@ -430,5 +433,5 @@
                            TRIM( coupling_char ) // ' requires ' //            &
                            'canopy_mode = read_from_file_3d'
-          CALL message( 'pcm_check_parameters', 'PA0999', 1, 2, 0, 6, 0 )
+          CALL message( 'pcm_check_parameters', 'PA0673', 1, 2, 0, 6, 0 )
        ENDIF
 
@@ -1066,4 +1069,5 @@
                    ENDDO
                 ENDDO
+                
                 CALL exchange_horiz( lad_s, nbgp )
 !
@@ -1091,5 +1095,5 @@
        ALLOCATE( pch_index_ji(nysg:nyng,nxlg:nxrg) )
        pch_index_ji = 0
-
+       
        DO  i = nxl, nxr
           DO  j = nys, nyn
@@ -1104,5 +1108,5 @@
                 message_string =  'Local vegetation height on top of ' //      &
                                   'topography exceeds height of model domain.'
-                CALL message( 'pcm_init', 'PA0999', 2, 2, 0, 6, 0 )
+                CALL message( 'pcm_init', 'PA0674', 2, 2, 0, 6, 0 )
              ENDIF
 
@@ -1114,4 +1118,6 @@
 !--    Calculate global pch_index value (index of top of plant canopy from ground)
        pch_index = MAXVAL( pch_index_ji )
+       
+       
 !
 !--    Exchange pch_index from all processors
@@ -1129,5 +1135,4 @@
           pc_latent_rate = 0.0_wp
        ENDIF
-
 !
 !--    Initialization of the canopy heat source distribution due to heating
Index: palm/trunk/SOURCE/radiation_model_mod.f90
===================================================================
--- palm/trunk/SOURCE/radiation_model_mod.f90	(revision 4186)
+++ palm/trunk/SOURCE/radiation_model_mod.f90	(revision 4187)
@@ -28,4 +28,9 @@
 ! -----------------
 ! $Id$
+! - Take external radiation from root domain dynamic input if not provided for 
+!   each nested domain
+! - Combine MPI_ALLREDUCE calls to reduce mpi overhead
+! 
+! 4182 2019-08-22 15:20:23Z scharf
 ! Corrected "Former revisions" section
 ! 
@@ -234,4 +239,5 @@
                inquire_variable_names,                                         &
                input_file_dynamic,                                             &
+               input_pids_dynamic,                                             &
                netcdf_data_input_get_dimension_length,                         &
                num_var_pids,                                                   &
@@ -1453,4 +1459,5 @@
        INTEGER(iwp) ::  ind_type  !< running index for subgrid-surface tiles
 #endif
+       LOGICAL      ::  radiation_input_root_domain !< flag indicating the existence of a dynamic input file for the root domain
 
 
@@ -2451,9 +2458,34 @@
        IF ( radiation_scheme == 'external' )  THEN
 !
-!--       Open the radiation input file
+!--       Open the radiation input file. Note, for child domain, a dynamic 
+!--       input file is often not provided. In order to do not need to 
+!--       duplicate the dynamic input file just for the radiation input, take
+!--       it from the dynamic file for the parent if not available for the 
+!--       child domain(s). In this case this is possible because radiation 
+!--       input should be the same for each model.
+          INQUIRE( FILE = TRIM( input_file_dynamic ),                          &
+                   EXIST = radiation_input_root_domain  )
+                   
+          IF ( .NOT. input_pids_dynamic  .AND.                                 &
+               .NOT. radiation_input_root_domain )  THEN
+             message_string = 'In case of external radiation forcing ' //      &
+                              'a dynamic input file is required. If no ' //    &
+                              'dynamic input for the child domain(s) is ' //   &
+                              'provided, at least one for the root domain ' // &
+                              'needs to be provided.'
+             CALL message( 'radiation_init', 'PA0315', 1, 2, 0, 6, 0 )
+          ENDIF
 #if defined( __netcdf )
-          CALL open_read_file( TRIM( input_file_dynamic ) //                   &
-                               TRIM( coupling_char ),                          &
-                               pids_id )
+!
+!--       Open dynamic input file for child domain if available, else, open
+!--       dynamic input file for the root domain. 
+          IF ( input_pids_dynamic )  THEN
+             CALL open_read_file( TRIM( input_file_dynamic ) //                &
+                                  TRIM( coupling_char ),                       &
+                                  pids_id )
+          ELSEIF ( radiation_input_root_domain )  THEN
+             CALL open_read_file( TRIM( input_file_dynamic ),                  &
+                                  pids_id )
+          ENDIF
                                
           CALL inquire_num_variables( pids_id, num_var_pids )
@@ -2462,5 +2494,4 @@
           ALLOCATE( vars_pids(1:num_var_pids) )
           CALL inquire_variable_names( pids_id, vars_pids )
-          
 !         
 !--       Input time dimension.
@@ -2519,5 +2550,7 @@
           ENDIF
 !         
-!--       Finally, close the input file.
+!--       Finally, close the input file and deallocate temporary arrays
+          DEALLOCATE( vars_pids )
+          
           CALL close_input_file( pids_id )
 #endif
@@ -5113,38 +5146,41 @@
      IMPLICIT NONE
 
-     INTEGER(iwp)                      :: i, j, k, kk, d, refstep, m, mm, l, ll
-     INTEGER(iwp)                      :: isurf, isurfsrc, isvf, icsf, ipcgb
-     INTEGER(iwp)                      :: imrt, imrtf
-     INTEGER(iwp)                      :: isd                !< solar direction number
-     INTEGER(iwp)                      :: pc_box_dimshift    !< transform for best accuracy
-     INTEGER(iwp), DIMENSION(0:3)      :: reorder = (/ 1, 0, 3, 2 /)
-     
-     REAL(wp), DIMENSION(3,3)          :: mrot               !< grid rotation matrix (zyx)
-     REAL(wp), DIMENSION(3,0:nsurf_type):: vnorm             !< face direction normal vectors (zyx)
-     REAL(wp), DIMENSION(3)            :: sunorig            !< grid rotated solar direction unit vector (zyx)
-     REAL(wp), DIMENSION(3)            :: sunorig_grid       !< grid squashed solar direction unit vector (zyx)
-     REAL(wp), DIMENSION(0:nsurf_type) :: costheta           !< direct irradiance factor of solar angle
-     REAL(wp), DIMENSION(nz_urban_b:nz_urban_t)    :: pchf_prep          !< precalculated factor for canopy temperature tendency
+     INTEGER(iwp)                      ::  i, j, k, kk, d, refstep, m, mm, l, ll
+     INTEGER(iwp)                      ::  isurf, isurfsrc, isvf, icsf, ipcgb
+     INTEGER(iwp)                      ::  imrt, imrtf
+     INTEGER(iwp)                      ::  isd                !< solar direction number
+     INTEGER(iwp)                      ::  pc_box_dimshift    !< transform for best accuracy
+     INTEGER(iwp), DIMENSION(0:3)      ::  reorder = (/ 1, 0, 3, 2 /)
+                                           
+     REAL(wp), DIMENSION(3,3)          ::  mrot               !< grid rotation matrix (zyx)
+     REAL(wp), DIMENSION(3,0:nsurf_type)::  vnorm             !< face direction normal vectors (zyx)
+     REAL(wp), DIMENSION(3)            ::  sunorig            !< grid rotated solar direction unit vector (zyx)
+     REAL(wp), DIMENSION(3)            ::  sunorig_grid       !< grid squashed solar direction unit vector (zyx)
+     REAL(wp), DIMENSION(0:nsurf_type) ::  costheta           !< direct irradiance factor of solar angle
+     REAL(wp), DIMENSION(nz_urban_b:nz_urban_t) ::  pchf_prep          !< precalculated factor for canopy temperature tendency
      REAL(wp), PARAMETER               :: alpha = 0._wp      !< grid rotation (TODO: synchronize with rotation_angle
                                                              !< from netcdf_data_input_mod)
-     REAL(wp)                          :: pc_box_area, pc_abs_frac, pc_abs_eff
-     REAL(wp)                          :: asrc               !< area of source face
-     REAL(wp)                          :: pcrad              !< irradiance from plant canopy
-     REAL(wp)                          :: pabsswl  = 0.0_wp  !< total absorbed SW radiation energy in local processor (W)
-     REAL(wp)                          :: pabssw   = 0.0_wp  !< total absorbed SW radiation energy in all processors (W)
-     REAL(wp)                          :: pabslwl  = 0.0_wp  !< total absorbed LW radiation energy in local processor (W)
-     REAL(wp)                          :: pabslw   = 0.0_wp  !< total absorbed LW radiation energy in all processors (W)
-     REAL(wp)                          :: pemitlwl = 0.0_wp  !< total emitted LW radiation energy in all processors (W)
-     REAL(wp)                          :: pemitlw  = 0.0_wp  !< total emitted LW radiation energy in all processors (W)
-     REAL(wp)                          :: pinswl   = 0.0_wp  !< total received SW radiation energy in local processor (W)
-     REAL(wp)                          :: pinsw    = 0.0_wp  !< total received SW radiation energy in all processor (W)
-     REAL(wp)                          :: pinlwl   = 0.0_wp  !< total received LW radiation energy in local processor (W)
-     REAL(wp)                          :: pinlw    = 0.0_wp  !< total received LW radiation energy in all processor (W)
-     REAL(wp)                          :: emiss_sum_surfl    !< sum of emissisivity of surfaces in local processor
-     REAL(wp)                          :: emiss_sum_surf     !< sum of emissisivity of surfaces in all processor
-     REAL(wp)                          :: area_surfl         !< total area of surfaces in local processor
-     REAL(wp)                          :: area_surf          !< total area of surfaces in all processor
-     REAL(wp)                          :: area_hor           !< total horizontal area of domain in all processor
-
+     REAL(wp)                          ::  pc_box_area, pc_abs_frac, pc_abs_eff
+     REAL(wp)                          ::  asrc               !< area of source face
+     REAL(wp)                          ::  pcrad              !< irradiance from plant canopy
+     REAL(wp)                          ::  pabsswl  = 0.0_wp  !< total absorbed SW radiation energy in local processor (W)
+     REAL(wp)                          ::  pabssw   = 0.0_wp  !< total absorbed SW radiation energy in all processors (W)
+     REAL(wp)                          ::  pabslwl  = 0.0_wp  !< total absorbed LW radiation energy in local processor (W)
+     REAL(wp)                          ::  pabslw   = 0.0_wp  !< total absorbed LW radiation energy in all processors (W)
+     REAL(wp)                          ::  pemitlwl = 0.0_wp  !< total emitted LW radiation energy in all processors (W)
+     REAL(wp)                          ::  pemitlw  = 0.0_wp  !< total emitted LW radiation energy in all processors (W)
+     REAL(wp)                          ::  pinswl   = 0.0_wp  !< total received SW radiation energy in local processor (W)
+     REAL(wp)                          ::  pinsw    = 0.0_wp  !< total received SW radiation energy in all processor (W)
+     REAL(wp)                          ::  pinlwl   = 0.0_wp  !< total received LW radiation energy in local processor (W)
+     REAL(wp)                          ::  pinlw    = 0.0_wp  !< total received LW radiation energy in all processor (W)
+     REAL(wp)                          ::  emiss_sum_surfl    !< sum of emissisivity of surfaces in local processor
+     REAL(wp)                          ::  emiss_sum_surf     !< sum of emissisivity of surfaces in all processor
+     REAL(wp)                          ::  area_surfl         !< total area of surfaces in local processor
+     REAL(wp)                          ::  area_surf          !< total area of surfaces in all processor
+     REAL(wp)                          ::  area_hor           !< total horizontal area of domain in all processor
+#if defined( __parallel )     
+     REAL(wp), DIMENSION(1:7)          ::  combine_allreduce   !< dummy array used to combine several MPI_ALLREDUCE calls
+     REAL(wp), DIMENSION(1:7)          ::  combine_allreduce_l !< dummy array used to combine several MPI_ALLREDUCE calls
+#endif
 
      IF ( debug_output_timestep )  CALL debug_message( 'radiation_interaction', 'start' )
@@ -5829,60 +5865,49 @@
         pabsswl = pabsswl + SUM(pcbinsw)
         pabslwl = pabslwl + SUM(pcbinlw)
-        pinswl = pinswl + SUM(pcbinswdir) + SUM(pcbinswdif)
+        pinswl  = pinswl + SUM(pcbinswdir) + SUM(pcbinswdif)
      ENDIF
 !
-!--  gather all rad flux energy in all processors
+!--  gather all rad flux energy in all processors. In order to reduce
+!--  the number of MPI calls (to reduce latencies), combine the required
+!--  quantities in one array, sum it up, and subsequently re-distribute
+!--  back to the respective quantities.
 #if defined( __parallel )
-     CALL MPI_ALLREDUCE( pinswl, pinsw, 1, MPI_REAL, MPI_SUM, comm2d, ierr)
-     IF ( ierr /= 0 ) THEN
-         WRITE(9,*) 'Error MPI_AllReduce5:', ierr, pinswl, pinsw
-         FLUSH(9)
-     ENDIF
-     CALL MPI_ALLREDUCE( pinlwl, pinlw, 1, MPI_REAL, MPI_SUM, comm2d, ierr)
-     IF ( ierr /= 0 ) THEN
-         WRITE(9,*) 'Error MPI_AllReduce6:', ierr, pinlwl, pinlw
-         FLUSH(9)
-     ENDIF
-     CALL MPI_ALLREDUCE( pabsswl, pabssw, 1, MPI_REAL, MPI_SUM, comm2d, ierr )
-     IF ( ierr /= 0 ) THEN
-         WRITE(9,*) 'Error MPI_AllReduce7:', ierr, pabsswl, pabssw
-         FLUSH(9)
-     ENDIF
-     CALL MPI_ALLREDUCE( pabslwl, pabslw, 1, MPI_REAL, MPI_SUM, comm2d, ierr )
-     IF ( ierr /= 0 ) THEN
-         WRITE(9,*) 'Error MPI_AllReduce8:', ierr, pabslwl, pabslw
-         FLUSH(9)
-     ENDIF
-     CALL MPI_ALLREDUCE( pemitlwl, pemitlw, 1, MPI_REAL, MPI_SUM, comm2d, ierr )
-     IF ( ierr /= 0 ) THEN
-         WRITE(9,*) 'Error MPI_AllReduce8:', ierr, pemitlwl, pemitlw
-         FLUSH(9)
-     ENDIF
-     CALL MPI_ALLREDUCE( emiss_sum_surfl, emiss_sum_surf, 1, MPI_REAL, MPI_SUM, comm2d, ierr )
-     IF ( ierr /= 0 ) THEN
-         WRITE(9,*) 'Error MPI_AllReduce9:', ierr, emiss_sum_surfl, emiss_sum_surf
-         FLUSH(9)
-     ENDIF
-     CALL MPI_ALLREDUCE( area_surfl, area_surf, 1, MPI_REAL, MPI_SUM, comm2d, ierr )
-     IF ( ierr /= 0 ) THEN
-         WRITE(9,*) 'Error MPI_AllReduce10:', ierr, area_surfl, area_surf
-         FLUSH(9)
-     ENDIF
+     combine_allreduce_l(1) = pinswl
+     combine_allreduce_l(2) = pinlwl
+     combine_allreduce_l(3) = pabsswl
+     combine_allreduce_l(4) = pabslwl
+     combine_allreduce_l(5) = pemitlwl
+     combine_allreduce_l(6) = emiss_sum_surfl
+     combine_allreduce_l(7) = area_surfl
+     
+     CALL MPI_ALLREDUCE( combine_allreduce_l,                                  &
+                         combine_allreduce,                                    &
+                         SIZE( combine_allreduce ),                            &
+                         MPI_REAL,                                             &
+                         MPI_SUM,                                              &
+                         comm2d,                                               &
+                         ierr )
+     
+     pinsw          = combine_allreduce(1)
+     pinlw          = combine_allreduce(2)
+     pabssw         = combine_allreduce(3)
+     pabslw         = combine_allreduce(4)
+     pemitlw        = combine_allreduce(5)
+     emiss_sum_surf = combine_allreduce(6)
+     area_surf      = combine_allreduce(7)
 #else
-     pinsw = pinswl
-     pinlw = pinlwl
-     pabssw = pabsswl
-     pabslw = pabslwl
-     pemitlw = pemitlwl
+     pinsw          = pinswl
+     pinlw          = pinlwl
+     pabssw         = pabsswl
+     pabslw         = pabslwl
+     pemitlw        = pemitlwl
      emiss_sum_surf = emiss_sum_surfl
-     area_surf = area_surfl
+     area_surf      = area_surfl
 #endif
 
 !--  (1) albedo
-     IF ( pinsw /= 0.0_wp )  &
-          albedo_urb = (pinsw - pabssw) / pinsw
+     IF ( pinsw /= 0.0_wp )  albedo_urb = ( pinsw - pabssw ) / pinsw
 !--  (2) average emmsivity
-     IF ( area_surf /= 0.0_wp ) &
-          emissivity_urb = emiss_sum_surf / area_surf
+     IF ( area_surf /= 0.0_wp )  emissivity_urb = emiss_sum_surf / area_surf
 !
 !--  Temporally comment out calculation of effective radiative temperature. 
@@ -5892,7 +5917,7 @@
 !--   the effect of vertical surfaces (which contributes to LW emission)
 !--   We simply use the ratio of the total LW to the incoming LW flux 
-      area_hor = pinlw/rad_lw_in_diff(nyn,nxl)
-      t_rad_urb = ( (pemitlw - pabslw + emissivity_urb*pinlw) / &
-           (emissivity_urb*sigma_sb * area_hor) )**0.25_wp
+      area_hor = pinlw / rad_lw_in_diff(nyn,nxl)
+      t_rad_urb = ( ( pemitlw - pabslw + emissivity_urb * pinlw ) / &
+           (emissivity_urb * sigma_sb * area_hor) )**0.25_wp
 
      IF ( debug_output_timestep )  CALL debug_message( 'radiation_interaction', 'end' )
