Re: Questions about VisAD units.

--Regarding the message from Gianluca <gianlucky@xxxxxxxxx> sent Sunday, May 20, 2001 11:31 PM +0200:

... The problem is that
some oceanographic units (as salinity, viscosity, ect.) are not
present in VisAD DefaultUnitsDB.class, and so I have some question
to you.
1) Could I add new units to the DefaultUnitsDB?

Though I'm no expert, I don't think you need new units for such quantities. The VisAD units are based on Unidata's udunits package, and you may find
the answers to your questions in the on-line documentation:

 http://www.unidata.ucar.edu/packages/udunits/index.html

2) I see that there are three unit constructors: ps( ), pn( ), px(
). I must use this methods to add new unit?
3) For example, one of my variable is U (velocity) who has unit
"m/s", does VisAD know that it has to take "m" and divide for "s",
or I must create a unit "m/s" with, for example:
px( "m/s", get("m").divide(get("s"))); ??
4) extending 3). Other unit is "m^2/s^2". I have to write "m2/s2"
or "m^2/s^2" when I make the netCDF file?
5) I have a variable named "sigma" that is no-dimensional. How
could I add to DefaultUnitsDB?                      px("sigma",
"null");  is good??

The udunits package definitely supports derived and dimensionless units,
and the documentation describes the proper syntax.

Dave


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