Index: LMDZ6/trunk/libf/phylmd/lmdz_cloud_optics_prop.f90
===================================================================
--- LMDZ6/trunk/libf/phylmd/lmdz_cloud_optics_prop.f90	(revision 5495)
+++ LMDZ6/trunk/libf/phylmd/lmdz_cloud_optics_prop.f90	(revision 5496)
@@ -27,4 +27,5 @@
   USE lmdz_cloud_optics_prop_ini , ONLY : rad_chau1, rad_chau2, rad_froid, iflag_rei
   USE lmdz_cloud_optics_prop_ini , ONLY : ok_icefra_lscp, rei_max, rei_min
+  USE lmdz_cloud_optics_prop_ini , ONLY : rei_coef, rei_min_temp
   USE lmdz_cloud_optics_prop_ini , ONLY : zepsec, novlp, iflag_ice_thermo, ok_new_lscp
   
@@ -300,5 +301,24 @@
           zfiwp_var = 1000.*icefrac_optics(i, k)*radocond(i, k)/pclc(i, k)*rhodz(i, k)
           ! Calculation of ice cloud effective radius in micron
-          IF (iflag_rei .EQ. 1) THEN
+          IF (iflag_rei .EQ. 2) THEN
+            ! in-cloud ice water content in g/m3
+            iwc = icefrac_optics(i,k) * radocond(i,k) / pclc(i,k) * zrho(i,k) * 1000.
+            ! this formula is a simplified version of the Sun 2001 one (as in the IFS model,
+            ! and which is activated for iflag_rei = 1).
+            ! In particular, the term in temperature**2 has been simplified.
+            ! The new coefs are tunable, and are by default set so that the results fit well
+            ! to the Sun 2001 formula
+            ! By default, rei_coef = 2.4 and rei_min_temp = 175.
+            ! The ranges of these parameters are determined so that the RMSE between this
+            ! formula and the one from Sun 2001 is less than 4 times the minimum RMSE
+            ! The ranges are [1.9, 2.9] for rei_coef and [160., 185.] for rei_min_temp
+            dei = rei_coef * (iwc**0.2445) * ( temp(i,k) - rei_min_temp )
+            ! we clip the results
+            deimax = 20.
+            deimin = 155.
+            dei = MIN(MAX(dei, deimin), deimax)
+            ! formula to convert effective diameter in effective radius
+            rei = 3. * SQRT(3.) / 8. * dei
+          ELSEIF (iflag_rei .EQ. 1) THEN
             ! when we account for precipitation in the radiation scheme,
             ! It is recommended to use the rei formula from Sun and Rikkus 1999 with a revision
@@ -407,6 +427,25 @@
 
 
-        IF (iflag_rei .GT. 0) THEN
-
+        IF (iflag_rei .EQ. 2) THEN
+            ! in-cloud ice water content in g/m3
+            iwc = icefrac_optics(i,k) * radocond(i,k) / pclc(i,k) * zrho(i,k) * 1000.
+            ! this formula is a simplified version of the Sun 2001 one (as in the IFS model,
+            ! and which is activated for iflag_rei = 1).
+            ! In particular, the term in temperature**2 has been simplified.
+            ! The new coefs are tunable, and are by default set so that the results fit well
+            ! to the Sun 2001 formula
+            ! By default, rei_coef = 2.4 and rei_min_temp = 175.
+            ! The ranges of these parameters are determined so that the RMSE between this
+            ! formula and the one from Sun 2001 is less than 4 times the minimum RMSE
+            ! The ranges are [1.9, 2.9] for rei_coef and [160., 185.] for rei_min_temp
+            dei = rei_coef * (iwc**0.2445) * ( temp(i,k) - rei_min_temp )
+            ! we clip the results
+            deimin = 20.
+            deimin = 155.
+            dei = MIN(MAX(dei, deimin), deimax)
+            ! formula to convert effective diameter to effective radius
+            rei = 3. * SQRT(3.) / 8. * dei
+
+        ELSEIF (iflag_rei .EQ. 1) THEN
             ! when we account for precipitation in the radiation scheme,
             ! we use the rei formula from Sun and Rikkus 1999 with a revision
Index: LMDZ6/trunk/libf/phylmd/lmdz_cloud_optics_prop_ini.f90
===================================================================
--- LMDZ6/trunk/libf/phylmd/lmdz_cloud_optics_prop_ini.f90	(revision 5495)
+++ LMDZ6/trunk/libf/phylmd/lmdz_cloud_optics_prop_ini.f90	(revision 5496)
@@ -21,4 +21,5 @@
   REAL, PROTECTED :: rad_chau1, rad_chau2, rad_froid
   REAL, PROTECTED :: rei_max, rei_min
+  REAL, PROTECTED :: rei_coef, rei_min_temp
   REAL, PROTECTED :: zepsec
   REAL, PARAMETER :: thres_tau=0.3, thres_neb=0.001
@@ -38,4 +39,5 @@
 !$OMP THREADPRIVATE(cdnc_min, cdnc_min_m3, rpi, rg, rd)
 !$OMP THREADPRIVATE(rad_chau1, rad_chau2, rad_froid, rei_max, rei_min)
+!$OMP THREADPRIVATE(rei_coef, rei_min_temp)
 !$OMP THREADPRIVATE(zepsec) 
 
@@ -98,4 +100,8 @@
     rei_max = 61.29
     CALL getin_p('rei_max',rei_max)
+    rei_coef = 2.4
+    CALL getin_p('rei_coef',rei_coef)
+    rei_min_temp = 175.
+    CALL getin_p('rei_min_temp',rei_min_temp)
 
    
