Index: trunk/LMDZ.GENERIC/libf/phystd/comsaison_h.F90
===================================================================
--- trunk/LMDZ.GENERIC/libf/phystd/comsaison_h.F90	(revision 1882)
+++ trunk/LMDZ.GENERIC/libf/phystd/comsaison_h.F90	(revision 1883)
@@ -4,10 +4,13 @@
        implicit none 
 
-       integer isaison
-       logical callsais
-       real dist_star,declin,right_ascen
+!       integer,save :: isaison
+!       logical,save :: callsais
+!!$OMP THREADPRIVATE(isaison,callsais)
+
+       real,save :: dist_star,declin,right_ascen
+!$OMP THREADPRIVATE(dist_star,declin,right_ascen)
 
        real, allocatable, dimension(:) :: mu0,fract
-!$OMP THREADPRIVATE(isaison,callsais,dist_star,declin,mu0,fract)
+!$OMP THREADPRIVATE(mu0,fract)
 
        end module comsaison_h
Index: trunk/LMDZ.GENERIC/libf/phystd/dyn1d/rcm1d.F
===================================================================
--- trunk/LMDZ.GENERIC/libf/phystd/dyn1d/rcm1d.F	(revision 1882)
+++ trunk/LMDZ.GENERIC/libf/phystd/dyn1d/rcm1d.F	(revision 1883)
@@ -35,4 +35,5 @@
       use mod_interface_dyn_phys, only: init_interface_dyn_phys
       use inifis_mod, only: inifis
+      use phys_state_var_mod, only: phys_state_var_init
       use physiq_mod, only: physiq
       implicit none
@@ -146,25 +147,20 @@
 c INITIALISATION
 c=======================================================================
-! initialize "serial/parallel" related stuff
-!      CALL init_phys_lmdz(iim,jjm+1,llm,1,(/(jjm-1)*iim+2/))
-!      CALL init_phys_lmdz(1,1,llm,1,(/1/))
-!      call initcomgeomphy
-
-      !! those are defined in surfdat_h.F90
-      IF (.not. ALLOCATED(albedodat)) ALLOCATE(albedodat(1))
-      IF (.not. ALLOCATED(phisfi)) ALLOCATE(phisfi(1))
-      IF (.not. ALLOCATED(zmea)) ALLOCATE(zmea(1))
-      IF (.not. ALLOCATED(zstd)) ALLOCATE(zstd(1))
-      IF (.not. ALLOCATED(zsig)) ALLOCATE(zsig(1))
-      IF (.not. ALLOCATED(zgam)) ALLOCATE(zgam(1))
-      IF (.not. ALLOCATED(zthe)) ALLOCATE(zthe(1))
-      IF (.not. ALLOCATED(dryness)) ALLOCATE(dryness(1))
-      IF (.not. ALLOCATED(watercaptag)) ALLOCATE(watercaptag(1))
-      !! those are defined in comdiurn_h.F90
-      IF (.not.ALLOCATED(sinlat)) ALLOCATE(sinlat(1))
-      IF (.not.ALLOCATED(coslat)) ALLOCATE(coslat(1))
-      IF (.not.ALLOCATED(sinlon)) ALLOCATE(sinlon(1))
-      IF (.not.ALLOCATED(coslon)) ALLOCATE(coslon(1))
-
+
+      ! read nq from traceur.def
+      open(90,file='traceur.def',status='old',form='formatted',
+     &       iostat=ierr)
+      if (ierr.eq.0) then
+        read(90,*,iostat=ierr) nq
+      else
+        nq=0
+      endif
+      close(90)
+      
+      ! Initialize dimphy module
+      call init_dimphy(1,llm) 
+      ! now initialize arrays using phys_state_var_init
+      call phys_state_var_init(nq)
+      
       saveprofile=.false.
       saveprofile=.true.
@@ -512,5 +508,5 @@
 !      call init_vertical_layers(nlayer,preff,scaleheight,
 !     &                      ap,bp,aps,bps,presnivs,pseudoalt)
-      call init_dimphy(1,nlayer) ! Initialize dimphy module
+!      call init_dimphy(1,nlayer) ! Initialize dimphy module
       call ini_planete_mod(nlayer,preff,ap,bp)
 
Index: trunk/LMDZ.GENERIC/libf/phystd/phys_state_var_mod.F90
===================================================================
--- trunk/LMDZ.GENERIC/libf/phystd/phys_state_var_mod.F90	(revision 1882)
+++ trunk/LMDZ.GENERIC/libf/phystd/phys_state_var_mod.F90	(revision 1883)
@@ -17,14 +17,11 @@
       use surfdat_h, only: phisfi, albedodat,  &
                         zmea, zstd, zsig, zgam, zthe
-      use turb_mod
-!#include "bands.h"
-!#include "scatterers.h"
-!      INTEGER, SAVE :: radpas
-!!$OMP THREADPRIVATE(radpas)
-!      REAL, SAVE :: dtime
-!!$OMP THREADPRIVATE(dtime)
+      use turb_mod, only: q2,sensibFlux,wstar,ustar,tstar,hfmax_th,zmax_th
+
       real,allocatable,dimension(:,:),save :: ztprevious ! Previous loop Atmospheric Temperature (K)
 ! Useful for Dynamical Heating calculation.
       real,allocatable,dimension(:,:),save :: zuprevious
+!$OMP THREADPRIVATE(ztprevious,zuprevious)
+
       real, dimension(:),allocatable,save ::  tsurf                ! Surface temperature (K).
       real, dimension(:,:),allocatable,save ::  tsoil              ! Sub-surface temperatures (K).
@@ -33,10 +30,8 @@
       real, dimension(:),allocatable,save :: albedo_snow_SPECTV    ! Snow Spectral albedo.
       real, dimension(:),allocatable,save :: albedo_co2_ice_SPECTV ! CO2 ice Spectral albedo.
-
 !$OMP THREADPRIVATE(tsurf,tsoil,albedo,albedo_equivalent,albedo_snow_SPECTV,albedo_co2_ice_SPECTV)
 
       real,dimension(:),allocatable,save :: albedo_bareground ! Bare Ground Albedo. By MT 2015.
       real,dimension(:),allocatable,save :: rnat              ! Defines the type of the grid (ocean,continent,...). By BC.
-
 !$OMP THREADPRIVATE(albedo_bareground,rnat)
 
@@ -48,6 +43,5 @@
       real,dimension(:),allocatable,save :: fluxgrd     ! Surface conduction flux (W.m-2).
       real,dimension(:,:),allocatable,save :: qsurf     ! Tracer on surface (e.g. kg.m-2).
-      !real,dimension(:,:),allocatable,save :: q2        ! Turbulent Kinetic Energy.
-
+!$OMP THREADPRIVATE(emis,dtrad,fluxrad_sky,fluxrad,capcal,fluxgrd,qsurf)
 
       ! FOR DIAGNOSTIC :
@@ -56,8 +50,12 @@
       real,dimension(:),allocatable,save :: fluxsurf_sw     ! Incident Short Wave (stellar) surface flux (W.m-2).
       real,dimension(:),allocatable,save :: fluxsurfabs_sw  ! Absorbed Short Wave (stellar) flux by the surface (W.m-2).
+!$OMP THREADPRIVATE(fluxsurf_lw,fluxsurf_sw,fluxsurfabs_sw)
+
       real,dimension(:),allocatable,save :: fluxtop_lw      ! Outgoing LW (IR) flux to space (W.m-2).
       real,dimension(:),allocatable,save :: fluxabs_sw      ! Absorbed SW (stellar) flux (W.m-2).
       real,dimension(:),allocatable,save :: fluxtop_dn      ! Incoming SW (stellar) radiation at the top of the atmosphere (W.m-2).
       real,dimension(:),allocatable,save :: fluxdyn         ! Horizontal heat transport by dynamics (W.m-2).
+!$OMP THREADPRIVATE(fluxtop_lw,fluxabs_sw,fluxtop_dn,fluxdyn)
+
       real,dimension(:,:),allocatable,save :: OLR_nu        ! Outgoing LW radiation in each band (Normalized to the band width (W/m2/cm-1)).
       real,dimension(:,:),allocatable,save :: OSR_nu        ! Outgoing SW radiation in each band (Normalized to the band width (W/m2/cm-1)).
@@ -65,4 +63,5 @@
       real,dimension(:,:),allocatable,save :: zdtsw         ! SW heating tendencies (K/s).
       !real,dimension(:),allocatable,save :: sensibFlux      ! Turbulent flux given by the atmosphere to the surface (W.m-2).
+!$OMP THREADPRIVATE(OLR_nu,OSR_nu,zdtlw,zdtsw)
 
       real,allocatable,dimension(:),save :: tau_col ! Total Aerosol Optical Depth.
@@ -75,10 +74,10 @@
 
       real,allocatable,dimension(:,:),save :: qsurf_hist
-!$OMP THREADPRIVATE(qsurf_hist)
       real,allocatable,dimension(:,:,:),save :: nueffrad ! Aerosol effective radius variance. By RW
+!$OMP THREADPRIVATE(qsurf_hist,nueffrad)
 
       real,allocatable,dimension(:),save :: ice_initial
       real,allocatable,dimension(:),save :: ice_min
-
+!$OMP THREADPRIVATE(ice_initial,ice_min)
 
       real, dimension(:),allocatable,save ::  pctsrf_sic
@@ -89,6 +88,5 @@
       integer, dimension(:),allocatable,save ::knindex
       real,allocatable,dimension(:,:,:),save :: reffrad
-
-!$OMP THREADPRIVATE(dlw,fder)
+!$OMP THREADPRIVATE(pctsrf_sic,tslab,tsea_ice,sea_ice,zmasq,knindex,reffrad)
       
 CONTAINS
@@ -99,5 +97,5 @@
 IMPLICIT NONE
 
-        integer :: nqtot
+        integer,intent(in) :: nqtot
 
 !  Parametres de l'Orographie a l'Echelle Sous-Maille (OESM):
Index: trunk/LMDZ.GENERIC/libf/phystd/physiq_mod.F90
===================================================================
--- trunk/LMDZ.GENERIC/libf/phystd/physiq_mod.F90	(revision 1882)
+++ trunk/LMDZ.GENERIC/libf/phystd/physiq_mod.F90	(revision 1883)
@@ -404,6 +404,7 @@
 ! --------------------------------
       if (firstcall) then
-        ! Allocate saved arrays.
-        call phys_state_var_init(nq)
+        ! Allocate saved arrays (except for 1D model, where this has already
+        ! been done)
+        if (ngrid>1) call phys_state_var_init(nq)
 
 !        Variables set to 0
Index: trunk/LMDZ.GENERIC/libf/phystd/turb_mod.F90
===================================================================
--- trunk/LMDZ.GENERIC/libf/phystd/turb_mod.F90	(revision 1882)
+++ trunk/LMDZ.GENERIC/libf/phystd/turb_mod.F90	(revision 1883)
@@ -4,11 +4,15 @@
   REAL,SAVE,ALLOCATABLE :: q2(:,:)    ! Turbulent Kinetic Energy
   REAL,allocatable,SAVE :: l0(:)
+!$OMP THREADPRIVATE(q2,l0)
   REAL,SAVE,ALLOCATABLE :: ustar(:)
   REAL,SAVE,ALLOCATABLE :: wstar(:)
   REAL,SAVE,ALLOCATABLE :: tstar(:)
+!$OMP THREADPRIVATE(ustar,wstar,tstar)
   REAL,SAVE,ALLOCATABLE :: hfmax_th(:)
   REAL,SAVE,ALLOCATABLE :: zmax_th(:)
+!$OMP THREADPRIVATE(hfmax_th,zmax_th)
   REAL,SAVE,ALLOCATABLE :: sensibFlux(:)
-  LOGICAL :: turb_resolved = .false.
+  LOGICAL,SAVE :: turb_resolved = .false.
+!$OMP THREADPRIVATE(sensibFlux,turb_resolved)
       ! this is a flag to say 'turbulence is resolved'
       ! mostly for LES use. default is FALSE (for GCM and mesoscale)
