Page 1 of 1

Get level height from ARWpost

PostPosted: Wed Aug 27, 2014 8:56 am
by brunocampos
Hi all,

I'd like to know how to get the height (in meters or km) of the vertical levels from the WRF output.
I am using a simulation with 70 vertical levels (e_vert = 70) and the ARWpost output just give me the sigma levels or the model levels (1 to 70).

Thank you!

Bruno.

Re: Get level height from ARWpost

PostPosted: Fri Aug 29, 2014 12:06 pm
by brunocampos
Hey

Just solved it.
I used this post as guide: viewtopic.php?f=8&t=5695

Here's a simple code in NCL to find it:

Code: Select all
  load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl"
  load "$NCARG_ROOT/lib/ncarg/nclscripts/wrf/WRFUserARW.ncl"

  nlvmax=69

  f = addfile("wrfout_d01_2013-09-21_18:00:00","r")

  Z = wrf_user_getvar(f,"height", -1) ;m Model Height
  Zter = wrf_user_getvar(f,"ter" , -1) ;m Terrain Height

  Zcat = Z(:,0:nlvmax-1,:,:)

  do kk = 0, nlvmax-1
    Zcat(:,kk,:,:) = Zcat(:,kk,:,:) - Zter
  end do

  print(Zcat(0,:,30,30))



Cheers,

Bruno DE CAMPOS.

Re: Get level height from ARWpost

PostPosted: Thu Jul 16, 2015 2:26 am
by neluwala
thanks