Skip to content
This repository was archived by the owner on Aug 28, 2024. It is now read-only.

Commit

Permalink
Browse files Browse the repository at this point in the history
Removed the longdouble conversion from constant numbers as it can screw with xarray
  • Loading branch information
daminton committed Nov 7, 2022
1 parent e999dd4 commit a9f5887
Showing 1 changed file with 12 additions and 9 deletions.
21 changes: 12 additions & 9 deletions python/swiftest/swiftest/constants.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,18 @@
import astropy.constants as const

# Constants in SI units
GC = np.longdouble(const.G.value)
AU2M = np.longdouble(const.au.value)
GMSunSI = np.longdouble(const.GM_sun.value)
MSun = np.longdouble(const.M_sun.value)
RSun = np.longdouble(const.R_sun.value)
GC = const.G.value
AU2M = const.au.value
GMSun = const.GM_sun.value
MSun = const.M_sun.value
RSun = const.R_sun.value
MEarth = const.M_earth.value
REarth = const.R_earth.value
GMEarth = const.GM_earth.value
JD2S = 86400
YR2S = np.longdouble(365.25 * JD2S)
einsteinC = np.longdouble(299792458.0)
YR2S = 365.25 * JD2S
einsteinC = 299792458.0
# Solar oblatenes values: From Mecheri et al. (2004), using Corbard (b) 2002 values (Table II)
J2Sun = np.longdouble(2.198e-7)
J4Sun = np.longdouble(-4.805e-9)
J2Sun = 2.198e-7
J4Sun = -4.805e-9

0 comments on commit a9f5887

Please sign in to comment.