Jump to content
Snow?
Local
Radar
Cold?

Ipswichweather.co.uk

Members
  • Posts

    5
  • Joined

  • Last visited

Posts posted by Ipswichweather.co.uk

  1. Here you go . . .

    'a=(u,v) 'b=(0,1)

    Dim ma As Single ' |a|

    Dim m As Single

    Dim d As Single

    ' Get wind speed (magnitude) and convert it to mph

    ma = Sqr(u * u + v * v)

    m = ma * 2.24

    ' Get angle(d) difference between a, and b

    ' because cos(d) = a.b/|a||b|, therefore d = arccos(a.b/|a||b|)

    ' simplified d = arccos(v/|a|)

    d = 360 - (ArcCos(v / ma) * 57.295780490443)

    d will give you the angle (from 0..360) so you should be able to determine what you need from that.

    That is the same as my first formula 57.2957*ATAN2(u,v)+180

    That, as well as yours, should determing the quadrant in the sum.

    Ian

  2. I did something very similar in my MRes project at Leeds.

    My understanding is that U (+ve) = west-east, and V (+ve) = south-north, corresponding to the x and y axis respectively.

    Thus, I'd have thought that if U and V were positive the wind would be coming from the SW quadrant, i.e. from west-east and from south-north.

    My thoughts exactly.

    John - The replys I get from NOAA are very hard to understand, they do not make things clear to me. I think that because they are all hold Phd's they are unable to explain in simple terms to the likes of which i can understand.

    While the Met Office forecast did make to clear, but i believe they got it wrong. I reply i got from the UKMO was infact relayed though their customer enquires, so perhaps thats where the mistake was made.

    Mind you they did get the 1987 storm wrong - perhaps if they new which way the wind was blowing, they would of got it right LOL.

    Ian

  3. Hello John,

    Why do you need u and v components?

    I am procducing my own forecasts based on the GFS 0.05deg NWP model. Unlike others who use this data I use a program that converts GRIB data into its raw state.

    and does not do the caculations for me.

    The reason for this is: I can then add my own caculations based on the topography of the area i am forecasting. Plus I can change the data, if some of the values are missing - quite comman with data set as large as the GFS.

    This should allow me to produce a more realistic forecast - Well thats the plan away

    Now wind is packed in a GRIB message as U m/s and V m/s at the required height

    Example: A wind @10 meters would return as 10 HGTL V=2.3 m/s U=2.6 m/s

    Now to caculate the direction you need for find the angle

    V = North to South if V<0

    V= South to North if V>0

    U= West to East if U>0

    U= East to West if U<0

    Next you need to find the Quadrent, and this is where my trouble lies.

    Now

    N 360

    |

    |

    W 270-----------90 E

    |

    |

    S 180

    Now based on the example above U=2.6 and V=2.3, this to me would put it in the quadrent SW (between S and W)

    As U>0 and V>0.

    I caculated the angle and ask if a met office forecaster would check the anwser and my formula, before i placed it in to my math model.

    The relpy was that it should be in the SE quadrant, but i can't see how.

    I contacted NOAA who gave me the formula in my earlier message, with should caculate the Quadrent for me, as well as the angle.

    I just need some further advice weather this formula is correct, so it can be placed in my model, and carry on with my work.

    Ian

  4. Hello,

    I am not to sure weather i have posted this in the right section of this forum.

    I need help caculating wind direction from the U and V components of wind.

    I can caculate the angle and degree, but having trouble detrerming the quadrent.

    After spending many weeks on this i think i have come up with a function that returns the inverse tangent of (y/x) in the range -π ≤ return_val ≤ π, using the signs of both arguments to determine the quadrant of the return value

    The formula:

    r2d = 45.0/atan(1.0) (radians to degrees) or 57.2957795

    dir = atan2(u, v) * r2d + 180

    If some one here is able to check this formula, or knows another way please post.

    I would be most greatful.

    Ian Gooch

  5. Current Conditions For Ipswich UK

    Temp : 6.8 °C

    Wind :NW at 2.0 mph

    Rainfall : 0.6 mm

    Barometer : 1006.9 mb

    Today's Extremes

    Temp Hi : 10.8 °C Lo : 4.7 °C

    Wind Gust : 20.0 mph

    Rain Rate : 0.2 mm/hr

    Barometer Hi : 1012.9 mb Lo : 1006.8 mb

    Forecast: Mostly cloudy and cooler. Precipitation possible within 12 hours, possibly heavy at times. Windy.

    Sunrise: 7:18

    Sunset: 16:12

    Moon phase: Full Moon

    Hi all , not to sure if this is the right place to post this, you will have to tell me.

×
×
  • Create New...