12 |
! Calcule les longitudes et dérivées dans la grille du GCM pour |
! Calcule les longitudes et dérivées dans la grille du GCM pour |
13 |
! une fonction f(x) à dérivée tangente hyperbolique. |
! une fonction f(x) à dérivée tangente hyperbolique. |
14 |
|
|
15 |
! Il vaut mieux avoir : grossismx \times dzoom < pi |
! Il vaut mieux avoir : grossismx \times delta < pi |
16 |
|
|
17 |
! Le premier point scalaire pour une grille regulière (grossismx = |
! Le premier point scalaire pour une grille regulière (grossismx = |
18 |
! 1., taux = 0., clon = 0.) est à - 180 degrés. |
! 1., taux = 0., clon = 0.) est à - 180 degrés. |
29 |
|
|
30 |
! Local: |
! Local: |
31 |
real rlonm025(iim + 1), rlonp025(iim + 1), d_rlonv(iim) |
real rlonm025(iim + 1), rlonp025(iim + 1), d_rlonv(iim) |
32 |
REAL dzoom, step |
REAL delta, step |
33 |
DOUBLE PRECISION, dimension(0:nmax):: xtild, fhyp, G, Xf, ffdx |
DOUBLE PRECISION, dimension(0:nmax):: xtild, fhyp, G, Xf, ffdx |
34 |
DOUBLE PRECISION beta |
DOUBLE PRECISION beta |
35 |
INTEGER i, is2 |
INTEGER i, is2 |
39 |
|
|
40 |
print *, "Call sequence information: fxhyp" |
print *, "Call sequence information: fxhyp" |
41 |
|
|
42 |
test_grossismx: if (grossismx == 1.) then |
if (grossismx == 1.) then |
43 |
step = twopi / iim |
step = twopi / iim |
44 |
|
|
45 |
xprimm025(:iim) = step |
xprimm025(:iim) = step |
51 |
rlonm025(:iim) = rlonv(:iim) - 0.25 * step |
rlonm025(:iim) = rlonv(:iim) - 0.25 * step |
52 |
rlonp025(:iim) = rlonv(:iim) + 0.25 * step |
rlonp025(:iim) = rlonv(:iim) + 0.25 * step |
53 |
rlonu(:iim) = rlonv(:iim) + 0.5 * step |
rlonu(:iim) = rlonv(:iim) + 0.5 * step |
54 |
else test_grossismx |
else |
55 |
dzoom = dzoomx * twopi_d |
delta = dzoomx * twopi_d |
56 |
xtild = arth(0d0, pi_d / nmax, nmax + 1) |
xtild = arth(0d0, pi_d / nmax, nmax + 1) |
57 |
forall (i = 1:nmax) xmoy(i) = 0.5d0 * (xtild(i-1) + xtild(i)) |
forall (i = 1:nmax) xmoy(i) = 0.5d0 * (xtild(i-1) + xtild(i)) |
58 |
|
|
59 |
! Compute fhyp: |
! Compute fhyp: |
60 |
fhyp(1:nmax - 1) = tanh_cautious(taux * (dzoom / 2d0 & |
fhyp(1:nmax - 1) = tanh_cautious(taux * (delta / 2d0 & |
61 |
- xtild(1:nmax - 1)), xtild(1:nmax - 1) & |
- xtild(1:nmax - 1)), xtild(1:nmax - 1) & |
62 |
* (pi_d - xtild(1:nmax - 1))) |
* (pi_d - xtild(1:nmax - 1))) |
63 |
fhyp(0) = 1d0 |
fhyp(0) = 1d0 |
64 |
fhyp(nmax) = -1d0 |
fhyp(nmax) = -1d0 |
65 |
|
|
66 |
fxm = tanh_cautious(taux * (dzoom / 2d0 - xmoy), xmoy * (pi_d - xmoy)) |
fxm = tanh_cautious(taux * (delta / 2d0 - xmoy), xmoy * (pi_d - xmoy)) |
67 |
|
|
68 |
! Compute \int_0 ^{\tilde x} F: |
! Compute \int_0 ^{\tilde x} F: |
69 |
|
|
95 |
call invert_zoom_x(xf, xtild, G, rlonu(:iim), xprimu(:iim), xuv = 0.5d0) |
call invert_zoom_x(xf, xtild, G, rlonu(:iim), xprimu(:iim), xuv = 0.5d0) |
96 |
call invert_zoom_x(xf, xtild, G, rlonp025(:iim), xprimp025(:iim), & |
call invert_zoom_x(xf, xtild, G, rlonp025(:iim), xprimp025(:iim), & |
97 |
xuv = 0.25d0) |
xuv = 0.25d0) |
98 |
end if test_grossismx |
end if |
99 |
|
|
100 |
is2 = 0 |
is2 = 0 |
101 |
|
|