From eb790c6c0b6c211ac6a791810cc80ab98eb572e3 Mon Sep 17 00:00:00 2001 From: Ryan Beall Date: Mon, 31 Jan 2022 14:31:38 -0800 Subject: [PATCH] AP_Baro.cpp: Add in notes for standard day model accuracy --- libraries/AP_Baro/AP_Baro.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libraries/AP_Baro/AP_Baro.cpp b/libraries/AP_Baro/AP_Baro.cpp index 5d726a5bc9..e2572bab1e 100644 --- a/libraries/AP_Baro/AP_Baro.cpp +++ b/libraries/AP_Baro/AP_Baro.cpp @@ -403,7 +403,8 @@ float AP_Baro::get_sealevel_pressure(float pressure) const { float temp = C_TO_KELVIN(get_ground_temperature()); float p0_sealevel; - + // This is an exact calculation that is within +-2.5m of the standard + // atmosphere tables in the troposphere (up to 11,000 m amsl). p0_sealevel = 8.651154799255761e30f*pressure*powF((769231.0f-(5000.0f*_field_elevation_active)/temp),-5.255993146184937f); return p0_sealevel;