convert wind direction in true North to Math convention

Hi all,
I am very confused about how to convert wind direction in true North to math convention (Trigonometric style). Could anyone offer some help?
Thanks

댓글 수: 1

tanq - do you have any examples or can you provide some context? If the wind is coming from the north (0 degrees), is the "math convention" just
0 + 180 = 180 degrees
and then you convert that into radians? I'm assuming that the compass is like
N
^
|
W < - - > E
|
S
And so a wind coming from the north has a direction towards the south i.e. 180 degrees along the y-axis. Likewise, a wind from the west is blowing to the east and so its direction would be
270 + 180 = 450 = 90 degrees
I suppose that given this angle you may want to determine the x- and y-components. Since the angle is relative to true north, then for wind coming from the north with speed ws
theta = 180 (degrees)
x = ws * sind(theta)
y = ws * cosd(theta)
Or the above is wrong and isn't what you are looking for...

댓글을 달려면 로그인하십시오.

 채택된 답변

Jim Riggs
Jim Riggs 2018년 2월 16일
편집: Jim Riggs 2018년 2월 16일

1 개 추천

Working with wind direction vectors can be confusing, because there are two different conventions which are both widely used.
Meteorologists tend to describe the wind direction as the direction "from" which the wind is coming. i.e. the direction you would be facing with the wind hitting you directly in the face.
But many engineers prefer to use a wind vector defined by the direction "toward" which the wind is going. This is the direction you would be facing with the wind hitting you in the back of your head.
As you can see, these two "directions" are opposite even though they are describing the same vector. So the first step is to determine whether you are using the "from" convention or the "toward" convention.
(If you have data from a meteorological source, the wind direction is probably "direction from") The rest is simple - just draw a picture of the problem.

댓글 수: 7

Ok. thanks all.
So let's say I have a list of direction provided by Meteorologists (coming from):
55 130 220 290 (degree)
how could I convert this data into the engineering style (going to) using Matlab? Sorry for asking this simple question.
Thanks
Not sure what you mean. Attach your data file. Or else simply do
windSpeeds = [55, 130, 220, 290];
Not sure what you want to do after that with the speeds though.
Jim Riggs
Jim Riggs 2018년 2월 17일
편집: Jim Riggs 2018년 2월 17일
windir_from = [55, 130, 220, 290];
windir_toward = windir_from + 180;
or
windir_toward = winddir_from - 180;
Either of these will work. Now, if you want the component in the North and East directions then you first must convert directions to radians. Then its
Vwind_North = windspeed .* cos(windir_toward);
Vwind_East = windspeed .* sin(windir_toward);
These are the vector components of the wind (toward) which is how they would be used in a typical engineering application.
thanks Jim Riggs, but if I just simply add 180 deg into the wind direction windir_from: windir_from = [55, 130, 220, 290];
I get: windir_toward = [235 310 400 470]
Is this correct? because the wind direction in both cases ranges from 0 to 360 deg.
Please help & thanks
Jim Riggs
Jim Riggs 2018년 2월 17일
편집: Jim Riggs 2018년 2월 17일
The trigonometry functions will work with these numbers just fine. Look at the values for Vwind_North and Vwind_East, do they look right? Don't forget that the Matlab functions (sin, cos) require units of radians. If you prefer, you can apply a 0 to 360 degree limiting function;
if x < 0
x=x+360;
elseif x > 360
x=x-360;
end
Or you could use mod() or rem(). Or use sind() and cosd() if you want to do operations on angles in degrees.
However I still don't know what, given an angle in degrees, "convert wind direction in true North to math convention" means. What is "math convention"??? You've got degrees, so what do you want? I still have no idea.
great thanks all for your contributions. I sorted out

댓글을 달려면 로그인하십시오.

추가 답변 (2개)

Mayra
Mayra 2019년 7월 9일
I have been struggling with the same problem and I found an easy way to deal with this.
First you should convert your original data (direction with true north, i.e. clockwise and 0° at the top and wind intensity, I will call Direction and Wind) to cartesian coordinates.
[u,v] = pol2cart(deg2rad(Direction),Wind);
Then you convert it againd to polar coordinates but swaping u and v
[theta,rho]=cart2pol(v,u);
Now theta is the wind direction in polar coordinates, i.e. counterclockwise and 0° at right.
wave_buoys
wave_buoys 2018년 2월 17일
편집: wave_buoys 2018년 2월 17일

0 개 추천

Sorry. Here is my data from meteorological source. I want to convert it into engineering style. How could I do in Matlab?
Thanks

댓글 수: 1

OK, what about it? What do you want to do with it? I have no idea.

댓글을 달려면 로그인하십시오.

카테고리

도움말 센터File Exchange에서 Weather and Atmospheric Science에 대해 자세히 알아보기

질문:

2018년 2월 16일

답변:

2019년 7월 9일

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by