Project

General

Profile

Regarding Bilinear Interpolation in CDO

Added by Pankaj Narula almost 2 years ago

I have netcdf file of the wind vector (u component) and rainfall netcdf file. Wind data is at gaussian grids whereas rainfall data at from regular grids. I want to interpolate wind data exactly at rainfall grids. I used

cdo remapbil,r360x180 uwnd.10m.gauss.1979.nc uwnd_1979_regular.nc, but grids are not matching with that of the rainfall file in nature (Wind data is global and rainfall data is of India, my point is lat-lon arrangement is different). I am just a beginner at CDO. Please help.


Replies (2)

RE: Regarding Bilinear Interpolation in CDO - Added by Pankaj Narula almost 2 years ago

I am not able to edit this post. I am also attaching the original file of u-wind data.

RE: Regarding Bilinear Interpolation in CDO - Added by Karin Meier-Fleischer almost 2 years ago

Hi Pankaj,

it is not the same as the rainfall_1979 grid because you remapped it to a 1x1 deg global grid. But the rainfall_1979 has a regional grid.

cdo sinfon rainfall_1979 
   File format : NetCDF
    -1 : Institut Source   T Steptype Levels Num    Points Num Dtype : Parameter name
     1 : unknown  unknown  v instant       1   1      1155   1  F64  : RAINFALL      
   Grid coordinates :
     1 : lonlat                   : points=1155 (35x33)
                        LONGITUDE : 66.5 to 100.5 by 1 degrees_east
                         LATITUDE : 6.5 to 38.5 by 1 degrees_north
   Vertical coordinates :
     1 : surface                  : levels=1
   Time coordinate :
                             TIME : 365 steps
     RefTime =  1900-12-31 00:00:00  Units = days  Calendar = standard
  YYYY-MM-DD hh:mm:ss  YYYY-MM-DD hh:mm:ss  YYYY-MM-DD hh:mm:ss  YYYY-MM-DD hh:mm:ss
  1979-01-01 00:00:00  1979-01-02 00:00:00  1979-01-03 00:00:00  1979-01-04 00:00:00
  1979-01-05 00:00:00  1979-01-06 00:00:00  1979-01-07 00:00:00  1979-01-08 00:00:00
  ...

To remap the data to the rainfall_1979 grid you can use the file as grid description itself.

cdo remapbil,rainfall_1979 uwnd.10m.gauss.1979.nc uwnd_1979_regular_same_grid_as_rainfall_1979.nc

And when you now take a look at the grid you can see it is the same as for rainfall_1979.

cdo sinfon uwnd_1979_regular_same_grid_as_rainfall_1979.nc
   File format : NetCDF4 classic
    -1 : Institut Source   T Steptype Levels Num    Points Num Dtype : Parameter name
     1 : NCEP     NCEP/DOE v instant       1   1      1155   1  F32  : uwnd          
   Grid coordinates :
     1 : lonlat                   : points=1155 (35x33)
                        LONGITUDE : 66.5 to 100.5 by 1 degrees_east
                         LATITUDE : 6.5 to 38.5 by 1 degrees_north
   Vertical coordinates :
     1 : generic                  : levels=1
                            level : 10 m
   Time coordinate :
                             time : 365 steps
     RefTime =  1800-01-01 00:00:00  Units = hours  Calendar = standard  Bounds = true
  YYYY-MM-DD hh:mm:ss  YYYY-MM-DD hh:mm:ss  YYYY-MM-DD hh:mm:ss  YYYY-MM-DD hh:mm:ss
  1979-01-01 00:00:00  1979-01-02 00:00:00  1979-01-03 00:00:00  1979-01-04 00:00:00
  1979-01-05 00:00:00  1979-01-06 00:00:00  1979-01-07 00:00:00  1979-01-08 00:00:00
  1979-01-09 00:00:00  1979-01-10 00:00:00  1979-01-11 00:00:00  1979-01-12 00:00:00
  ...
    (1-2/2)