Index: /palm/trunk/SOURCE/module_interface.f90
===================================================================
--- /palm/trunk/SOURCE/module_interface.f90	(revision 3768)
+++ /palm/trunk/SOURCE/module_interface.f90	(revision 3769)
@@ -24,5 +24,7 @@
 ! Former revisions:
 ! -----------------
-! $Id$
+! $ID: MODULE_INTERFACE.F90 3767 2019-02-27 08:18:02Z Mohamed $
+! removed unused variables in module_interface_check_data_output_ts
+! 3767 08:18:02Z raasch
 ! unused variable file_index removed from subroutine parameter list
 ! 
@@ -553,5 +555,5 @@
 
     IF ( radiation )  THEN
-       CALL radiation_check_data_output_ts( dots_max, dots_num, dots_label, dots_unit )
+       CALL radiation_check_data_output_ts( dots_max, dots_num )
     ENDIF
 
Index: /palm/trunk/SOURCE/radiation_model_mod.f90
===================================================================
--- /palm/trunk/SOURCE/radiation_model_mod.f90	(revision 3768)
+++ /palm/trunk/SOURCE/radiation_model_mod.f90	(revision 3769)
@@ -23,9 +23,12 @@
 ! Current revisions:
 ! ------------------
-! 
+!
 ! 
 ! Former revisions:
 ! -----------------
 ! $Id$
+! removed unused variables and subroutine radiation_radflux_gridbox
+!
+! 3767 2019-02-27 08:18:02Z raasch
 ! unused variable for file index removed from rrd-subroutines parameter list
 ! 
@@ -1241,8 +1244,4 @@
     END INTERFACE radiation_presimulate_solar_pos
 
-    INTERFACE radiation_radflux_gridbox
-       MODULE PROCEDURE radiation_radflux_gridbox
-    END INTERFACE radiation_radflux_gridbox
-
     INTERFACE radiation_calc_svf
        MODULE PROCEDURE radiation_calc_svf
@@ -1272,5 +1271,5 @@
            radiation_define_netcdf_grid, radiation_wrd_local,                  &
            radiation_rrd_local, radiation_data_output_mask,                    &
-           radiation_radflux_gridbox, radiation_calc_svf, radiation_write_svf, &
+           radiation_calc_svf, radiation_write_svf,                            &
            radiation_interaction, radiation_interaction_init,                  &
            radiation_read_svf, radiation_presimulate_solar_pos
@@ -1352,5 +1351,5 @@
        CHARACTER (LEN=*) ::  variable      !<
 
-       INTEGER(iwp) :: i, j, k, l
+       INTEGER(iwp) :: i, k
        INTEGER(iwp) :: ilen
        CHARACTER(LEN=varnamelength) :: var          !< TRIM(variable)
@@ -1481,11 +1480,9 @@
 !> Set module-specific timeseries units and labels
 !------------------------------------------------------------------------------!
- SUBROUTINE radiation_check_data_output_ts( dots_max, dots_num, dots_label, dots_unit )
+ SUBROUTINE radiation_check_data_output_ts( dots_max, dots_num )
 
 
    INTEGER(iwp),      INTENT(IN)     ::  dots_max
    INTEGER(iwp),      INTENT(INOUT)  ::  dots_num
-   CHARACTER (LEN=*), DIMENSION(dots_max), INTENT(INOUT)  :: dots_label
-   CHARACTER (LEN=*), DIMENSION(dots_max), INTENT(INOUT)  :: dots_unit
 
 !
@@ -4960,5 +4957,5 @@
      IMPLICIT NONE
 
-     INTEGER(iwp)                      :: i, j, k, kk, is, js, d, ku, refstep, m, mm, l, ll
+     INTEGER(iwp)                      :: i, j, k, kk, d, refstep, m, mm, l, ll
      INTEGER(iwp)                      :: isurf, isurfsrc, isvf, icsf, ipcgb
      INTEGER(iwp)                      :: imrt, imrtf
@@ -8788,119 +8785,4 @@
     END FUNCTION searchsorted
 
-!------------------------------------------------------------------------------!
-! Description:
-! ------------
-!
-!> radiation_radflux_gridbox subroutine gives the sw and lw radiation fluxes at the 
-!> faces of a gridbox defined at i,j,k and located in the urban layer.
-!> The total sw and the diffuse sw radiation as well as the lw radiation fluxes at
-!> the gridbox 6 faces are stored in sw_gridbox, swd_gridbox, and lw_gridbox arrays, 
-!> respectively, in the following order:
-!>  up_face, down_face, north_face, south_face, east_face, west_face
-!> 
-!> The subroutine reports also how successful was the search process via the parameter
-!> i_feedback as follow:
-!> - i_feedback =  1 : successful
-!> - i_feedback = -1 : unsuccessful; the requisted point is outside the urban domain
-!> - i_feedback =  0 : uncomplete; some gridbox faces fluxes are missing
-!> 
-!> 
-!> It is called outside from usm_urban_surface_mod whenever the radiation fluxes
-!> are needed.
-!>
-!> This routine is not used so far. However, it may serve as an interface for radiation
-!> fluxes of urban and land surfaces
-!>
-!> TODO:
-!>    - Compare performance when using some combination of the Fortran intrinsic 
-!>      functions, e.g. MINLOC, MAXLOC, ALL, ANY and COUNT functions, which search
-!>      surfl array for elements meeting user-specified criterion, i.e. i,j,k
-!>    - Report non-found or incomplete radiation fluxes arrays , if any, at the 
-!>      gridbox faces in an error message form
-!>
-!------------------------------------------------------------------------------!
-    SUBROUTINE radiation_radflux_gridbox(i,j,k,sw_gridbox,swd_gridbox,lw_gridbox,i_feedback)
-        
-        IMPLICIT NONE
-
-        INTEGER(iwp),                 INTENT(in)  :: i,j,k                 !< gridbox indices at which fluxes are required
-        INTEGER(iwp)                              :: ii,jj,kk,d            !< surface indices and type
-        INTEGER(iwp)                              :: l                     !< surface id
-        REAL(wp)    , DIMENSION(1:6), INTENT(out) :: sw_gridbox,lw_gridbox !< total sw and lw radiation fluxes of 6 faces of a gridbox, w/m2 
-        REAL(wp)    , DIMENSION(1:6), INTENT(out) :: swd_gridbox           !< diffuse sw radiation from sky and model boundary of 6 faces of a gridbox, w/m2
-        INTEGER(iwp),                 INTENT(out) :: i_feedback            !< feedback to report how the search was successful 
-
-
-!-- initialize variables
-        i_feedback  = -999999
-        sw_gridbox  = -999999.9_wp
-        lw_gridbox  = -999999.9_wp
-        swd_gridbox = -999999.9_wp
-        
-!-- check the requisted grid indices
-        IF ( k < nzb   .OR.  k > nzut  .OR.   &
-             j < nysg  .OR.  j > nyng  .OR.   &
-             i < nxlg  .OR.  i > nxrg         &
-             ) THEN
-           i_feedback = -1
-           RETURN
-        ENDIF
-
-!-- search for the required grid and formulate the fluxes at the 6 gridbox faces
-        DO l = 1, nsurfl
-            ii = surfl(ix,l)
-            jj = surfl(iy,l)
-            kk = surfl(iz,l)
-
-            IF ( ii == i  .AND.  jj == j  .AND.  kk == k ) THEN
-               d = surfl(id,l)
-
-               SELECT CASE ( d )
-
-               CASE (iup_u,iup_l)                          !- gridbox up_facing face
-                  sw_gridbox(1) = surfinsw(l)
-                  lw_gridbox(1) = surfinlw(l)
-                  swd_gridbox(1) = surfinswdif(l)
-
-               CASE (inorth_u,inorth_l)                    !- gridbox north_facing face
-                  sw_gridbox(3) = surfinsw(l)
-                  lw_gridbox(3) = surfinlw(l)
-                  swd_gridbox(3) = surfinswdif(l)
-
-               CASE (isouth_u,isouth_l)                    !- gridbox south_facing face
-                  sw_gridbox(4) = surfinsw(l)
-                  lw_gridbox(4) = surfinlw(l)
-                  swd_gridbox(4) = surfinswdif(l)
-
-               CASE (ieast_u,ieast_l)                      !- gridbox east_facing face
-                  sw_gridbox(5) = surfinsw(l)
-                  lw_gridbox(5) = surfinlw(l)
-                  swd_gridbox(5) = surfinswdif(l)
-
-               CASE (iwest_u,iwest_l)                      !- gridbox west_facing face
-                  sw_gridbox(6) = surfinsw(l)
-                  lw_gridbox(6) = surfinlw(l)
-                  swd_gridbox(6) = surfinswdif(l)
-
-               END SELECT
-
-            ENDIF
-
-        IF ( ALL( sw_gridbox(:)  /= -999999.9_wp )  ) EXIT
-        ENDDO
-
-!-- check the completeness of the fluxes at all gidbox faces        
-!-- TODO: report non-found or incomplete rad fluxes arrays in an error message form
-        IF ( ANY( sw_gridbox(:)  <= -999999.9_wp )  .OR.   &
-             ANY( swd_gridbox(:) <= -999999.9_wp )  .OR.   &
-             ANY( lw_gridbox(:)  <= -999999.9_wp ) ) THEN
-           i_feedback = 0
-        ELSE
-           i_feedback = 1
-        ENDIF
-        
-        RETURN
-        
-    END SUBROUTINE radiation_radflux_gridbox
 
 !------------------------------------------------------------------------------!
Index: /palm/trunk/SOURCE/urban_surface_mod.f90
===================================================================
--- /palm/trunk/SOURCE/urban_surface_mod.f90	(revision 3768)
+++ /palm/trunk/SOURCE/urban_surface_mod.f90	(revision 3769)
@@ -28,4 +28,7 @@
 ! -----------------
 ! $Id$
+! removed unused variables
+!
+! 3767 2019-02-27 08:18:02Z raasch
 ! unused variables removed from rrd-subroutines parameter list
 ! 
@@ -529,5 +532,4 @@
                 field_capacity = 9999999.9_wp,          &  !< NAMELIST fc
                 hydraulic_conductivity = 9999999.9_wp,  &  !< NAMELIST gamma_w_green_sat
-                lambda_h_green_sat = 0.0_wp,            &  !< heat conductivity for saturated soil
                 l_vangenuchten = 9999999.9_wp,          &  !< NAMELIST l_vg
                 n_vangenuchten = 9999999.9_wp,          &  !< NAMELIST n_vg
@@ -2842,12 +2844,12 @@
         REAL(wp), DIMENSION(nzb:nzt+1,nys:nyn,nxl:nxr)     ::  temp_pf    !< temp array for urban surface output procedure
         
-        CHARACTER (len=varnamelength)                          :: var     !< trimmed variable name
-        INTEGER(iwp), PARAMETER                                :: nd = 5  !< number of directions
-        CHARACTER(len=6), DIMENSION(0:nd-1), PARAMETER         :: dirname = (/ '_roof ', '_south', '_north', '_west ', '_east ' /)
-        INTEGER(iwp), DIMENSION(0:nd-1), PARAMETER             :: dirint =  (/    iup_u, isouth_u, inorth_u,  iwest_u,  ieast_u /)
-        INTEGER(iwp), DIMENSION(0:nd-1), PARAMETER             :: diridx =  (/       -1,        1,        0,        3,        2 /)
-                                                                     !< index for surf_*_v: 0:3 = (North, South, East, West)
-        INTEGER(iwp)                                           :: ids,idsint,idsidx,isvf
-        INTEGER(iwp)                                           :: i,j,k,iwl,istat, l, m  !< running indices
+        CHARACTER (len=varnamelength)                      :: var     !< trimmed variable name
+        INTEGER(iwp), PARAMETER                            :: nd = 5  !< number of directions
+        CHARACTER(len=6), DIMENSION(0:nd-1), PARAMETER     :: dirname = (/ '_roof ', '_south', '_north', '_west ', '_east ' /)
+        INTEGER(iwp), DIMENSION(0:nd-1), PARAMETER         :: dirint =  (/    iup_u, isouth_u, inorth_u,  iwest_u,  ieast_u /)
+        INTEGER(iwp), DIMENSION(0:nd-1), PARAMETER         :: diridx =  (/       -1,        1,        0,        3,        2 /)
+                                                                      !< index for surf_*_v: 0:3 = (North, South, East, West)
+        INTEGER(iwp)                   :: ids,idsint,idsidx
+        INTEGER(iwp)                   :: i,j,k,iwl,istat, l, m  !< running indices
 
         found = .TRUE.
@@ -4026,5 +4028,5 @@
         INTEGER(iwp) ::  st                  !< dummy  
 
-        REAL(wp)     ::  c, d, tin, twin
+        REAL(wp)     ::  c, tin, twin
         REAL(wp)     ::  ground_floor_level_l         !< local height of ground floor level
         REAL(wp)     ::  z_agl                        !< height above ground
