Changeset 2160 for LMDZ5/branches/testing/libf/dyn3dmem
- Timestamp:
- Nov 28, 2014, 4:36:29 PM (10 years ago)
- Location:
- LMDZ5/branches/testing
- Files:
-
- 1 deleted
- 8 edited
- 1 copied
Legend:
- Unmodified
- Added
- Removed
-
LMDZ5/branches/testing
- Property svn:mergeinfo changed
/LMDZ5/trunk merged: 2072,2075-2115,2117-2126,2128-2158
- Property svn:mergeinfo changed
-
LMDZ5/branches/testing/libf/dyn3dmem/abort_gcm.F
r1910 r2160 23 23 C ierr = severity of situation ( = 0 normal ) 24 24 25 character(len=*) modname25 character(len=*), intent(in):: modname 26 26 integer ierr, ierror_mpi 27 character(len=*) message27 character(len=*), intent(in):: message 28 28 29 29 write(lunout,*) 'in abort_gcm' … … 46 46 write(lunout,*) 'Everything is cool' 47 47 else 48 write(lunout,*) 'Houston, we have a problem ', ierr48 write(lunout,*) 'Houston, we have a problem, ierr = ', ierr 49 49 #ifdef CPP_MPI 50 50 C$OMP CRITICAL (MPI_ABORT_GCM) -
LMDZ5/branches/testing/libf/dyn3dmem/gcm.F
r2056 r2160 174 174 !#ifdef CPP_IOIPSL 175 175 CALL conf_gcm( 99, .TRUE. , clesphy0 ) 176 if (mod(iphysiq, iperiod) /= 0) call abort_gcm("conf_gcm", 177 s "iphysiq must be a multiple of iperiod", 1) 176 178 !#else 177 179 ! CALL defrun( 99, .TRUE. , clesphy0 ) -
LMDZ5/branches/testing/libf/dyn3dmem/getparam.F90
r1910 r2160 11 11 12 12 INTERFACE getpar 13 MODULE PROCEDURE ini_getparam,fin_getparam,getparamr,getparami,getparaml13 MODULE PROCEDURE getparamr,getparami,getparaml 14 14 END INTERFACE 15 private getparamr,getparami,getparaml 15 16 16 17 INTEGER, PARAMETER :: out_eff=99 -
LMDZ5/branches/testing/libf/dyn3dmem/guide_loc_mod.F90
r2056 r2160 68 68 69 69 SUBROUTINE guide_init 70 70 71 71 USE control_mod 72 72 73 IMPLICIT NONE 73 74 … … 75 76 INCLUDE "paramet.h" 76 77 INCLUDE "netcdf.inc" 78 79 ! For grossismx: 80 include "serre.h" 77 81 78 82 INTEGER :: error,ncidpl,rid,rcod … … 94 98 CALL getpar('guide_add',.false.,guide_add,'for�age constant?') 95 99 CALL getpar('guide_zon',.false.,guide_zon,'guidage moy zonale') 100 if (guide_zon .and. abs(grossismx - 1.) > 0.01) & 101 call abort_gcm("guide_init", & 102 "zonal nudging requires grid regular in longitude", 1) 96 103 97 104 ! Constantes de rappel. Unite : fraction de jour … … 114 121 ! frequences f>0: fx/jour; f<0: tous les f jours; f=0: 1 seule fois. 115 122 IF (iguide_sav.GT.0) THEN 116 iguide_sav=day_step/iguide_sav 123 iguide_sav=day_step/iguide_sav 124 ELSE if (iguide_sav == 0) then 125 iguide_sav = huge(0) 117 126 ELSE 118 127 iguide_sav=day_step*iguide_sav 119 128 ENDIF 120 129 … … 1517 1526 enddo 1518 1527 enddo 1519 1520 1528 ENDIF ! guide_reg 1529 1530 if (.not. guide_add) alpha = 1. - exp(- alpha) 1521 1531 1522 1532 END SUBROUTINE tau2alpha -
LMDZ5/branches/testing/libf/dyn3dmem/iniacademic_loc.F90
r2056 r2160 4 4 SUBROUTINE iniacademic_loc(vcov,ucov,teta,q,masse,ps,phis,time_0) 5 5 6 USE filtreg_mod, ONLY: inifilr 6 7 use exner_hyb_m, only: exner_hyb 7 8 use exner_milieu_m, only: exner_milieu 8 USE filtreg_mod9 9 USE infotrac, ONLY : nqtot 10 10 USE control_mod, ONLY: day_step,planet_type 11 USE parallel_lmdz 11 USE parallel_lmdz, ONLY: ijb_u, ije_u, ijb_v, ije_v 12 12 #ifdef CPP_IOIPSL 13 USE IOIPSL 13 USE IOIPSL, ONLY: getin 14 14 #else 15 15 ! if not using IOIPSL, we still need to use (a local version of) getin 16 USE ioipsl_getincom 16 USE ioipsl_getincom, ONLY: getin 17 17 #endif 18 18 USE Write_Field … … 41 41 ! ---------- 42 42 43 real time_0 44 45 ! variables dynamiques 46 REAL vcov(ijb_v:ije_v,llm),ucov(ijb_u:ije_u,llm) ! vents covariants 47 REAL teta(ijb_u:ije_u,llm) ! temperature potentielle 48 REAL q(ijb_u:ije_u,llm,nqtot) ! champs advectes 49 REAL ps(ijb_u:ije_u) ! pression au sol 50 REAL masse(ijb_u:ije_u,llm) ! masse d'air 51 REAL phis(ijb_u:ije_u) ! geopotentiel au sol 43 REAL,INTENT(OUT) :: time_0 44 45 ! fields 46 REAL,INTENT(OUT) :: vcov(ijb_v:ije_v,llm) ! meridional covariant wind 47 REAL,INTENT(OUT) :: ucov(ijb_u:ije_u,llm) ! zonal covariant wind 48 REAL,INTENT(OUT) :: teta(ijb_u:ije_u,llm) ! potential temperature (K) 49 REAL,INTENT(OUT) :: q(ijb_u:ije_u,llm,nqtot) ! advected tracers (.../kg_of_air) 50 REAL,INTENT(OUT) :: ps(ijb_u:ije_u) ! surface pressure (Pa) 51 REAL,INTENT(OUT) :: masse(ijb_u:ije_u,llm) ! air mass in grid cell (kg) 52 REAL,INTENT(OUT) :: phis(ijb_u:ije_u) ! surface geopotential 52 53 53 54 ! Local: … … 80 81 character(len=80) :: abort_message 81 82 83 ! Sanity check: verify that options selected by user are not incompatible 84 if ((iflag_phys==1).and. .not. read_start) then 85 write(lunout,*) trim(modname)," error: if read_start is set to ", & 86 " false then iflag_phys should not be 1" 87 write(lunout,*) "You most likely want an aquaplanet initialisation", & 88 " (iflag_phys >= 100)" 89 call abort_gcm(modname,"incompatible iflag_phys==1 and read_start==.false.",1) 90 endif 91 82 92 !----------------------------------------------------------------------- 83 93 ! 1. Initializations for Earth-like case -
LMDZ5/branches/testing/libf/dyn3dmem/integrd_loc.F
r1910 r2160 147 147 ! & MPI_LOGICAL,MPI_LOR,COMM_LMDZ,ierr) 148 148 IF( .NOT. checksum ) THEN 149 write(lunout,*) "integrd: negative surface pressure ", 150 & ps(stop_it) 149 write(lunout,*) "integrd: ps = ", ps(stop_it) 151 150 write(lunout,*) " at node ij =", stop_it 152 151 ! since ij=j+(i-1)*jjp1 , we have … … 155 154 ! write(lunout,*) " lon = ",rlonv(i)*180./pi, " deg", 156 155 ! & " lat = ",rlatu(j)*180./pi, " deg" 156 call abort_gcm("integrd_loc", "negative surface pressure", 1) 157 157 ENDIF 158 158 … … 183 183 . dq(:,:,j)) 184 184 enddo 185 STOP185 call abort_gcm("integrd_loc", "", 1) 186 186 ENDIF 187 187 -
LMDZ5/branches/testing/libf/dyn3dmem/mod_filtreg_p.F
r1910 r2160 6 6 & ifiltre, iaire, griscal ,iter) 7 7 USE parallel_lmdz, only : OMP_CHUNK 8 USE mod_filtre_fft_loc 9 USE timer_filtre 10 11 USE filtreg_mod 8 USE mod_filtre_fft_loc, ONLY: use_filtre_fft, filtre_u_fft, 9 & filtre_v_fft, filtre_inv_fft 10 USE timer_filtre, ONLY: init_timer, start_timer, stop_timer 11 12 USE filtreg_mod, ONLY: matrinvn, matrinvs, matriceun, matriceus, 13 & matricevn, matricevs 12 14 13 15 IMPLICIT NONE … … 57 59 #include "coefils.h" 58 60 c 59 INTEGER jjb,jje,ibeg,iend,nlat,nbniv,ifiltre,iter 61 INTEGER,INTENT(IN) :: jjb,jje,ibeg,iend,nlat,nbniv,ifiltre,iter 62 INTEGER,INTENT(IN) :: iaire 63 LOGICAL,INTENT(IN) :: griscal 64 REAL,INTENT(INOUT) :: champ( iip1,jjb:jje,nbniv) 65 60 66 INTEGER i,j,l,k 61 67 INTEGER iim2,immjm 62 68 INTEGER jdfil1,jdfil2,jffil1,jffil2,jdfil,jffil 63 64 REAL champ( iip1,jjb:jje,nbniv) 65 66 LOGICAL griscal 67 INTEGER hemisph, iaire 68 69 INTEGER hemisph 69 70 REAL :: champ_fft(iip1,jjb:jje,nbniv) 70 REAL :: champ_in(iip1,jjb:jje,nbniv)71 ! REAL :: champ_in(iip1,jjb:jje,nbniv) 71 72 72 73 LOGICAL,SAVE :: first=.TRUE. … … 216 217 & champ_fft(1,j,1), iip1*(jje-jjb+1)) 217 218 #else 218 champ_fft( :,j,1:nbniv_loc)=219 & matmul(matrinvn( :,:,j),220 & champ_loc( :iim,j,1:nbniv_loc))219 champ_fft(1:iim,j,1:nbniv_loc)= 220 & matmul(matrinvn(1:iim,1:iim,j), 221 & champ_loc(1:iim,j,1:nbniv_loc)) 221 222 #endif 222 223 ENDDO … … 230 231 & champ_fft(1,j,1), iip1*(jje-jjb+1)) 231 232 #else 232 champ_fft( :,j,1:nbniv_loc)=233 & matmul(matriceun( :,:,j),234 & champ_loc( :iim,j,1:nbniv_loc))233 champ_fft(1:iim,j,1:nbniv_loc)= 234 & matmul(matriceun(1:iim,1:iim,j), 235 & champ_loc(1:iim,j,1:nbniv_loc)) 235 236 #endif 236 237 ENDDO … … 244 245 & champ_fft(1,j,1), iip1*(jje-jjb+1)) 245 246 #else 246 champ_fft( :,j,1:nbniv_loc)=247 & matmul(matricevn( :,:,j),248 & champ_loc( :iim,j,1:nbniv_loc))247 champ_fft(1:iim,j,1:nbniv_loc)= 248 & matmul(matricevn(1:iim,1:iim,j), 249 & champ_loc(1:iim,j,1:nbniv_loc)) 249 250 #endif 250 251 ENDDO … … 262 263 & champ_fft(1,j,1), iip1*(jje-jjb+1)) 263 264 #else 264 champ_fft( :,j,1:nbniv_loc)=265 & matmul(matrinvs( :,:,j-jfiltsu+1),266 & champ_loc( :iim,j,1:nbniv_loc))265 champ_fft(1:iim,j,1:nbniv_loc)= 266 & matmul(matrinvs(1:iim,1:iim,j-jfiltsu+1), 267 & champ_loc(1:iim,j,1:nbniv_loc)) 267 268 #endif 268 269 ENDDO … … 277 278 & champ_fft(1,j,1), iip1*(jje-jjb+1)) 278 279 #else 279 champ_fft( :,j,1:nbniv_loc)=280 & matmul(matriceus( :,:,j-jfiltsu+1),281 & champ_loc( :iim,j,1:nbniv_loc))280 champ_fft(1:iim,j,1:nbniv_loc)= 281 & matmul(matriceus(1:iim,1:iim,j-jfiltsu+1), 282 & champ_loc(1:iim,j,1:nbniv_loc)) 282 283 #endif 283 284 ENDDO … … 292 293 & champ_fft(1,j,1), iip1*(jje-jjb+1)) 293 294 #else 294 champ_fft( :,j,1:nbniv_loc)=295 & matmul(matricevs( :,:,j-jfiltsv+1),296 & champ_loc( :iim,j,1:nbniv_loc))295 champ_fft(1:iim,j,1:nbniv_loc)= 296 & matmul(matricevs(1:iim,1:iim,j-jfiltsv+1), 297 & champ_loc(1:iim,j,1:nbniv_loc)) 297 298 #endif 298 299 ENDDO … … 344 345 DO l = 1, nbniv 345 346 DO j = jdfil,jffil 347 ! add redundant longitude 346 348 champ( iip1,j,l ) = champ( 1,j,l ) 347 349 ENDDO … … 406 408 DO j=jdfil,jffil 407 409 ! champ_FFT( iip1,j,l ) = champ_FFT( 1,j,l ) 410 ! add redundant longitude 408 411 champ( iip1,j,l ) = champ( 1,j,l ) 409 412 ENDDO
Note: See TracChangeset
for help on using the changeset viewer.