Sign in to follow this  
Varmint007

Anyone want to tackle this vector Q?

Recommended Posts

Hey all,I've been trying to duplicate (for trivial reasons) the values produced by the (A:VELOCITY WORLD [x][y][z], unit), but I'm having limited sucess.I can duplicate the values 2-dimentionally thus:PITCH (radians)VS = vertical speedTAS = True airspeedHT = True Heading in radiansWS = Wind speedWD = Wind direction in radiansZ = (TAS * COS(HT)) - (WS *COS(WD))X = (TAS * SIN(HT)) - (WS *SIN(WD))The above formulas produce an exact match for (A:VELOCITY WORLD Z) and (A:VELOCITY WORLD X) UNTIL a vertical velocity is introduced, at which point Z and X are reduced by some amount which does not make sense to me.At first I assumed it would be something simple like: Z = Z - (Z * SIN(PITCH)) and X = X - (X * COS(PITCH))But neither of these work closely enough. I've also tried subtracting the vertical component prior to the wind component, and also tried subtracting the vertical component from the TAS prior to breaking the velocity into north and east components. I'm sure I'm just missing something simple, but it's giving me drain bramage.Here is some tested XML source if anyone would like to try: I have not added any code for the vertical component because none of it was working with any significant amount of pitch applied. Calculated values (right column) will match (A:VELOCITY...) (left column) until pitch is applied. You'll note the wind components are also calculated, rather than using (A:AMBIENT WIND XYZ).(A:AMBIENT WIND VELOCITY, knots) (A:AMBIENT WIND DIRECTION, radians) cos * (>L:WIND Z, enum)(A:AMBIENT WIND VELOCITY, knots) (A:AMBIENT WIND DIRECTION, radians) sin * (>L:WIND X, enum)(A:AIRSPEED TRUE, knots) (A:Plane Heading Degrees True, radians) cos * (L:WIND Z, enum) - (>L:VEL Z, enum)(A:AIRSPEED TRUE, knots) (A:Plane Heading Degrees True, radians) sin * (L:WIND X, enum) - (>L:VEL X, enum)1%ttFS9tCALCn%{lsp=23}%tNt%((A:VELOCITY WORLD Z, knots))%!4d!t%((L:VEL Z, enum))%!4d!n%tEt%((A:VELOCITY WORLD X, knots))%!4d!t%((L:VEL X, enum))%!4d!n%tUPt%((A:VELOCITY WORLD Y, knots))%!4d!t%((A:VERTICAL SPEED, knots))%!4d!n%{lsp=60}%tWIND Nt%((L:WIND Z, enum))%!d!n%tWIND Et%((L:WIND X, enum))%!d!n --Jon

Share this post


Link to post
Share on other sites
Help AVSIM continue to serve you!
Please donate today!

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this