Re: Plotting isobaric surface in 3D


On Tue, 31 Oct 2006, Tom Whittaker wrote:

To show the "topography" of an isobaric surface in the IDV, you need
only extract the "geopotential height" grid for the desired pressure
level as a 2D grid and then display it as topography.  In the current
IDV release, one Jython function is missing, so you'll have to put one
in!  It's EASY, though!

Tom,

It was indeed easy, and it does look great--thanks very much for whipping this up! Hard to believe that this capability wasn't in the IDV early on--those of us on the MetApps Task Force and its successor advisory group must have overlooked it somehow.

Now I want to plot wind vectors and stuff on that gorgeous isobaric surface ....

-- Dave

****************************************************************
*                                      |         __ __    \|/  *
*   Dr. Dave Dempsey                   | )   ^  /|| ||\  --0-- *
*   Dept. of Geosciences               |) ) ^  / ||_|| \  /|\  *
*   San Francisco State University     | ) )  /  | _ |  \      *
*   1600 Holloway Ave.                 |)   )/   || ||   \     *
*   San Francisco, CA   94132          | )   )   ||_||    \    *
*                                      |)  ) )   | _ |     \   *
*   Phone:  (415) 338-7716             |  )   )  || ||      \  *
*   FAX:    (415) 338-7705             |)   )  )~~~~~~~~~~~~~~~*
*   Email:  ddempsey@xxxxxxxxxxxxxxx   |  )  )  )  ~  ~   ~ ~  *
*                                      |)  )   ) )  ~   ~  ~   *
****************************************************************

(Note that steps 1-4 are a "one time" step to define the function and
formula you can then use "forever"...)

1. Fire up the IDV and pick "Edit -> Formulas -> Jython Library
2. in the Jython library window, pick the "User's LIbrary" tab, and
then click in the edit window on a blank line, and then copy-and-paste
this formula (to paste, use "CTRL+V"):

def threeDPressure(z, level):
import ucar.unidata.data.grid.GridUtil as gu
return gu.make2DGridFromSlice(gu.sliceAtLevel(z,float(level)))

(Note that spacing is important - this is Python).

3. Click File->Save, and after a few seconds, you can then click "Close".
4. Now you need to make a small formula to call this method.  If
you've never done that before, here are the steps:
 a. back in the main window, "Edit->Formulas -> Create Formula"
 b. Give it a name like "3D Pressure Surface"
 c. for the formula, use:

threeDPressure(z, level[isuser=true, default=500])

 d. in the "advanced" section, be sure that "3D -> Topography" is
clicked (along with whatever
      else y ou might want)
 e. Click "Add formaula" and you're done!

5. Of course, you only have to do these steps one time, because the
IDV will save the Jython code and the formula....

6. Now, pick your favorite model in the Data Chooser
7. In the Field Selector window (or pane) pick the "Formulas" for the
"Data Source"
8. Find your "3D Pressure Surface" formula and click on it
9. Then pick "Topography"  (under the "3D Surface") for the Display type
10. Click "Create Display"
11. In the little "Select Input" pop-up, pick the level you want and click "OK"
12. In the pop-up that says "Field: z", find the 3D grid of
"Geopotential height at isobaric levels"
13. Select the dates/times you want, and click "OK"
14. After a few seconds you'll have the plot!!
15. Now when you rotate the 3D display, you'll notice it is kinda
"flat".  You can easily stretch this
    out using the menu item:  "View -> Viewpoint -> Vertical Scale".
I picked 5000 to 6000 for the 500mb surface and it looks great!

Here's what mine looks like:
<http://www.ssec.wisc.edu/~tomw/temp/dave.gif>

Using the same idea (and formula), you can also produce other fields
"draped" over the "topography".  The possibilities are mind boggling!

In a future release of the IDV, there will be a System Formula to help
out with this, but this should get you going......  Let me know if you
have any questions!

tom

--
Tom Whittaker
University of Wisconsin-Madison
Space Science & Engineering Center (SSEC)
Cooperative Institute for Meteorological Satellite Studies (CIMSS)
1225 W. Dayton Street
Madison, WI  53706  USA
ph: +1 608 262 2759





  • 2006 messages navigation, sorted by:
    1. Thread
    2. Subject
    3. Author
    4. Date
    5. ↑ Table Of Contents
  • Search the idvusers archives: