Changeset 1073 for LMDZ4/branches/LMDZ4_V3_patches/libf/phylmd
- Timestamp:
- Jan 19, 2009, 2:40:26 PM (16 years ago)
- Location:
- LMDZ4/branches/LMDZ4_V3_patches/libf/phylmd
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
LMDZ4/branches/LMDZ4_V3_patches/libf/phylmd/coefcdrag.F90
r793 r1073 1 !2 ! $Header$3 !4 1 ! 5 2 ! … … 54 51 include "indicesol.h" 55 52 ! Quelques constantes : 56 REAL, parameter :: RKAR=0.40, CB=5.0, CC=5.0, CD=5.0 53 REAL, parameter :: RKAR=0.40, CB=5.0, CC=5.0, CD=5.0, cepdu2=(0.1)**2 57 54 ! 58 55 ! Variables locales : … … 72 69 ! 73 70 zdphi(i) = zgeop(i) 74 zdu2(i) = speed(i)**271 zdu2(i) = max(cepdu2,speed(i)**2) 75 72 pref(i) = exp(log(psol(i)) - zdphi(i)/(RD*t(i)* & 76 73 (1.+ RETV * max(q(i),0.0)))) -
LMDZ4/branches/LMDZ4_V3_patches/libf/phylmd/conf_phys.F90
r954 r1073 1 !2 ! $Header$3 1 ! 4 2 ! … … 14 12 15 13 use IOIPSL 14 use surface_data, ONLY : version_ocean 16 15 implicit none 17 16 … … 33 32 ! 34 33 ! ocean: type d'ocean (force, slab, couple) 34 ! version_ocean: version d'ocean (opa8/nemo pour ocean=couple) 35 35 ! ok_veget: type de modele de vegetation 36 36 ! ok_journe: sorties journalieres … … 52 52 integer :: iflag_cldcon 53 53 54 character (len = 6),SAVE :: ocean_omp 54 character (len = 6),SAVE :: ocean_omp, version_ocean_omp 55 55 logical,SAVE :: ok_veget_omp, ok_newmicro_omp 56 56 logical,SAVE :: ok_journe_omp, ok_mensuel_omp, ok_instan_omp, ok_hf_omp … … 105 105 ocean_omp = 'force ' 106 106 call getin('OCEAN', ocean_omp) 107 ! 108 !Config Key = version_ocean 109 !Config Desc = Version d'ocean 110 !Config Def = xxxxxx 111 !Config Help = Version d'ocean utilise: opa8/nemo/xxxxxx 112 ! 113 version_ocean_omp = 'opa8' 114 call getin('version_ocean', version_ocean_omp) 107 115 ! 108 116 !Config Key = VEGET … … 849 857 850 858 ocean = ocean_omp 859 version_ocean = version_ocean_omp 851 860 ok_veget = ok_veget_omp 852 861 ok_newmicro = ok_newmicro_omp … … 886 895 ok_lic_melt = ok_lic_melt_omp 887 896 897 ! Test of coherence between ocean and version_ocean 898 IF (ocean=='couple' .AND. (version_ocean/='opa8' .AND. version_ocean/='nemo') ) THEN 899 WRITE(numout,*)' ERROR version_ocean=',version_ocean,' not valid in coupled configuration' 900 CALL abort_gcm('conf_phys','version_ocean not valid',1) 901 END IF 902 888 903 !$OMP MASTER 889 904 … … 891 906 write(numout,*)' Configuration des parametres de la physique: ' 892 907 write(numout,*)' Config ocean = ', ocean 908 write(numout,*)' Version ocean = ', version_ocean, ' (valable si config ocean=couple)' 893 909 write(numout,*)' Config veget = ', ok_veget 894 910 write(numout,*)' Sortie journaliere = ', ok_journe -
LMDZ4/branches/LMDZ4_V3_patches/libf/phylmd/cpl_mod.F90
r845 r1073 1 !2 ! $Header$3 1 ! 4 2 MODULE cpl_mod … … 262 260 ! 4 fields : read_sst, read_sic, read_sit and read_alb_sic. 263 261 262 USE surface_data, ONLY : version_ocean 264 263 INCLUDE "indicesol.h" 265 264 INCLUDE "temps.h" … … 306 305 307 306 ! Save each field in a 2D array. 308 read_sst(:,:) = tab_read_flds(:,:,1) ! Sea surface temperature 309 read_sic(:,:) = tab_read_flds(:,:,2) ! Sea ice concentration 310 read_alb_sic(:,:) = tab_read_flds(:,:,3) ! Albedo at sea ice 311 read_sit(:,:) = tab_read_flds(:,:,4) ! Sea ice temperature 307 IF (version_ocean=='nemo') THEN 308 read_sst(:,:) = tab_read_flds(:,:,1) ! Sea surface temperature 309 read_sic(:,:) = tab_read_flds(:,:,2) ! Sea ice concentration 310 read_sit(:,:) = tab_read_flds(:,:,3) ! Sea ice temperature 311 read_alb_sic(:,:) = tab_read_flds(:,:,4) ! Albedo at sea ice 312 ELSE IF (version_ocean=='opa8') THEN 313 read_sst(:,:) = tab_read_flds(:,:,1) ! Sea surface temperature 314 read_sic(:,:) = tab_read_flds(:,:,2) ! Sea ice concentration 315 read_alb_sic(:,:) = tab_read_flds(:,:,3) ! Albedo at sea ice 316 read_sit(:,:) = tab_read_flds(:,:,4) ! Sea ice temperature 317 ENDIF 312 318 313 319 !************************************************************************************* … … 902 908 ! all calculations at the different surfaces have to be done before. 903 909 ! 910 USE surface_data, ONLY : version_ocean 904 911 ! Some includes 905 912 !************************************************************************************* … … 950 957 ! 951 958 !************************************************************************************* 952 tab_flds(:,:,7) = cpl_windsp2D(:,:) 953 tab_flds(:,:,8) = cpl_sols2D(:,:,2) 954 tab_flds(:,:,9) = cpl_sols2D(:,:,1) 955 tab_flds(:,:,10) = cpl_nsol2D(:,:,2) 956 tab_flds(:,:,11) = cpl_nsol2D(:,:,1) 957 tab_flds(:,:,12) = cpl_fder2D(:,:,2) 958 tab_flds(:,:,13) = cpl_evap2D(:,:,2) 959 tab_flds(:,:,14) = cpl_evap2D(:,:,1) 960 tab_flds(:,:,17) = cpl_rcoa2D(:,:) 961 tab_flds(:,:,18) = cpl_rriv2D(:,:) 962 959 IF (version_ocean=='nemo') THEN 960 tab_flds(:,:,7) = cpl_windsp2D(:,:) 961 tab_flds(:,:,14) = cpl_sols2D(:,:,2) 962 tab_flds(:,:,12) = cpl_sols2D(:,:,1) 963 tab_flds(:,:,15) = cpl_nsol2D(:,:,2) 964 tab_flds(:,:,13) = cpl_nsol2D(:,:,1) 965 tab_flds(:,:,16) = cpl_fder2D(:,:,2) 966 tab_flds(:,:,11) = cpl_evap2D(:,:,2) 967 tab_flds(:,:,18) = cpl_rriv2D(:,:) 968 tab_flds(:,:,19) = cpl_rcoa2D(:,:) 969 ELSE IF (version_ocean=='opa8') THEN 970 tab_flds(:,:,7) = cpl_windsp2D(:,:) 971 tab_flds(:,:,8) = cpl_sols2D(:,:,2) 972 tab_flds(:,:,9) = cpl_sols2D(:,:,1) 973 tab_flds(:,:,10) = cpl_nsol2D(:,:,2) 974 tab_flds(:,:,11) = cpl_nsol2D(:,:,1) 975 tab_flds(:,:,12) = cpl_fder2D(:,:,2) 976 tab_flds(:,:,13) = cpl_evap2D(:,:,2) 977 tab_flds(:,:,14) = cpl_evap2D(:,:,1) 978 tab_flds(:,:,17) = cpl_rcoa2D(:,:) 979 tab_flds(:,:,18) = cpl_rriv2D(:,:) 980 ENDIF 981 963 982 !************************************************************************************* 964 983 ! Transform the fraction of sub-surfaces from 1D to 2D array … … 1008 1027 1009 1028 1010 tab_flds(:,:,19) = tmp_calv(:,:) 1029 IF (version_ocean=='nemo') THEN 1030 tab_flds(:,:,17) = tmp_calv(:,:) 1031 ELSE IF (version_ocean=='opa8') THEN 1032 tab_flds(:,:,19) = tmp_calv(:,:) 1033 ENDIF 1011 1034 1012 1035 !************************************************************************************* … … 1018 1041 ! 1019 1042 !************************************************************************************* 1020 tab_flds(:,:,15) = 0.01021 tab_flds(:,:,16) = 0.01022 tmp_taux(:,:) = 0.01023 tmp_tauy(:,:) = 0.01024 1025 1026 1043 ! fraction oce+seaice 1027 1044 deno = pctsrf2D(:,:,is_oce) + pctsrf2D(:,:,is_sic) 1028 ! For all valid grid cells containing some fraction of ocean or sea-ice 1029 WHERE ( deno(:,:) /= 0 ) 1030 tab_flds(:,:,15) = cpl_rain2D(:,:,1) * pctsrf2D(:,:,is_oce) / deno(:,:) + & 1031 cpl_rain2D(:,:,2) * pctsrf2D(:,:,is_sic) / deno(:,:) 1032 tab_flds(:,:,16) = cpl_snow2D(:,:,1) * pctsrf2D(:,:,is_oce) / deno(:,:) + & 1033 cpl_snow2D(:,:,2) * pctsrf2D(:,:,is_sic) / deno(:,:) 1045 1046 IF (version_ocean=='nemo') THEN 1047 tab_flds(:,:,10) = 0.0 1048 tmp_taux(:,:) = 0.0 1049 tmp_tauy(:,:) = 0.0 1050 ! For all valid grid cells containing some fraction of ocean or sea-ice 1051 WHERE ( deno(:,:) /= 0 ) 1052 tab_flds(:,:,10) = cpl_snow2D(:,:,1) * pctsrf2D(:,:,is_oce) / deno(:,:) + & 1053 cpl_snow2D(:,:,2) * pctsrf2D(:,:,is_sic) / deno(:,:) 1054 1055 tmp_taux = cpl_taux2D(:,:,1) * pctsrf2D(:,:,is_oce) / deno(:,:) + & 1056 cpl_taux2D(:,:,2) * pctsrf2D(:,:,is_sic) / deno(:,:) 1057 tmp_tauy = cpl_tauy2D(:,:,1) * pctsrf2D(:,:,is_oce) / deno(:,:) + & 1058 cpl_tauy2D(:,:,2) * pctsrf2D(:,:,is_sic) / deno(:,:) 1059 ENDWHERE 1060 tab_flds(:,:,8) = (cpl_evap2D(:,:,1) - ( cpl_rain2D(:,:,1) + cpl_snow2D(:,:,1))) 1061 tab_flds(:,:,9) = (cpl_evap2D(:,:,2) - ( cpl_rain2D(:,:,2) + cpl_snow2D(:,:,2))) 1034 1062 1035 tmp_taux = cpl_taux2D(:,:,1) * pctsrf2D(:,:,is_oce) / deno(:,:) + & 1036 cpl_taux2D(:,:,2) * pctsrf2D(:,:,is_sic) / deno(:,:) 1037 tmp_tauy = cpl_tauy2D(:,:,1) * pctsrf2D(:,:,is_oce) / deno(:,:) + & 1038 cpl_tauy2D(:,:,2) * pctsrf2D(:,:,is_sic) / deno(:,:) 1039 ENDWHERE 1040 1063 ELSE IF (version_ocean=='opa8') THEN 1064 tab_flds(:,:,15) = 0.0 1065 tab_flds(:,:,16) = 0.0 1066 tmp_taux(:,:) = 0.0 1067 tmp_tauy(:,:) = 0.0 1068 1069 ! For all valid grid cells containing some fraction of ocean or sea-ice 1070 WHERE ( deno(:,:) /= 0 ) 1071 tab_flds(:,:,15) = cpl_rain2D(:,:,1) * pctsrf2D(:,:,is_oce) / deno(:,:) + & 1072 cpl_rain2D(:,:,2) * pctsrf2D(:,:,is_sic) / deno(:,:) 1073 tab_flds(:,:,16) = cpl_snow2D(:,:,1) * pctsrf2D(:,:,is_oce) / deno(:,:) + & 1074 cpl_snow2D(:,:,2) * pctsrf2D(:,:,is_sic) / deno(:,:) 1075 1076 tmp_taux = cpl_taux2D(:,:,1) * pctsrf2D(:,:,is_oce) / deno(:,:) + & 1077 cpl_taux2D(:,:,2) * pctsrf2D(:,:,is_sic) / deno(:,:) 1078 tmp_tauy = cpl_tauy2D(:,:,1) * pctsrf2D(:,:,is_oce) / deno(:,:) + & 1079 cpl_tauy2D(:,:,2) * pctsrf2D(:,:,is_sic) / deno(:,:) 1080 ENDWHERE 1081 ENDIF 1082 1041 1083 !************************************************************************************* 1042 1084 ! Transform the wind components from local atmospheric 2D coordinates to geocentric -
LMDZ4/branches/LMDZ4_V3_patches/libf/phylmd/oasis.F90
r793 r1073 1 !2 ! $Header$3 1 ! 4 2 MODULE oasis … … 57 55 ! LF 09/2003 58 56 ! 57 USE surface_data, ONLY : version_ocean 59 58 INCLUDE "dimensions.h" 60 59 … … 136 135 cl_writ(6)='COTAUZZV' 137 136 cl_writ(7)='COWINDSP' 138 cl_writ(8)='COSHFICE' 139 cl_writ(9)='COSHFOCE' 140 cl_writ(10)='CONSFICE' 141 cl_writ(11)='CONSFOCE' 142 cl_writ(12)='CODFLXDT' 143 cl_writ(13)='COTFSICE' 144 cl_writ(14)='COTFSOCE' 145 cl_writ(15)='COTOLPSU' 146 cl_writ(16)='COTOSPSU' 147 cl_writ(17)='CORUNCOA' 148 cl_writ(18)='CORIVFLU' 149 cl_writ(19)='COCALVIN' 137 138 IF (version_ocean=='nemo') THEN 139 cl_writ(8) ='COPEFWAT' 140 cl_writ(9) ='COPEFICE' 141 cl_writ(10)='COTOSPSU' 142 cl_writ(11)='COICEVAP' 143 cl_writ(12)='COSWFLDO' 144 cl_writ(13)='CONSFLDO' 145 cl_writ(14)='COSHFLIC' 146 cl_writ(15)='CONSFLIC' 147 cl_writ(16)='CODFLXDT' 148 cl_writ(17)='CRWOCEIS' 149 cl_writ(18)='CRWOCERD' 150 cl_writ(19)='CRWOCECD' 151 ELSE IF (version_ocean=='opa8') THEN 152 cl_writ(8)='COSHFICE' 153 cl_writ(9)='COSHFOCE' 154 cl_writ(10)='CONSFICE' 155 cl_writ(11)='CONSFOCE' 156 cl_writ(12)='CODFLXDT' 157 cl_writ(13)='COTFSICE' 158 cl_writ(14)='COTFSOCE' 159 cl_writ(15)='COTOLPSU' 160 cl_writ(16)='COTOSPSU' 161 cl_writ(17)='CORUNCOA' 162 cl_writ(18)='CORIVFLU' 163 cl_writ(19)='COCALVIN' 164 ENDIF 150 165 ! 151 166 ! Define symbolic name for fields exchanged from coupler to atmosphere, 152 167 ! must be the same as (2) of the field definition in namcouple: 153 168 ! 154 cl_read(1)='SISUTESW' 155 cl_read(2)='SIICECOV' 156 cl_read(3)='SIICEALW' 157 cl_read(4)='SIICTEMW' 169 IF (version_ocean=='nemo') THEN 170 cl_read(1)='SISUTESW' 171 cl_read(2)='SIICECOV' 172 cl_read(4)='SIICEALW' 173 cl_read(3)='SIICTEMW' 174 ELSE IF (version_ocean=='opa8') THEN 175 cl_read(1)='SISUTESW' 176 cl_read(2)='SIICECOV' 177 cl_read(3)='SIICEALW' 178 cl_read(4)='SIICTEMW' 179 ENDIF 158 180 159 181 il_var_nodims(1) = 2 -
LMDZ4/branches/LMDZ4_V3_patches/libf/phylmd/surf_land_orchidee_mod.F90
r853 r1073 1 !2 ! $Header$3 1 ! 4 2 MODULE surf_land_orchidee_mod … … 269 267 ENDIF 270 268 269 CALL bcast(lon_scat) 270 CALL bcast(lat_scat) 271 271 272 272 ! -
LMDZ4/branches/LMDZ4_V3_patches/libf/phylmd/surface_data.F90
r803 r1073 1 !2 ! $Header$3 1 ! 4 2 MODULE surface_data … … 15 13 !$OMP THREADPRIVATE(ocean) 16 14 15 ! if ocean=couple : version_ocean=opa8 ou nemo 16 CHARACTER(len=6), SAVE :: version_ocean 17 !$OMP THREADPRIVATE(version_ocean) 18 17 19 END MODULE surface_data
Note: See TracChangeset
for help on using the changeset viewer.