پشتیبانی

potential temperature (Theta.gs) in grads
loading...

free grads

potential temperature in grads

Script: theta.gs; Defines potential and equlivalent potential temperature given temperature and moisture inputs

admin بازدید : 159 شنبه 05 شهریور 1401 نظرات (0)

This script, is really more of a function, the best way to use this would be to copy the contents of this script into the bottom of the script you wish to use it in.  This function reads in temperature and moisture information and returns a good approximation of both potential and equivalent potential temperature.

This function asks for up to four inputs, though only temperature and moisture inputs are required.
It is capable of calculating  equivalent potential temperature given four different moisture input variables:

  1. Relative Humidity (-rh)
  2. Mixing Ratio (-r)
  3. Vapor Pressure (-e)
  4. Specific Humidity (-q)

The default is relative humidity.

Example Usage: theta(tmpprs,rhprs)
                           -This example would define PT and EPT using relative humidity as the input.

In addition to calculating potential and equivalent potential temperature at given pressure levels, this function also allows you to specify surface pressure as the pressure input.  This adjusts for the fact that it would simply calculate everything at fixed pressure levels.

Example Usage: theta(tmp2m,spfhum2m,pressfc,'-q')
                           -This returns the surface PT and EPT calculated using specific humidity as the input.

Notes on Usage: As always, all input variables must be in MKS units.  If you wish to use a method other than relative humidity, but do not wish to use a specific variable for surface pressure, just type 'lev' or '-' in place of where surface pressure would normally go (e.g., theta(tmp,mixr,'-','-r'))  Be sure to put '' around any variables with a "-" in them, or grads will try to subtract.

I have not tested this function with all of the above variables,but this function does work well with both relative humidity and specific humidity.  As always, report any bugs here! 

*Minor bug fixed 09/2013

Download Theta.gs

ارسال نظر برای این مطلب

کد امنیتی رفرش
اطلاعات کاربری
  • فراموشی رمز عبور؟
  • آمار سایت
  • کل مطالب : 160
  • کل نظرات : 0
  • افراد آنلاین : 2
  • تعداد اعضا : 4
  • آی پی امروز : 32
  • آی پی دیروز : 64
  • بازدید امروز : 86
  • باردید دیروز : 115
  • گوگل امروز : 0
  • گوگل دیروز : 0
  • بازدید هفته : 86
  • بازدید ماه : 2,972
  • بازدید سال : 21,153
  • بازدید کلی : 257,763
  • کدهای اختصاصی