Changeset 2626
- Timestamp:
- Feb 23, 2022, 2:22:42 PM (3 years ago)
- Location:
- trunk/LMDZ.COMMON/libf
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LMDZ.COMMON/libf/dyn3dpar/filtreg_p.F
r1019 r2626 4 4 & ifiltre, iaire, griscal ,iter) 5 5 USE parallel_lmdz, only : OMP_CHUNK 6 USE mod_filtre_fft 7 USE timer_filtre 8 9 USE filtreg_mod 6 USE mod_filtre_fft, only: use_filtre_fft, filtre_u_fft 7 USE mod_filtre_fft, only: filtre_v_fft, filtre_inv_fft 8 USE timer_filtre, only: init_timer, start_timer, stop_timer 9 USE filtreg_mod, only: matriceun, matricevn, matrinvn, matrinvs 10 USE filtreg_mod, only: matriceus, matricevs 10 11 11 12 IMPLICIT NONE … … 51 52 c 52 53 c 53 #include "dimensions.h" 54 #include "paramet.h" 55 #include "coefils.h" 56 c 57 INTEGER ibeg,iend,nlat,nbniv,ifiltre,iter 54 include "dimensions.h" 55 include "paramet.h" 56 include "coefils.h" 57 c 58 REAL,INTENT(INOUT) :: champ( iip1,nlat,nbniv) 59 INTEGER,INTENT(IN) :: ibeg,iend,nlat,nbniv,ifiltre,iter 60 LOGICAL,INTENT(IN) :: griscal 61 INTEGER,INTENT(IN) :: iaire 62 58 63 INTEGER i,j,l,k 59 64 INTEGER iim2,immjm 60 65 INTEGER jdfil1,jdfil2,jffil1,jffil2,jdfil,jffil 61 66 62 REAL champ( iip1,nlat,nbniv) 63 64 LOGICAL griscal 65 INTEGER hemisph, iaire 67 INTEGER hemisph 66 68 67 69 REAL :: champ_fft(iip1,nlat,nbniv) … … 201 203 ENDDO 202 204 c$OMP END DO NOWAIT 203 204 205 nbniv_loc = ll_nb 205 206 … … 214 215 & champ_fft(1,j-jdfil+1,1), iip1*nlat) 215 216 #else 216 champ_fft(:iim,j-jdfil+1,:) 217 & =matmul(matrinvn(:,:,j),champ_loc(:iim,j,:)) 217 champ_fft(:iim,j-jdfil+1,:nbniv_loc) 218 & =matmul(matrinvn(:,:,j), 219 & champ_loc(:iim,j,:nbniv_loc)) 218 220 #endif 219 221 ENDDO … … 227 229 & champ_fft(1,j-jdfil+1,1), iip1*nlat) 228 230 #else 229 champ_fft(:iim,j-jdfil+1,:) 230 & =matmul(matriceun(:,:,j),champ_loc(:iim,j,:)) 231 champ_fft(:iim,j-jdfil+1,:nbniv_loc) 232 & =matmul(matriceun(:,:,j), 233 & champ_loc(:iim,j,:nbniv_loc)) 231 234 #endif 232 235 ENDDO … … 240 243 & champ_fft(1,j-jdfil+1,1), iip1*nlat) 241 244 #else 242 champ_fft(:iim,j-jdfil+1,:) 243 & =matmul(matricevn(:,:,j),champ_loc(:iim,j,:)) 244 #endif 245 ENDDO 246 247 ENDIF 248 249 ELSE 245 champ_fft(:iim,j-jdfil+1,:nbniv_loc) 246 & =matmul(matricevn(:,:,j), 247 & champ_loc(:iim,j,:nbniv_loc)) 248 #endif 249 ENDDO 250 251 ENDIF ! of IF( ifiltre.EQ.-2 ) ... ELSE IF ( griscal ) ... ELSE 252 253 ELSE ! of IF( hemisph.EQ.1 ) 250 254 251 255 IF( ifiltre.EQ.-2 ) THEN … … 257 261 & champ_fft(1,j-jdfil+1,1), iip1*nlat) 258 262 #else 259 champ_fft(:iim,j-jdfil+1,: )263 champ_fft(:iim,j-jdfil+1,:nbniv_loc) 260 264 & =matmul(matrinvs(:,:,j-jfiltsu+1), 261 & champ_loc(:iim,j,: ))265 & champ_loc(:iim,j,:nbniv_loc)) 262 266 #endif 263 267 ENDDO … … 272 276 & champ_fft(1,j-jdfil+1,1), iip1*nlat) 273 277 #else 274 champ_fft(:iim,j-jdfil+1,: )278 champ_fft(:iim,j-jdfil+1,:nbniv_loc) 275 279 & =matmul(matriceus(:,:,j-jfiltsu+1), 276 & champ_loc(:iim,j,: ))280 & champ_loc(:iim,j,:nbniv_loc)) 277 281 #endif 278 282 ENDDO … … 287 291 & champ_fft(1,j-jdfil+1,1), iip1*nlat) 288 292 #else 289 champ_fft(:iim,j-jdfil+1,: )293 champ_fft(:iim,j-jdfil+1,:nbniv_loc) 290 294 & =matmul(matricevs(:,:,j-jfiltsv+1), 291 & champ_loc(:iim,j,: ))292 #endif 293 ENDDO 294 295 ENDIF 296 297 ENDIF 295 & champ_loc(:iim,j,:nbniv_loc)) 296 #endif 297 ENDDO 298 299 ENDIF ! of IF( ifiltre.EQ.-2 ) ... ELSE IF ( griscal ) ... ELSE 300 301 ENDIF ! of IF( hemisph.EQ.1 ) ... ELSE 298 302 ! c 299 303 IF( ifiltre.EQ.2 ) THEN … … 334 338 c$OMP END DO NOWAIT 335 339 336 ENDIF 340 ENDIF ! of IF( ifiltre.EQ.2 ) ... ELSE 337 341 338 342 c$OMP DO SCHEDULE(STATIC,OMP_CHUNK) … … 348 352 ccccccccccccccccccccccccccccccccccccccccccccc 349 353 350 ELSE 354 ELSE ! of IF (.NOT. use_filtre_fft) 351 355 352 356 c$OMP DO SCHEDULE(STATIC,OMP_CHUNK) … … 405 409 ENDDO 406 410 c$OMP END DO NOWAIT 407 ENDIF 411 ENDIF ! of IF (.NOT. use_filtre_fft) ... ELSE 408 412 c Fin de la zone de filtrage 409 413 410 414 411 ENDDO 415 ENDDO ! of DO hemisph = 1, 2 412 416 413 417 ! DO j=1,nlat … … 430 434 CALL stop_timer 431 435 c$OMP END MASTER 432 RETURN 436 433 437 END -
trunk/LMDZ.COMMON/libf/filtrez/filtreg.F
r979 r2626 5 5 & griscal ,iter) 6 6 7 USE filtreg_mod 7 USE filtreg_mod, only: matriceun, matricevn, matrinvn, matrinvs 8 USE filtreg_mod, only: matriceus, matricevs 8 9 9 10 IMPLICIT NONE … … 46 47 c 47 48 c 48 #include "dimensions.h" 49 #include "paramet.h" 50 #include "coefils.h" 51 52 INTEGER nlat,nbniv,ifiltre,iter 49 include "dimensions.h" 50 include "paramet.h" 51 include "coefils.h" 52 53 REAL,INTENT(INOUT) :: champ( iip1,nlat,nbniv) 54 INTEGER,INTENT(IN) :: nlat,nbniv,ifiltre,iter 55 INTEGER,INTENT(IN) :: iaire 56 53 57 INTEGER i,j,l,k 54 58 INTEGER iim2,immjm 55 59 INTEGER jdfil1,jdfil2,jffil1,jffil2,jdfil,jffil 56 60 57 REAL champ( iip1,nlat,nbniv)58 61 59 62 REAL eignq(iim,nlat,nbniv), sdd1(iim),sdd2(iim) 60 LOGICAL 61 INTEGER hemisph , iaire63 LOGICAL,INTENT(IN) :: griscal 64 INTEGER hemisph 62 65 63 66 LOGICAL,SAVE :: first=.TRUE. … … 132 135 jffil2 = jjm 133 136 END IF 134 ELSE 137 ELSE ! of IF( griscal ) 135 138 IF( nlat.NE.jjm ) THEN 136 139 PRINT 2222 … … 159 162 jffil2 = jjm 160 163 END IF 161 END IF 164 END IF ! of IF( griscal ) 162 165 163 166 DO hemisph = 1, 2 … … 223 226 END DO 224 227 225 ENDIF 226 227 ELSE 228 ENDIF ! of IF( ifiltre.EQ.-2 ) ... ELSE IF ( griscal ) ... ELSE 229 230 ELSE ! of IF( hemisph. EQ. 1 ) 228 231 229 232 IF( ifiltre. EQ. -2 ) THEN … … 273 276 END DO 274 277 275 ENDIF 276 277 ENDIF 278 ENDIF ! of IF( ifiltre.EQ.-2 ) ... ELSE IF ( griscal ) ... ELSE 279 280 ENDIF ! of IF( hemisph. EQ. 1 ) 278 281 279 282 IF( ifiltre.EQ. 2 ) THEN … … 301 304 END DO 302 305 303 ENDIF 306 ENDIF ! of IF( ifiltre.EQ. 2 ) 304 307 305 308 DO l = 1, nbniv … … 310 313 311 314 312 ENDDO 315 ENDDO ! of DO hemisph = 1, 2 313 316 314 317 1111 FORMAT(//20x,'ERREUR dans le dimensionnement du tableau CHAMP a … … 316 319 2222 FORMAT(//20x,'ERREUR dans le dimensionnement du tableau CHAMP a fi 317 320 & ltrer, sur la grille de V ou de Z'/) 318 RETURN 321 319 322 END
Note: See TracChangeset
for help on using the changeset viewer.