[524] | 1 | ! |
---|
| 2 | ! $Header$ |
---|
| 3 | ! |
---|
[5246] | 4 | SUBROUTINE gradiv2(klevel, xcov, ycov, ld, gdx, gdy ) |
---|
| 5 | ! |
---|
| 6 | ! P. Le Van |
---|
| 7 | ! |
---|
| 8 | ! ********************************************************** |
---|
| 9 | ! ld |
---|
| 10 | ! calcul de (grad (div) ) du vect. v .... |
---|
| 11 | ! |
---|
| 12 | ! xcov et ycov etant les composant.covariantes de v |
---|
| 13 | ! ********************************************************** |
---|
| 14 | ! xcont , ycont et ld sont des arguments d'entree pour le s-prog |
---|
| 15 | ! gdx et gdy sont des arguments de sortie pour le s-prog |
---|
| 16 | ! |
---|
| 17 | ! |
---|
[5281] | 18 | USE comgeom_mod_h |
---|
[5280] | 19 | USE comdissipn_mod_h |
---|
[5271] | 20 | USE dimensions_mod, ONLY: iim, jjm, llm, ndm |
---|
[5285] | 21 | USE paramet_mod_h |
---|
[5271] | 22 | IMPLICIT NONE |
---|
[5246] | 23 | ! |
---|
[5271] | 24 | |
---|
[5272] | 25 | |
---|
[5246] | 26 | ! |
---|
| 27 | ! ........ variables en arguments ........ |
---|
[524] | 28 | |
---|
[5246] | 29 | INTEGER :: klevel |
---|
| 30 | REAL :: xcov( ip1jmp1,klevel ), ycov( ip1jm,klevel ) |
---|
| 31 | REAL :: gdx( ip1jmp1,klevel ), gdy( ip1jm,klevel ) |
---|
| 32 | ! |
---|
| 33 | ! ........ variables locales ......... |
---|
| 34 | ! |
---|
| 35 | REAL :: div(ip1jmp1,llm) |
---|
| 36 | REAL :: signe, nugrads |
---|
| 37 | INTEGER :: l,ij,iter,ld |
---|
[524] | 38 | |
---|
[5246] | 39 | ! ........................................................ |
---|
| 40 | ! |
---|
| 41 | ! |
---|
| 42 | CALL SCOPY( ip1jmp1 * klevel, xcov, 1, gdx, 1 ) |
---|
| 43 | CALL SCOPY( ip1jm * klevel, ycov, 1, gdy, 1 ) |
---|
| 44 | ! |
---|
| 45 | ! |
---|
| 46 | signe = (-1.)**ld |
---|
| 47 | nugrads = signe * cdivu |
---|
| 48 | ! |
---|
[524] | 49 | |
---|
| 50 | |
---|
[5246] | 51 | CALL divergf( klevel, gdx, gdy , div ) |
---|
[524] | 52 | |
---|
[5246] | 53 | IF( ld.GT.1 ) THEN |
---|
[524] | 54 | |
---|
[5246] | 55 | CALL laplacien ( klevel, div, div ) |
---|
[524] | 56 | |
---|
[5246] | 57 | ! ...... Iteration de l'operateur laplacien_gam ....... |
---|
[524] | 58 | |
---|
[5246] | 59 | DO iter = 1, ld -2 |
---|
| 60 | CALL laplacien_gam ( klevel,cuvscvgam1,cvuscugam1,unsair_gam1, & |
---|
| 61 | unsapolnga1, unsapolsga1, div, div ) |
---|
| 62 | ENDDO |
---|
[524] | 63 | |
---|
[5246] | 64 | ENDIF |
---|
[524] | 65 | |
---|
| 66 | |
---|
[5246] | 67 | CALL filtreg( div , jjp1, klevel, 2, 1, .TRUE., 1 ) |
---|
| 68 | CALL grad ( klevel, div, gdx, gdy ) |
---|
| 69 | |
---|
| 70 | ! |
---|
| 71 | DO l = 1, klevel |
---|
| 72 | DO ij = 1, ip1jmp1 |
---|
| 73 | gdx( ij,l ) = gdx( ij,l ) * nugrads |
---|
| 74 | ENDDO |
---|
| 75 | DO ij = 1, ip1jm |
---|
| 76 | gdy( ij,l ) = gdy( ij,l ) * nugrads |
---|
| 77 | ENDDO |
---|
| 78 | ENDDO |
---|
| 79 | ! |
---|
| 80 | RETURN |
---|
| 81 | END SUBROUTINE gradiv2 |
---|