[ncl-talk] diagonal cross section with wrf_user_intrp3d

David Jones jonesd647 at yahoo.ca
Mon Mar 23 16:40:01 MDT 2015


Hi Matt, 

I may have encountered this problem before. If I recall correctly, wrf_user_intrp3d requires the plane to be floats, rather than integers.
You could just change your script to 
 tmp_plane = (/  40,81 , 259,81  /)
plane   = tofloat(tmp_plane)
 tc_plane = wrf_user_intrp3d(tc,z,"v",plane,0.,True)
Hope this helps,Dave.

   ------------------------------

Message: 2
Date: Mon, 23 Mar 2015 06:21:51 +0000
From: Matthew Fearon <Matthew.Fearon at dri.edu>
Subject: [ncl-talk] diagonal cross section with wrf_user_intrp3d
To: "wrf-help at ucar.edu" <wrf-help at ucar.edu>, "ncl-talk at ucar.edu"
    <ncl-talk at ucar.edu>
Message-ID:
    <CE379185CDDDEA4CB6796C413A518A638A2F3AD3 at Ex-Reno-MB1.DRI.local>
Content-Type: text/plain; charset="iso-8859-1"

Dear WRF-help and NCL users,

Has anyone successfully plotted a cross section with wrf data
along a diagonal, say southeast to northwest or vice versa, using
wrf_user_intrp3d? North/south or east/west works fine, but from the
documentation, a diagonal seemed possible using the example below,
although I can't get it working?

Also, the plane is defined (/xstart,xend , ystart,yend/) for sure
rather than (/xstart,ystart , xend,yend/) instead?

thanks,
Matt

load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl"
  load "$NCARG_ROOT/lib/ncarg/nclscripts/wrf/WRFUserARW.ncl"

  a = addfile<https://www.ncl.ucar.edu/Document/Functions/Built-in/addfile.shtml>("wrfout_d01_2000-01-24_12:00:00.nc","r")

  time = 1
  tc = wrf_user_getvar<https://www.ncl.ucar.edu/Document/Functions/WRF_arw/wrf_user_getvar.shtml>(a,"tc",time)  ; T [C]
  z  = wrf_user_getvar<https://www.ncl.ucar.edu/Document/Functions/WRF_arw/wrf_user_getvar.shtml>(a,"z",time)    ; z on mass points

  plane = (/  40,81 , 259,81  /) ; approx. START x;y and END x;y point

  ; Extract cross section from point A to point B, as defined in "plane"
  ; And vertically interpolate to height coordinates ("z")
  tc_plane = wrf_user_intrp3d(tc,z,"v",plane,0.,True)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20150323/4b9f2038/attachment-0001.html 


   
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20150323/3e6b8013/attachment.html 


More information about the ncl-talk mailing list