Index: palm/trunk/SOURCE/land_surface_model_mod.f90
===================================================================
--- palm/trunk/SOURCE/land_surface_model_mod.f90	(revision 3232)
+++ palm/trunk/SOURCE/land_surface_model_mod.f90	(revision 3233)
@@ -25,4 +25,7 @@
 ! -----------------
 ! $Id$
+! Adapted for the use of cloud_droplets 
+! 
+! 3222 2018-08-30 13:35:35Z suehring
 ! - Introduction of surface array for type and its names
 ! - Bugfix in intialization of pavement surfaces
@@ -2487,5 +2490,5 @@
 !
 !--    If no cloud physics is used, rho_surface has not been calculated before
-       IF (  .NOT.  cloud_physics )  THEN
+       IF (  .NOT.  cloud_physics  .AND.  .NOT.  cloud_droplets )  THEN
           CALL calc_mean_profile( pt, 4 )
           rho_surface = surface_pressure * 100.0_wp / ( r_d * hom(topo_min_level+1,1,4,0) * exn )
Index: palm/trunk/SOURCE/radiation_model_mod.f90
===================================================================
--- palm/trunk/SOURCE/radiation_model_mod.f90	(revision 3232)
+++ palm/trunk/SOURCE/radiation_model_mod.f90	(revision 3233)
@@ -28,4 +28,7 @@
 ! -----------------
 ! $Id$
+! Adapted for the use of cloud_droplets 
+! 
+! 3230 2018-09-05 09:29:05Z schwenkel
 ! Bugfix in radiation_constant_surf: changed (10.0 - emissivity_urb) to 
 ! (1.0 - emissivity_urb)
@@ -1434,4 +1437,12 @@
        ENDIF
 
+       IF ( cloud_droplets  .AND.   radiation_scheme == 'rrtmg'  .AND.         &
+            average_radiation ) THEN
+          message_string = 'average_radiation = .T. with radiation_scheme'//   & 
+                           '= "rrtmg" in combination cloud_droplets = .T.'//   &
+                           'is not implementd'
+          CALL message( 'check_parameters', 'PA0560', 1, 2, 0, 6, 0 )
+       ENDIF
+
 !
 !--    Incialize svf normalization reporting histogram
@@ -2326,21 +2337,21 @@
        IF ( average_radiation ) THEN   
           pt1   = 0.0_wp
-          IF ( cloud_physics )  ql1   = 0.0_wp
+          IF ( cloud_physics  .OR.  cloud_droplets )  ql1   = 0.0_wp
 
           pt1_l = SUM( pt(nzut,nys:nyn,nxl:nxr) )
-          IF ( cloud_physics )  ql1_l = SUM( ql(nzut,nys:nyn,nxl:nxr) )
+          IF ( cloud_physics  .OR.  cloud_droplets  )  ql1_l = SUM( ql(nzut,nys:nyn,nxl:nxr) )
 
 #if defined( __parallel )      
           IF ( collective_wait )  CALL MPI_BARRIER( comm2d, ierr )
           CALL MPI_ALLREDUCE( pt1_l, pt1, 1, MPI_REAL, MPI_SUM, comm2d, ierr )
-          IF ( cloud_physics )                                                 &
+          IF ( cloud_physics  .OR.  cloud_droplets )                            &
              CALL MPI_ALLREDUCE( ql1_l, ql1, 1, MPI_REAL, MPI_SUM, comm2d, ierr )
 #else
           pt1 = pt1_l 
-          IF ( cloud_physics )  ql1 = ql1_l
+          IF ( cloud_physics  .OR.  cloud_droplets )  ql1 = ql1_l
 #endif
  
           exn1 = ( hyp(nzut) / 100000.0_wp )**0.286_wp
-          IF ( cloud_physics )  pt1 = pt1 + l_d_cp / exn1 * ql1
+          IF ( cloud_physics  .OR.  cloud_droplets  )  pt1 = pt1 + l_d_cp / exn1 * ql1
 !
 !--       Finally, divide by number of grid points
@@ -2447,5 +2458,5 @@
 
 
-                   IF ( cloud_physics )  THEN
+                   IF ( cloud_physics  .OR.  cloud_droplets  )  THEN
                       pt1 = pt(k,j,i) + l_d_cp / exn1 * ql(k,j,i)
                       surf%rad_lw_in(m)  = 0.8_wp * sigma_sb * (pt1 * exn1)**4
@@ -2506,19 +2517,19 @@
        IF ( average_radiation ) THEN   
           pt1   = 0.0_wp
-          IF ( cloud_physics )  ql1   = 0.0_wp
+          IF ( cloud_physics  .OR.  cloud_droplets )  ql1   = 0.0_wp
 
           pt1_l = SUM( pt(nzut,nys:nyn,nxl:nxr) )
-          IF ( cloud_physics )  ql1_l = SUM( ql(nzut,nys:nyn,nxl:nxr) )
+          IF ( cloud_physics  .OR.  cloud_droplets )  ql1_l = SUM( ql(nzut,nys:nyn,nxl:nxr) )
 
 #if defined( __parallel )      
           IF ( collective_wait )  CALL MPI_BARRIER( comm2d, ierr )
           CALL MPI_ALLREDUCE( pt1_l, pt1, 1, MPI_REAL, MPI_SUM, comm2d, ierr )
-          IF ( cloud_physics )                                                 &
+          IF ( cloud_physics  .OR.  cloud_droplets )                             &
              CALL MPI_ALLREDUCE( ql1_l, ql1, 1, MPI_REAL, MPI_SUM, comm2d, ierr )
 #else
           pt1 = pt1_l
-          IF ( cloud_physics )  ql1 = ql1_l
+          IF ( cloud_physics  .OR.  cloud_droplets )  ql1 = ql1_l
 #endif
-          IF ( cloud_physics )  pt1 = pt1 + l_d_cp / exn1 * ql1
+          IF ( cloud_physics  .OR.  cloud_droplets )  pt1 = pt1 + l_d_cp / exn1 * ql1
 !
 !--       Finally, divide by number of grid points
@@ -2603,5 +2614,5 @@
                    exn1 = (hyp(k) / 100000.0_wp )**0.286_wp
 
-                   IF ( cloud_physics )  THEN
+                   IF ( cloud_physics  .OR.  cloud_droplets )  THEN
                       pt1 = pt(k,j,i) + l_d_cp / exn1 * ql(k,j,i)
                       surf%rad_lw_in(m)  = 0.8_wp * sigma_sb * (pt1 * exn1)**4
@@ -2973,5 +2984,5 @@
           IF ( cloud_physics )  THEN
              DO k = nzb+1, nzt+1
-                rrtm_cliqwp(0,k) =  ql_av(k) * 1000._wp *                  &
+                rrtm_cliqwp(0,k) =  ql_av(k) * 1000._wp *                   &
                                     (rrtm_plev(0,k) - rrtm_plev(0,k+1))     &
                                     * 100._wp / g 
@@ -2983,13 +2994,9 @@
 !
 !--                Calculate cloud droplet effective radius
-                   IF ( cloud_physics )  THEN
-                      rrtm_reliq(0,k) = 1.0E6_wp * ( 3._wp * ql_av(k)      &
-                                        * rho_surface                       &
-                                        / ( 4._wp * pi * nc_const * rho_l )&
-                                        )**.33333333333333_wp              &
-                                        * EXP( LOG( sigma_gc )**2 )
-
-                   ENDIF
-
+                   rrtm_reliq(0,k) = 1.0E6_wp * ( 3.0_wp * ql_av(k)         &
+                                     * rho_surface                          &
+                                     / ( 4.0_wp * pi * nc_const * rho_l )   &
+                                     )**0.33333333333333_wp                 &
+                                     * EXP( LOG( sigma_gc )**2 )
 !
 !--                Limit effective radius
@@ -3157,4 +3164,10 @@
                                        )**0.286_wp + l_d_cp * ql(k,j,i)
                       rrtm_h2ovmr(0,k) = mol_mass_air_d_wv * (q(k,j,i) - ql(k,j,i))
+                   ENDDO
+                ELSEIF ( cloud_droplets )  THEN
+                   DO k = nzb+1, nzt+1
+                      rrtm_tlay(0,k) = pt(k,j,i) * ( (hyp(k) ) / 100000.0_wp   &
+                                       )**0.286_wp + l_d_cp * ql(k,j,i)
+                      rrtm_h2ovmr(0,k) = mol_mass_air_d_wv * q(k,j,i) 
                    ENDDO
                 ELSE
