Tic-Tac Posted December 17, 2018 Share Posted December 17, 2018 I'm trying to return IAS of a unit using local speed = math.sqrt(velocity.x^2 + velocity.y^2 + velocity.z^2) I'm guessing returns ground speed? I'm familiar with the calc to convert IAS to TAS, but that's not really helping Any ideas? Link to comment Share on other sites More sharing options...
catt42 Posted December 17, 2018 Share Posted December 17, 2018 (edited) I get a good approximation with this metod: The formula you wrote gives tas (3d), multiply tas by 1.94384 to get true speed in knots. Then, ias = tas * (1- (6.87535 * 10^(-6) * altitude))^2.128 Altitude is expressed in feet: local altitude = unit:getPoint().y * 3.28084 Inviato dal mio S2 utilizzando Tapatalk Edited December 17, 2018 by catt42 Link to comment Share on other sites More sharing options...
catt42 Posted December 17, 2018 Share Posted December 17, 2018 Thinking about it, I don't think that your formula returns true airspeed, most likely it's some sort of 3d ground speed. You probably should take into consideration the wind vector to get tas. Anyway, that's probably where my formula error comes from. Inviato dal mio S2 utilizzando Tapatalk Link to comment Share on other sites More sharing options...
Tic-Tac Posted December 17, 2018 Author Share Posted December 17, 2018 (edited) Thanks for the reply, I think I have a pretty good solution, I think similar to yours... been testing a number of scenarios and it seems fairly accurate +/- 1kts between 20000ft - 500ft...but I could be deluding myself... I'm making a couple of assumptions, 1) for height I need above MSL, so I'm using height from getposition to give me above MSL in metres 2) the velocity speed will already take wind into account as it's ground speed, speed as measured over the ground Please set me right if either of these is wrong the formula that seems to work... local IAS = speed -(((alt_MSL^0.964/1000) * 0.019329)*speed) see above for speed So far I tested by running just an AI flight so it showed IAS at the bottom of the screen I expected temperature to be a factor, but does not seem to be... Edited December 17, 2018 by Tic-Tac Link to comment Share on other sites More sharing options...
Habu_69 Posted December 17, 2018 Share Posted December 17, 2018 So speed is in miles per hour?? Link to comment Share on other sites More sharing options...
Tic-Tac Posted December 17, 2018 Author Share Posted December 17, 2018 (edited) So speed is in miles per hour?? converted into kts for the formula (originally m/s), * 1.9438445 Edited December 17, 2018 by Tic-Tac Link to comment Share on other sites More sharing options...
Recommended Posts