Skip to content
Snippets Groups Projects
Commit a2033fca authored by tomrink's avatar tomrink
Browse files

snapshot...

parent 00840c34
No related branches found
No related tags found
No related merge requests found
......@@ -1115,12 +1115,23 @@ def best_fit_altitude(amv_spd, amv_dir, amv_alt, amv_lat, amv_lon, fcst_spd, fcs
# Find best fit U and V by linear interpolation:
if a2 == sat_wind_best_fit_alt:
sat_wind_best_fit_u = fcst_uwind[imin]
sat_wind_best_fit_v = fcst_vwind[imin]
else:
pass
if a2 < sat_wind_best_fit_alt:
lev_below = imin
lev_above = imin + 1
Prop = (sat_wind_best_fit_alt - a2) / (a3 - a2)
else:
pass
sat_wind_best_fit_u = fcst_uwind[lev_below] * (1.0 - Prop) + fcst_uwind[lev_above] * Prop
sat_wind_best_fit_v = fcst_vwind[lev_below] * (1.0 - Prop) + fcst_vwind[lev_above] * Prop
return bf_tup
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment