Opened 10 years ago

Closed 4 years ago

#122 closed defect (fixed)

Problems with interpolation of regional maps

Reported by: maignan Owned by: ajornet
Priority: major Milestone: ORCHIDEE 4.0
Component: Model architecture Version: trunc
Keywords: Cc:

Description

Interpolation is not correct when giving a regional PFT map or a LAI regional map, for the corresponding regional run.
In the case of the LAI map, reverting to slowproc_interlai_OLD using the corresponding keyword gives the correct solution.
I didn't check if the variable global is correctly assessed. Anyway there is a part in aggregate_2d:

!    Duplicate the border assuming we have a global grid going from west to east

that is applied whether global is true or not.

Change History (7)

comment:1 Changed 7 years ago by jgipsl

  • Milestone changed from ORCHIDEE 1.9.7 to ORCHIDEE 3.0

comment:2 Changed 6 years ago by ajornet

In order to enable the interpolation of regional maps:

[rlmd998@ada338: MICT_MATTHIEU]$ svn diff src_global/interpol_help.f90
Index: src_global/interpol_help.f90
===================================================================
--- src_global/interpol_help.f90	(revision 4057)
+++ src_global/interpol_help.f90	(working copy)
@@ -78,7 +78,7 @@
     REAL(r_std), ALLOCATABLE, DIMENSION(:,:) :: lat_ful, lon_ful
     REAL(r_std), ALLOCATABLE, DIMENSION(:,:) :: loup_rel, lolow_rel, laup_rel, lalow_rel
     INTEGER(i_std), ALLOCATABLE, DIMENSION(:,:) :: searchind
-    REAL(r_std) :: lon_up, lon_low, lat_up, lat_low
+    REAL(r_std) :: lon_up, lon_low, lat_up, lat_low, lat_resol, lon_resol
     REAL(r_std) :: coslat, ax, ay, sgn, lonrel, lolowrel, louprel
     INTEGER(i_std) :: fopt, fopt_max, ip, jp, ib, i, itmp, iprog, nbind
     REAL(r_std) :: domain_minlon,domain_maxlon,domain_minlat,domain_maxlat
@@ -147,10 +147,9 @@
        lat_ful(iml+2,2:jml+1) = lat_rel(1,1:jml)
     ENDIF
     !
-    sgn = lat_rel(1,1)/ABS(lat_rel(1,1))
-    lat_ful(2:iml+1,1) = sgn*180 - lat_rel(1:iml,1)
-    sgn = lat_rel(1,jml)/ABS(lat_rel(1,jml))
-    lat_ful(2:iml+1,jml+2) = sgn*180 - lat_rel(1:iml,jml)
+    lat_resol = lat_rel(1,2) - lat_rel(1,1)
+    lat_ful(2:iml+1,1) = lat_rel(1,1) - lat_resol
+    lat_ful(2:iml+1,jml+2) = lat_rel(1,jml) + lat_resol
     lat_ful(1,1) = lat_ful(iml+1,1)
     lat_ful(iml+2,1) = lat_ful(2,1)
     lat_ful(1,jml+2) = lat_ful(iml+1,jml+2)
@@ -158,8 +157,11 @@
     !
     ! Add the longitude lines to the top and bottom
     !
+    lon_resol = lon_ful(3,2) - lon_ful(2,2)
     lon_ful(:,1) = lon_ful(:,2) 
     lon_ful(:,jml+2) = lon_ful(:,jml+1) 
+    lon_ful(1,:) = lon_ful(2,1) - lon_resol
+    lon_ful(iml+2,:) = lon_ful(iml+1,1) + lon_resol
     !
     !  Get the upper and lower limits of each grid box
     !

This change modifies how halo values (1+ domain +1) are computed.

For example:

Regional (previous):

  • HALO 45.25 45.75 46.23 HALO -> 21 45.25 45.75 46.25 70.

Regional (fix):

  • HALO 45.25 45.75 46.23 HALO -> 44.75 45.25 45.75 46.25 46.75

comment:3 Changed 5 years ago by aducharne

  • Milestone changed from ORCHIDEE 3.0 to ORCHIDEE 4.0
  • Owner changed from somebody to ajornet
  • Status changed from new to assigned

18/12/18: Jan dit qu'un flag a été introduit pour dire si global/regional.
Puis les interpolations ont été réécrites par Lluis.
Ce pb est a priori obsolète.

A tester si OK désormais avec un cas test régional (cas test d'Albert).

comment:4 Changed 5 years ago by ajornet

It was found on Orchidee MICT (common to trunk) by Matthieu. It was a regional map. We worked on that test case until it worked.

comment:5 Changed 5 years ago by ajornet

Regarding this ticket, should it be?

  • do you require a test case
  • close and obsolete (not fixed) - no point to do a test case -
  • close and solved (fixed)

comment:6 Changed 4 years ago by stafasca

I had this problem this summer 2019 when reading the vegetation map in a regional simulation over West Africa with ORCHIDEE tag 2.0 (old driver, 0.05° over the three ALMIP2 domains). When I tried the patch suggested by comment 2, it worked perfectly well.

comment:7 Changed 4 years ago by jgipsl

  • Resolution set to fixed
  • Status changed from assigned to closed

The solution above is done in the trunk [6326]

Note: See TracTickets for help on using tickets.