Index: palm/trunk/SOURCE/chemistry_model_mod.f90
===================================================================
--- palm/trunk/SOURCE/chemistry_model_mod.f90	(revision 3782)
+++ palm/trunk/SOURCE/chemistry_model_mod.f90	(revision 3783)
@@ -27,4 +27,9 @@
 ! -----------------
 ! $Id$
+! Removed forgotte write statements an some unused variables (did not touch the 
+! parts related to deposition)
+! 
+! 
+! 3780 2019-03-05 11:19:45Z forkel
 ! Removed READ from unit 10, added CALL get_mechanismname
 ! 
@@ -731,5 +736,5 @@
                bc_radiation_s                
     USE indices,                                                               &  
-        ONLY:  nxl, nxr,  nxlg, nxrg, nyng, nysg, nzt                              
+        ONLY:  nxl, nxr, nzt                              
 
     USE arrays_3d,                                                             &     
@@ -747,5 +752,4 @@
     INTEGER(iwp) ::  m                            !< running index surface elements.
     INTEGER(iwp) ::  lsp                          !< running index for chem spcs.
-    INTEGER(iwp) ::  lph                          !< running index for photolysis frequencies
 
 
@@ -869,7 +873,4 @@
  SUBROUTINE chem_boundary_conds_decycle( cs_3d, cs_pr_init )
 
-    USE pegrid,                                                             &
-        ONLY:  myid
-
     IMPLICIT NONE 
     INTEGER(iwp) ::  boundary  !< 
@@ -1027,7 +1028,4 @@
  SUBROUTINE chem_check_data_output( var, unit, i, ilen, k )
 
-
-    USE control_parameters,                                                 &
-        ONLY:  data_output, message_string
 
     IMPLICIT NONE
@@ -1186,6 +1184,4 @@
 !-- check for chemical mechanism used 
     CALL get_mechanismname
-    WRITE(06,*) 'cs_mech ',cs_mech
-    WRITE(06,*) 'chem_mechanism ', chem_mechanism
     IF (chem_mechanism /= trim(cs_mech) )  THEN
        message_string = 'Incorrect chemistry mechanism selected, check spelling in namelist and/or chem_gasphase_mod'
@@ -1257,7 +1253,4 @@
     USE kinds
 
-    USE pegrid,                                                               &
-        ONLY:  myid, threads_per_task
-
     IMPLICIT NONE
 
@@ -1280,5 +1273,4 @@
     INTEGER(iwp) ::  j               !< grid index along y-direction
     INTEGER(iwp) ::  k               !< grid index along z-direction
-    INTEGER(iwp) ::  m               !< running index surface elements
     INTEGER(iwp) ::  char_len        !< length of a character string
     found = .FALSE.
@@ -1460,6 +1452,4 @@
     USE indices
     USE kinds
-    USE pegrid,                                                                       &
-        ONLY:  myid, threads_per_task
     USE surface_mod,                                                                  &
         ONLY:  get_topography_top_index_ji
@@ -1793,8 +1783,4 @@
  SUBROUTINE chem_init_internal
 
-    USE control_parameters,                                                    &
-        ONLY:  message_string, io_blocks, io_group, turbulent_inflow
-    USE arrays_3d,                                                             &
-        ONLY:  mean_inflow_profiles
     USE pegrid
 
@@ -2063,7 +2049,4 @@
     INTEGER(iwp) ::  lsp                                                     !< running index for chem spcs.
     INTEGER(iwp) ::  lph                                                     !< running index for photolysis frequencies
-    INTEGER      ::  k
-    INTEGER      ::  m
-    INTEGER      ::  istatf
     INTEGER, DIMENSION(20)    :: istatus
     REAL(kind=wp), DIMENSION(nzb+1:nzt,nspec)                :: tmp_conc
@@ -2083,5 +2066,4 @@
 !    REAL(wp), PARAMETER              ::  xm_air  = 28.96_wp                  !< Mole mass of dry air
 !    REAL(wp), PARAMETER              ::  xm_h2o  = 18.01528_wp               !< Mole mass of water vapor
-    REAL(wp), PARAMETER              ::  pref_i  = 1._wp / 100000.0_wp       !< inverse reference pressure (1/Pa)
     REAL(wp), PARAMETER              ::  t_std   = 273.15_wp                 !< standard pressure (Pa)
     REAL(wp), PARAMETER              ::  p_std   = 101325.0_wp               !< standard pressure (Pa)
@@ -2182,9 +2164,7 @@
 
     CHARACTER (LEN=80) ::  line                        !< dummy string that contains the current line of the parameter file
-    CHARACTER (LEN=3)  ::  cs_prefix 
 
     REAL(wp), DIMENSION(nmaxfixsteps) ::   my_steps    !< List of fixed timesteps   my_step(1) = 0.0 automatic stepping
     INTEGER(iwp) ::  i                                 !< 
-    INTEGER(iwp) ::  j                                 !< 
     INTEGER(iwp) ::  max_pr_cs_tmp                     !< 
 
@@ -2242,6 +2222,4 @@
     !--   Read chem namelist   
 
-    INTEGER             :: ier
-    CHARACTER(LEN=64)   :: text
     CHARACTER(LEN=8)    :: solver_type
 
@@ -2677,6 +2655,4 @@
     INTEGER(iwp) ::  sr   !< statistical region
     INTEGER(iwp) ::  tn   !< thread number 
-    INTEGER(iwp) ::  n    !<
-    INTEGER(iwp) ::  m    !<
     INTEGER(iwp) ::  lpr  !< running index chem spcs
 
