source: LMDZ6/branches/contrails/libf/grid/fxy_sin_mod_h.f90 @ 5435

Last change on this file since 5435 was 5287, checked in by abarral, 8 weeks ago

Turn fxy*.h into modules
Fix clesphys_rrtm.h name

  • Property copyright set to
    Name of program: LMDZ
    Creation date: 1984
    Version: LMDZ5
    License: CeCILL version 2
    Holder: Laboratoire de m\'et\'eorologie dynamique, CNRS, UMR 8539
    See the license file in the root directory
  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 712 bytes
Line 
1! This module replaces grid/fxy_sin.h
2
3MODULE fxy_sin_mod_h
4  USE comconst_mod, ONLY: pi
5  USE dimensions_mod, ONLY: iim, jjm, llm, ndm
6  IMPLICIT NONE; PRIVATE
7  PUBLIC fx, fxprim, fy, fyprim
8
9CONTAINS
10
11  REAL FUNCTION fx(ri)
12    REAL, INTENT(IN) :: ri
13    fx = 2. * pi / REAL(iim) * (ri - 0.5 * REAL(iim) - 1.)
14  END FUNCTION fx
15
16  REAL FUNCTION fxprim(ri)
17    REAL, INTENT(IN) :: ri
18    fxprim = 2. * pi / REAL(iim)
19  END FUNCTION fxprim
20
21  REAL FUNCTION fy(rj)
22    REAL, INTENT(IN) :: rj
23    fy = ASIN(1. + 2. * ((1. - rj) / REAL(jjm)))
24  END FUNCTION fy
25
26  REAL FUNCTION fyprim(rj)
27    REAL, INTENT(IN) :: rj
28    fyprim = 1. / SQRT((rj - 1.) * (jjm + 1. - rj))
29  END FUNCTION fyprim
30END MODULE fxy_sin_mod_h
Note: See TracBrowser for help on using the repository browser.