Changeset 3605 for LMDZ6/branches/Ocean_skin/libf/phylmd/atm2geo.F90
- Timestamp:
- Nov 21, 2019, 4:43:45 PM (5 years ago)
- Location:
- LMDZ6/branches/Ocean_skin
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
LMDZ6/branches/Ocean_skin
-
LMDZ6/branches/Ocean_skin/libf/phylmd/atm2geo.F90
r2429 r3605 5 5 USE dimphy 6 6 USE mod_phys_lmdz_para 7 USE mod_grid_phy_lmdz, only: grid_type, unstructured, regular_lonlat 7 8 IMPLICIT NONE 8 9 INCLUDE 'YOMCST.h' 10 11 CHARACTER (len = 6) :: clmodnam 12 CHARACTER (len = 20) :: modname = 'atm2geo' 13 CHARACTER (len = 80) :: abort_message 14 9 15 ! 10 16 ! Change wind local atmospheric coordinates to geocentric 11 17 ! 18 ! Geocentric : 19 ! axe x is eastward : crosses (0 N, 0 E) point. 20 ! axe y crosses (0 N, 90 E) point. 21 ! axe z is 'up' : crosses north pole 12 22 INTEGER, INTENT (in) :: im, jm 13 REAL, DIMENSION (im,jm), INTENT (in) :: pte, ptn 23 REAL, DIMENSION (im,jm), INTENT (in) :: pte ! Eastward vector component 24 REAL, DIMENSION (im,jm), INTENT (in) :: ptn ! Northward vector component 14 25 REAL, DIMENSION (im,jm), INTENT (in) :: plon, plat 15 REAL, DIMENSION (im,jm), INTENT(out) :: pxx, pyy, pzz 16 17 REAL :: rad 18 26 REAL, DIMENSION (im,jm), INTENT(out) :: pxx, pyy, pzz ! Component in the geocentric referential 27 REAL :: rad, reps 19 28 20 29 rad = rpi / 180.0E0 30 reps = 1.0e-5 21 31 22 32 pxx(:,:) = & … … 31 41 + ptn(:,:) * COS(rad * plat (:,:)) 32 42 33 ! Value at North Pole 34 IF (is_north_pole_dyn) THEN 35 pxx(:, 1) = - pte (1, 1) 36 pyy(:, 1) = - ptn (1, 1) 37 pzz(:, 1) = pzz(1,1) 38 ENDIF 43 IF (grid_type==regular_lonlat) THEN 44 ! Value at North Pole 45 IF (is_north_pole_dyn) THEN 46 pxx(:, 1) = - pte (1, 1) 47 pyy(:, 1) = - ptn (1, 1) 48 pzz(:, 1) = pzz(1,1) ! => 0 49 ENDIF 39 50 40 ! Value at South Pole 41 IF (is_south_pole_dyn) THEN 42 pxx(:,jm) = pxx(1,jm) 43 pyy(:,jm) = pyy(1,jm) 44 pzz(:,jm) = pzz(1,jm) 45 ENDIF 51 ! Value at South Pole 52 IF (is_south_pole_dyn) THEN 53 pxx(:,jm) = pxx(1,jm) 54 pyy(:,jm) = pyy(1,jm) 55 pzz(:,jm) = pzz(1,jm) ! => 0 56 ENDIF 57 58 ELSE IF (grid_type==unstructured) THEN 59 ! Pole nord pour Dynamico 60 WHERE ( plat(:,:) >= 90.0d+0-reps ) 61 pxx (:,:) = -ptn (:,:) 62 pyy (:,:) = pte (:,:) 63 pzz (:,:) = 0.0e0 64 END WHERE 65 66 ELSE 67 abort_message='Problem: unknown grid type' 68 CALL abort_physic(modname,abort_message,1) 69 END IF 70 46 71 47 72 END SUBROUTINE atm2geo
Note: See TracChangeset
for help on using the changeset viewer.