Index: /trunk/LMDZ.GENERIC/libf/phystd/dyn1d/rcm1d.F
===================================================================
--- /trunk/LMDZ.GENERIC/libf/phystd/dyn1d/rcm1d.F	(revision 2712)
+++ /trunk/LMDZ.GENERIC/libf/phystd/dyn1d/rcm1d.F	(revision 2713)
@@ -117,4 +117,5 @@
       character (len=7) :: str7
       character(len=44) :: txt
+      character(len=44) :: tracer_profile_file_name
 
       logical oldcompare, earthhack,saveprofile
@@ -681,10 +682,13 @@
             endif ! of if (txt.eq."h2o_ice")
 
-            !Fe_vap 
-            if (txt .eq. "Fe_vap") then 
+            !_vap
+            if((txt .ne. 'h2o_vap') .and.
+     &                     (index(txt,'_vap'   ) .ne. 0))   then
                   q(:,iq)=0. !kg/kg of atmosphere
                   qsurf(iq) = 0. !kg/kg of atmosphere
-                  ! Look for a "profile_Fe_vap" input file
-                  open(91,file='profile_Fe_vap',status='old',
+                  ! Look for a "profile_Fe_vap" input file*
+                  tracer_profile_file_name=""
+                  tracer_profile_file_name='profile_'//txt
+                  open(91,file=tracer_profile_file_name,status='old',
      &            form="formatted",iostat=ierr)
                   if (ierr .eq. 0) then 
@@ -694,147 +698,13 @@
                         enddo 
                   else 
-                        write(*,*),"No profile_Fe_vap file !"
+                        write(*,*) "No initial profile "
+                        write(*,*) " for this tracer :"
+                        write(*,*) txt
                   endif
                   close(91)
-            endif ! (txt .eq. "Fe_vap") 
-            !Fe_ice 
-            if (txt .eq. "Fe_ice") then 
-                  q(:,iq)=0. !kg/kg of atmosphere
-                  qsurf(iq) = 0. !kg/kg of atmosphere
-            endif ! we only initialize the solid at 0
-
-            ! Cr_vap 
-            if (txt .eq. "Cr_vap") then 
-                  q(:,iq)=0. !kg/kg of atmosphere
-                  qsurf(iq) = 0. !kg/kg of atmosphere
-                  ! Look for a "profile_Cr_vap" input file
-                  open(91,file='profile_Cr_vap',status='old',
-     &            form="formatted",iostat=ierr)
-                  if (ierr .eq. 0) then 
-                        read(91,*),qsurf(iq)
-                        do ilayer=1,nlayer 
-                              read(91,*)q(ilayer,iq)
-                        enddo 
-                  else 
-                        write(*,*),"No profile_Cr_vap file !"
-                  endif
-                  close(91)
-            endif ! (txt .eq. "Cr_vap") 
-            !Cr_ice 
-            if (txt .eq. "Cr_ice") then 
-                  q(:,iq)=0. !kg/kg of atmosphere
-                  qsurf(iq) = 0. !kg/kg of atmosphere
-            endif ! we only initialize the solid at 0
-
-            ! Mg_vap 
-            if (txt .eq. "Mg_vap") then 
-                  q(:,iq)=0. !kg/kg of atmosphere
-                  qsurf(iq) = 0. !kg/kg of atmosphere
-                  ! Look for a "profile_Mg_vap" input file
-                  open(91,file='profile_Mg_vap',status='old',
-     &            form="formatted",iostat=ierr)
-                  if (ierr .eq. 0) then 
-                        read(91,*),qsurf(iq)
-                        do ilayer=1,nlayer 
-                              read(91,*)q(ilayer,iq)
-                        enddo 
-                  else 
-                        write(*,*),"No profile_Mg_vap file !"
-                  endif
-                  close(91)
-            endif ! (txt .eq. "Mg_vap") 
-            !Mg_ice 
-            if (txt .eq. "Mg_ice") then 
-                  q(:,iq)=0. !kg/kg of atmosphere
-                  qsurf(iq) = 0. !kg/kg of atmosphere
-            endif ! we only initialize the solid at 0
-
-            ! Na_vap 
-            if (txt .eq. "Na_vap") then 
-                  q(:,iq)=0. !kg/kg of atmosphere
-                  qsurf(iq) = 0. !kg/kg of atmosphere
-                  ! Look for a "profile_Na_vap" input file
-                  open(91,file='profile_Na_vap',status='old',
-     &            form="formatted",iostat=ierr)
-                  if (ierr .eq. 0) then 
-                        read(91,*),qsurf(iq)
-                        do ilayer=1,nlayer 
-                              read(91,*)q(ilayer,iq)
-                        enddo 
-                  else 
-                        write(*,*),"No profile_Na_vap file !"
-                  endif
-                  close(91)
-            endif ! (txt .eq. Na_vap") 
-            !Cr_ice 
-            if (txt .eq. "Na_ice") then 
-                  q(:,iq)=0. !kg/kg of atmosphere
-                  qsurf(iq) = 0. !kg/kg of atmosphere
-            endif ! we only initialize the solid at 0
-            ! KCl_vap 
-            if (txt .eq. "KCl_vap") then 
-                  q(:,iq)=0. !kg/kg of atmosphere
-                  qsurf(iq) = 0. !kg/kg of atmosphere
-                  ! Look for a "profile_KCL_vap" input file
-                  open(91,file='profile_KCl_vap',status='old',
-     &            form="formatted",iostat=ierr)
-                  if (ierr .eq. 0) then 
-                        read(91,*),qsurf(iq)
-                        do ilayer=1,nlayer 
-                              read(91,*)q(ilayer,iq)
-                        enddo 
-                  else 
-                        write(*,*),"No profile_KCl_vap file !"
-                  endif
-                  close(91)
-            endif ! (txt .eq. "KCl_vap") 
-            !KCl_ice 
-            if (txt .eq. "KCl_ice") then 
-                  q(:,iq)=0. !kg/kg of atmosphere
-                  qsurf(iq) = 0. !kg/kg of atmosphere
-            endif ! we only initialize the solid at 0
-
-            ! Mn_vap 
-            if (txt .eq. "Mn_vap") then 
-                  q(:,iq)=0. !kg/kg of atmosphere
-                  qsurf(iq) = 0. !kg/kg of atmosphere
-                  ! Look for a "profile_Mn_vap" input file
-                  open(91,file='profile_Mn_vap',status='old',
-     &            form="formatted",iostat=ierr)
-                  if (ierr .eq. 0) then 
-                        read(91,*),qsurf(iq)
-                        do ilayer=1,nlayer 
-                              read(91,*)q(ilayer,iq)
-                        enddo 
-                  else 
-                        write(*,*),"No profile_Mn_vap file !"
-                  endif
-                  close(91)
-            endif ! (txt .eq. "Mn_vap") 
-            !Mn_ice 
-            if (txt .eq. "Mn_ice") then 
-                  q(:,iq)=0. !kg/kg of atmosphere
-                  qsurf(iq) = 0. !kg/kg of atmosphere
-            endif ! we only initialize the solid at 0
-
-            ! Zn_vap 
-            if (txt .eq. "Zn_vap") then 
-                  q(:,iq)=0. !kg/kg of atmosphere
-                  qsurf(iq) = 0. !kg/kg of atmosphere
-                  ! Look for a "profile_Zn_vap" input file
-                  open(91,file='profile_Zn_vap',status='old',
-     &            form="formatted",iostat=ierr)
-                  if (ierr .eq. 0) then 
-                        read(91,*),qsurf(iq)
-                        do ilayer=1,nlayer 
-                              read(91,*)q(ilayer,iq)
-                        enddo 
-                  else 
-                        write(*,*),"No profile_Zn_vap file !"
-                  endif
-                  close(91)
-            endif ! (txt .eq. "Zn_vap") 
-            !Zn_ice 
-            if (txt .eq. "Zn_ice") then 
+            endif ! (txt .eq. "_vap") 
+            !_ice 
+            if((txt.ne."h2o_ice") .and. 
+     &                      (index(txt,'_ice'   ) /= 0)) then
                   q(:,iq)=0. !kg/kg of atmosphere
                   qsurf(iq) = 0. !kg/kg of atmosphere
