Index: trunk/LMDZ.MARS/libf/dyn3d/newstart.F
===================================================================
--- trunk/LMDZ.MARS/libf/dyn3d/newstart.F	(revision 575)
+++ trunk/LMDZ.MARS/libf/dyn3d/newstart.F	(revision 618)
@@ -139,5 +139,6 @@
       real choix_1
       character*80      fichnom
-      integer Lmodif,iq,thermo
+      integer Lmodif,iq
+      integer flagthermo, flagh2o
       character modif*20
       real z_reel(iip1,jjp1)
@@ -450,17 +451,12 @@
       enddo ! of do iq=1,nqmx
       
+      ! initialize tracer names noms(:) and indexes (igcm_co2, igcm_h2o_vap, ...)
+      call initracer(qsurf,co2ice)
+      
       if (count.eq.nqmx) then
         write(*,*) 'Newstart: updating tracer names'
-        ! do things the easy but dirty way:
-        ! 1. call inichim_readcallphys (so that callphys.def is read)
-        call inichim_readcallphys()
-        ! 2. call initracer to set all new tracer names (in noms(:)) 
-        call initracer(qsurf,co2ice)
-        ! 3. copy noms(:) to tnom(:)
+        ! copy noms(:) to tnom(:) to have matching tracer names in physics
+        ! and dynamics
         tnom(1:nqmx)=noms(1:nqmx)
-        write(*,*) 'Newstart: updated tracer names'
-      else
-       ! initialize tracer names and indexes (igcm_co2, igcm_h2o_vap, ...)
-        call initracer(qsurf,co2ice)
       endif
 
@@ -474,36 +470,37 @@
       write(*,*)
       write(*,*) 'List of possible changes :'
-      write(*,*) '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~'
+      write(*,*) '~~~~~~~~~~~~~~~~~~~~~~~~~~'
       write(*,*)
-      write(*,*) 'flat : no topography ("aquaplanet")'
-      write(*,*) 'bilball : uniform albedo and thermal inertia'
-      write(*,*) 'z0 : set a uniform surface roughness length'
-      write(*,*) 'coldspole : cold subsurface and high albedo at S.pole'
-      write(*,*) 'qname : change tracer name'
-      write(*,*) 'q=0 : ALL tracer =zero'
-      write(*,*) 'q=x : give a specific uniform value to one tracer'
-      write(*,*) 'q=profile : specify a profile for a tracer'
-      write(*,*) 'ini_q : tracers initialisation for chemistry, water an
-     $d ice   '
-      write(*,*) 'ini_q-H2O : tracers initialisation for chemistry and 
-     $ice '
-      write(*,*) 'ini_q-iceH2O : tracers initialisation for chemistry on
-     $ly ' 
-      write(*,*) 'ini_h2osurf : reinitialize surface water ice '
-      write(*,*) 'noglacier : Remove tropical H2O ice if |lat|<45'
-      write(*,*) 'watercapn : H20 ice on permanent N polar cap '
-      write(*,*) 'watercaps : H20 ice on permanent S polar cap '
-      write(*,*) 'wetstart  : start with a wet atmosphere'
-      write(*,*) 'isotherm : Isothermal Temperatures, wind set to zero'
-      write(*,*) 'co2ice=0 : remove CO2 polar cap'
-      write(*,*) 'ptot : change total pressure'
-      write(*,*) 'therm_ini_s: Set soil thermal inertia to reference sur
-     &face values'
-      write(*,*) 'subsoilice_n: Put deep underground ice layer in northe
-     &rn hemisphere'
-      write(*,*) 'subsoilice_s: Put deep underground ice layer in southe
-     &rn hemisphere'
-      write(*,*) 'mons_ice: Put underground ice layer according to MONS-
-     &derived data'
+      write(*,*) 'flat         : no topography ("aquaplanet")'
+      write(*,*) 'bilball      : uniform albedo and thermal inertia'
+      write(*,*) 'z0           : set a uniform surface roughness length'
+      write(*,*) 'coldspole    : cold subsurface and high albedo at
+     $ S.Pole'
+      write(*,*) 'qname        : change tracer name'
+      write(*,*) 'q=0          : ALL tracer =zero'
+      write(*,*) 'q=x          : give a specific uniform value to one
+     $ tracer'
+      write(*,*) 'q=profile    : specify a profile for a tracer'
+      write(*,*) 'ini_q        : tracers initialization for chemistry
+     $ and water vapour'
+      write(*,*) 'ini_q-h2o    : tracers initialization for chemistry
+     $ only'
+      write(*,*) 'ini_h2osurf  : reinitialize surface water ice '
+      write(*,*) 'noglacier    : Remove tropical H2O ice if |lat|<45'
+      write(*,*) 'watercapn    : H20 ice on permanent N polar cap '
+      write(*,*) 'watercaps    : H20 ice on permanent S polar cap '
+      write(*,*) 'wetstart     : start with a wet atmosphere'
+      write(*,*) 'isotherm     : Isothermal Temperatures, wind set to
+     $ zero'
+      write(*,*) 'co2ice=0     : remove CO2 polar cap'
+      write(*,*) 'ptot         : change total pressure'
+      write(*,*) 'therm_ini_s  : set soil thermal inertia to reference
+     $ surface values'
+      write(*,*) 'subsoilice_n : put deep underground ice layer in
+     $ northern hemisphere'
+      write(*,*) 'subsoilice_s : put deep underground ice layer in
+     $ southern hemisphere'
+      write(*,*) 'mons_ice     : put underground ice layer according
+     $ to MONS derived data'
 
         write(*,*)
@@ -834,7 +831,8 @@
 c       -----------------------------------------------
         else if (trim(modif) .eq. 'ini_q') then
+          flagh2o    = 1
+          flagthermo = 0
+          yes=' '
 c         For more than 32 layers, possible to initiate thermosphere only     
-          thermo=0
-          yes=' '
           if (llm.gt.32) then 
             do while ((yes.ne.'y').and.(yes.ne.'n'))
@@ -843,30 +841,23 @@
             read(*,fmt='(a)') yes
             if (yes.eq.'y') then
-            thermo=1 
+            flagthermo=1 
             else
-            thermo=0
+            flagthermo=0
             endif
             enddo  
           endif
           
-              call inichim_newstart(q,ps,sig,nqmx,latfi,lonfi,airefi,
-     $   thermo,qsurf)
-          write(*,*) 'Chemical species initialized'
-
-        if (thermo.eq.0) then 
-c          mise a 0 des qsurf (traceurs a la surface)
-           DO iq =1, nqmx
-             DO ig=1,ngridmx
-                 qsurf(ig,iq)=0.
-             ENDDO
-           ENDDO
-        endif   
-
-c       ini_q-H2O : as above exept for the water vapour tracer 
+          call inichim_newstart(q, qsurf, ps, flagh2o, flagthermo)
+          write(*,*) 'inichim_newstart: chemical species and
+     $ water vapour initialised'
+
+
+c       ini_q-h2o : as above exept for the water vapour tracer 
 c       ------------------------------------------------------
-        else if (trim(modif) .eq. 'ini_q-H2O') then
+        else if (trim(modif) .eq. 'ini_q-h2o') then
+          flagh2o    = 0
+          flagthermo = 0
+          yes=' '
           ! for more than 32 layers, possible to initiate thermosphere only     
-          thermo=0
-          yes=' '
           if(llm.gt.32) then
             do while ((yes.ne.'y').and.(yes.ne.'n'))
@@ -875,58 +866,14 @@
             read(*,fmt='(a)') yes
             if (yes.eq.'y') then 
-            thermo=1 
+            flagthermo=1 
             else
-            thermo=0
+            flagthermo=0
             endif
             enddo
           endif
-              call inichim_newstart(q,ps,sig,nqmx-1,latfi,lonfi,airefi,
-     $   thermo,qsurf)
-          write(*,*) 'Initialized chem. species exept last (H2O)'
-
-        if (thermo.eq.0) then 
-c          set surface tracers to zero, except water ice
-           DO iq =1, nqmx
-            if (iq.ne.igcm_h2o_ice) then
-             DO ig=1,ngridmx
-                 qsurf(ig,iq)=0.
-             ENDDO
-            endif
-           ENDDO
-        endif
-
-c       ini_q-iceH2O : as above exept for ice et H2O
-c       -----------------------------------------------
-        else if (trim(modif) .eq. 'ini_q-iceH2O') then
-c         For more than 32 layers, possible to initiate thermosphere only     
-          thermo=0
-          yes=' '
-          if(llm.gt.32) then
-            do while ((yes.ne.'y').and.(yes.ne.'n'))
-            write(*,*)'',
-     &      'initialisation for thermosphere only? (y/n)'
-            read(*,fmt='(a)') yes
-            if (yes.eq.'y') then 
-            thermo=1 
-            else
-            thermo=0
-            endif
-            enddo
-          endif
-     
-         call inichim_newstart(q,ps,sig,nqmx-2,latfi,lonfi,airefi,
-     $   thermo,qsurf)
-          write(*,*) 'Initialized chem. species exept ice and H2O'
-
-        if (thermo.eq.0) then 
-c          set surface tracers to zero, except water ice
-           DO iq =1, nqmx
-            if (iq.ne.igcm_h2o_ice) then
-             DO ig=1,ngridmx
-                 qsurf(ig,iq)=0.
-             ENDDO 
-            endif
-           ENDDO
-        endif
+          call inichim_newstart(q, qsurf, ps, flagh2o, flagthermo)
+          write(*,*) 'inichim_newstart: chemical species initialised
+     $ (except water vapour)'
+
 
 c      wetstart : wet atmosphere with a north to south gradient
