From f723f797fbf221bb0b6bca9f7b60a5abf9b94203 Mon Sep 17 00:00:00 2001 From: Jeffrey Harris Date: Wed, 23 Jul 2025 11:36:36 +0200 Subject: [PATCH] Update geo_tools.py Make Earth radius consistent with NEMO source --- SalishSeaTools/salishsea_tools/geo_tools.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SalishSeaTools/salishsea_tools/geo_tools.py b/SalishSeaTools/salishsea_tools/geo_tools.py index ea461dcd..b203ed57 100644 --- a/SalishSeaTools/salishsea_tools/geo_tools.py +++ b/SalishSeaTools/salishsea_tools/geo_tools.py @@ -60,7 +60,7 @@ def haversine(lon1, lat1, lon2, lat2): dlat = lat2 - lat1 a = np.sin(dlat / 2) ** 2 + np.cos(lat1) * np.cos(lat2) * np.sin(dlon / 2) ** 2 c = 2 * np.arcsin(np.sqrt(a)) - km = 6367 * c + km = 6371.229 * c return km