Akaflieg-Freiburg / enroute

A free navigation app for VFR pilots
https://akaflieg-freiburg.github.io/enroute/
GNU General Public License v3.0
101 stars 25 forks source link

calculate Density Altitude #408

Open charlylima opened 5 months ago

charlylima commented 5 months ago

I would like to suggest that the app calculates and shows density altitude next to the Weather data.

Is your feature request related to a problem? Please describe. As a Pilot you should calculate Density Altitude before flight to decide if the runway length is sufficient for a safe takeoff. It might be that in the morning when it is still cold from the night, you can easily start from a runway in the alps, later on a sunny day with high temperate it is getting critical because the engine is loosing power with increased temperature and lower density altitude. It is often surprising for pilots when you got used to the weaker engine power in summer and then start on a cold day how much better it performs. So to do a good flight preparation you would have to calculate density altitude and estimate the takeoff distance using the tables in the aircrafts manual. But in reality, calculating Density Altitude manually is too much effort, Hobby Pilots often dont do it.

Describe the solution you'd like The App should calculate Density Altitude, based on Elevation, QNH and Temperature. It could show it below METAR data.

Describe alternatives you've considered Alternatives:

Additional context A good explanation of the formulas is on this page: https://aerotoolbox.com/density-altitude/

It could look like this: image

What do you think? And where would you add it in the UI?

My branch, first try: https://github.com/charlylima/enroute/tree/feature/densityAltitude

kebekus commented 5 months ago

@charlylima Thanks! I will definitely come back to this. It will take me a few days or weeks, though, because I am currently implementing Bluetooth support for traffic data connections.

charlylima commented 5 months ago

In case you like it, I would would then try to implement the more exact formula from aerotoolbox.com, currently on my branch is the simple linear formula that pilots use when manually calculating.

Also I would like to display a second value, the difference to the elevation of the airfield, like this: calculated Density Altitude: 2000ft (+500ft) Then the pilot could apply the value to nearby airports that do not have a Metar weather report themself.

It would also be interesting to estimate a factor by which the takeoff distance will extend, but i am not sure if it is a good idea since it would be different for turbo-charged aircraft. There is the "Koch Chart" available that tries to calculate this factor. (see FAA document about Density Altitude) (see this interactive koch chart)

Also it would be possible that the Metar already contains the Density Altitude value, although it have never seen that in germany, we should detect that and then not display the calculated value.

And I was considering to add the functionality to metaf library, but it might be not possible because the parameters of the function are like this: calculateDensityAltitude(altFeet, qnh, temp_c); and I think the elevation of the airfield would not be available if you only have the METAR report as input.

kebekus commented 5 months ago

@charlylima, I absolutely appreciate your input! Please go ahead with my blessings.

charlylima commented 1 week ago

I did not have much time to work on it during summer (since we bought an experimental aircraft !!!), but i will continue to work on it during winter time.