[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[python #CCF-756181]: metpy - metpy.calc.geopotential_to_height(...)



Greetings!

All of the angular calculations in MetPy will assume radians unless the values 
are annotated with proper units indicating degrees. So if you're using latitude 
in degrees you should have:

  lat = lat * units.degrees

`geostrophic_wind` is expecting to get something like this for the latitude 
parameter, which it will pass to `coriolis_parameter()` (which will return 
values with units of 1/s with proper unit information). `coriolis_parameter()` 
should try to detect if you're accidentally giving it degrees without units by 
looking for large values and warn you in that case.

Hope that helps,

Ryan

> Dear Ryan May,
> 
> 
> 
> Kevin Donkers has passed me your email address and I wondered whether you
> might be able to help me with something I think may be fairly simple to
> resolve.  I am not a meteorologist and am attempting to use the MetPy
> library for a variety of tasks.  I have seen the function
> metpy.calc.geostrophic_wind
> used in differing ways and am aware that there have been multiple
> versions.  I have managed to confuse myself and am not sure whether the
> latitude part of the of metpy.calc.geostrophic_wind(*height*, *dx*,
> *dy*, *latitude,
> *.*..) *function should be just the latitude in radians (and the
> metpy.calc.geostrophic_wind(…) function does the coriolis bit) OR whether
> it is expecting the radians returned from the *coriolis_parameter(...)
> *function
> (which I have seen examples of but in older versions of the function).


Ticket Details
===================
Ticket ID: CCF-756181
Department: Support Python
Priority: Low
Status: Closed
===================
NOTE: All email exchanges with Unidata User Support are recorded in the Unidata 
inquiry tracking system and then made publicly available through the web.  If 
you do not want to have your interactions made available in this way, you must 
let us know in each email you send to us.