/[lmdze]/trunk/dyn3d/grad.f90
ViewVC logotype

Contents of /trunk/dyn3d/grad.f90

Parent Directory Parent Directory | Revision Log Revision Log


Revision 76 - (show annotations)
Fri Nov 15 18:45:49 2013 UTC (10 years, 6 months ago) by guez
File size: 970 byte(s)
Moved everything out of libf.
1 module grad_m
2
3 IMPLICIT NONE
4
5 contains
6
7 SUBROUTINE grad(klevel, g, gx, gy)
8
9 ! From LMDZ4/libf/dyn3d/grad.F, version 1.1.1.1 2004/05/19 12:53:05
10 ! P. Le Van
11
12 ! Calcul des composantes covariantes en x et y du gradient de g.
13
14 USE dimens_m, ONLY: iim
15 USE paramet_m, ONLY: iip1, ip1jm, ip1jmp1
16
17 INTEGER, intent(in):: klevel
18 REAL, intent(in):: g(ip1jmp1, klevel)
19 REAL, intent(out):: gx(ip1jmp1, klevel) , gy(ip1jm, klevel)
20
21 ! Local:
22 INTEGER l, ij
23
24 !----------------------------------------------------------------
25
26 DO l = 1, klevel
27 DO ij = 1, ip1jmp1 - 1
28 gx(ij, l) = g(ij +1, l) - g(ij, l)
29 end DO
30
31 ! correction pour gx(ip1, j, l)
32 ! gx(iip1, j, l)= gx(1, j, l)
33 DO ij = iip1, ip1jmp1, iip1
34 gx(ij, l) = gx(ij -iim, l)
35 end DO
36
37 DO ij = 1, ip1jm
38 gy(ij, l) = g(ij, l) - g(ij +iip1, l)
39 end DO
40 end DO
41
42 END SUBROUTINE grad
43
44 end module grad_m

  ViewVC Help
Powered by ViewVC 1.1.21