Releases: Smithsonian/SuperNOVAS
v1.0.1
Bug fix release
Known Issues
Fixes for the issues affecting the original v1.0.1 are readily available in the attached 1.0.1-2
tarball; on the main
branch; and will be included in the v1.0.2
bug fix release.
- #28 --
d_light()
divide by zero if called with a zero vectorpos
argument (e.g. Sun or SSB position, depending on the solar-system calculator type). - #29 -- [CRITICAL] All calculations involving the IAU2000 nutation or
ee_ct()
yield invalid results on non-Intel x86 platforms, such as ARMv7 or PowerPC, due to a different signedness of thechar
integer type on these platforms.
Fixes
- #15 --
cirs_to_itrs()
,itrs_to_cirs()
,tod_to_itrs()
, anditrs_to_tod()
all had a unit conversion bug in using theut1_to_tt
argument [s] when converting TT-based Julian date to UT1-based JD [day] internally. - #17 -- Fixes to included
examples.c
Additions
- Added
cirs_to_app_ra()
andapp_to_cirs_ra()
for convenience to convert between right ascensions measured from the CIO (for CIRS) vs measured from the true equinox of date, on the same true equator of date.
Changes
- #18 -- Changed definition of
NOVAS_AU
to the IAU definition of exactly 149597870.7 km (a <10 m change from the previously defined value, which has been renamed toDE405_AU
). - Various corrections and changes to documentation.
v1.0
[1.0.0] - 2024-03-01
This is the initial release of the SuperNOVAS library. Changes are indicated w.r.t. the upstream NOVAS C 3.1 library
from which SuperNOVAS is forked from.
Known Issues
-
#15 --
cirs_to_itrs()
,itrs_to_cirs()
,tod_to_itrs()
, anditrs_to_tod()
all have a unit conversion bug in using theut1_to_tt
argument [s] when converting TT-based Julian date to UT1-based JD [day] internally. A fix for this bug is included in themain
branch and thev1.0.1
bug fix release. -
#28 --
d_light()
divide by zero if called withpos
argument is a zero vector (e.g. Sun or SSB, depending on the solar-system calculator type). Fix available on themain
branch and will be included in thev1.0.2
bug fix release. -
#29 -- [CRITICAL] All calculations in this release involving the IAU2000 nutation or
ee_ct()
yield invalid results on non-Intel x86 platforms, such as ARMv7 or PowerPC, due to a different signedness of thechar
integer type on these platforms. Fix available on themain
branch and will be included in thev1.0.2
bug fix release.
Fixed
-
Fixes the sidereal_time bug, whereby the
sidereal_time()
function had
an incorrect unit cast. This is a known issue of NOVAS C 3.1. -
Some remainder calculations in NOVAS C 3.1 used the result from
fmod()
unchecked, which led to the wrong results
when the numerator was negative. This affected the calculation of the mean anomaly insolsys3.c
(line 261) and
the fundamental arguments calculated infund_args()
andee_ct()
for dates prior to J2000. Less critically, it
also was the reasoncal_date()
did not work for negative JD values. -
Fixes antedating velocities and distances for light travel time in
ephemeris()
. When getting positions and
velocities for Solar-system sources, it is important to use the values from the time light originated from the
observed body rather than at the time that light arrives to the observer. This correction was done properly for
positions, but not for velocities or distances, resulting in incorrect observed radial velocities or apparent
distances being reported for spectroscopic observations or for angular-physical size conversions. -
Fixes bug in
ira_equinox()
which may return the result for the wrong type of equinox (mean vs. true) if the the
equinox
argument was changing from 1 to 0, and back to 1 again with the date being held the same. This affected
routines downstream also, such assidereal_time()
. -
Fixes accuracy switching bug in
cio_basis()
,cio_location()
,ecl2equ()
,equ2ecl_vec()
,ecl2equ_vec()
,
geo_posvel()
,place()
, andsidereal_time()
. All these functions returned a cached value for the other
accuracy if the other input parameters are the same as a prior call, except the accuracy. -
Fixes multiple bugs related to using cached values in
cio_basis()
with alternating CIO location reference
systems. -
Fixes bug in
equ2ecl_vec()
andecl2equ_vec()
whereby a query withcoord_sys = 2
(GCRS) has overwritten the
cached mean obliquity value forcoord_sys = 0
(mean equinox of date). As a result, a subsequent call with
coord_sys = 0
and the same date as before would return the results GCRS coordinates instead of the requested mean
equinox of date coordinates. -
Fixes
aberration()
returning NaN vectors if theve
argument is 0. It now returns the unmodified input vector
appropriately instead. -
Fixes unpopulated
az
output value inequ2hor()
at zenith. While any azimuth is acceptable really, it results in
unpredictable behavior. Hence, we setaz
to 0.0 for zenith to be consistent. -
Fixes potential string overflows and eliminates associated compiler warnings.
-
Fixes the ephem_close bug, whereby
ephem_close()
in
eph_manager.c
did not reset theEPHFILE
pointer to NULL. This is a known issue of NOVAS C 3.1. -
Supports calculations in parallel threads by making cached results thread-local.
Added
-
New debug mode and error traces. Simply call
novas_debug(NOVAS_DEBUG_ON)
ornovas_debug(NOVAS_DEBUG_EXTRA)
to enable. When enabled, any error conditions (such as NULL pointer arguments, or invalid input values etc.) will
be reported to the standard error, complete with call tracing within the SuperNOVAS library, s.t. users can have
a better idea of what exactly did not go to plan (and where). The debug messages can be disabled by passing
NOVAS_DEBUF_OFF
(0) as the argument to the same call. -
Added Doxygen markup of source code and header.
-
Added Makefile for GNU make.
-
Added continuous integration on GitHub, including regression testing, static analysis, and doxygen validation.
-
Added an number of precompiler constants and enums in
novas.h
to promote consistent usage and easier to read
code. -
New runtime configurability:
-
The planet position calculator function used by
ephemeris()
can be set at runtime viaset_planet_provider()
,
andset_planet_provider_hp()
(for high precision calculations). Similarly, ifplanet_ephem_provider()
or
planet_ephem_provider_hp()
(defined insolsys-ephem.c
) are set as the planet calculator functions, then
set_ephem_provider()
can set the user-specified function to use with these to actually read ephemeris data
(e.g. from a JPL ephemeris file). -
If CIO locations vs GSRS are important to the user, the user may call
set_cio_locator_file()
at runtime to
specify the location of the binary CIO interpolation table (e.g.cio_ra.bin
) to use, even if the library was
compiled with the different default CIO locator path. -
The default low-precision nutation calculator
nu2000k()
can be replaced by another suitable IAU 2006 nutation
approximation viaset_nutation_lp_provider()
. For example, the user may want to use theiau2000b()
model
instead or some custom algorithm instead.
-
-
New intutitive XYZ coordinate conversion functions:
- for GCRS - CIRS - ITRS (IAU 2000 standard):
gcrs_to_cirs()
,cirs_to_itrs()
, anditrs_to_cirs()
,
cirs_to_gcrs()
. - for GCRS - J2000 - TOD - ITRS (old methodology):
gcrs_to_j2000()
,j2000_to_tod()
,tod_to_itrs()
, and
itrs_to_tod()
,tod_to_j2000()
,j2000_to_gcrs()
.
- for GCRS - CIRS - ITRS (IAU 2000 standard):
-
New
itrs_to_hor()
andhor_to_itrs()
functions to convert Earth-fixed ITRS coordinates to astrometric azimuth
and elevation or back. Whereastod_to_itrs()
followed byitrs_to_hor()
is effectively a just a more explicit
2-step version of the existingequ2hor()
for converting from TOD to to local horizontal (old methodology), the
cirs_to_itrs()
followed byitrs_to_hor()
does the same from CIRS (new IAU standard methodology), and had no
prior equivalent in NOVAS C 3.1. -
New
ecl2equ()
for converting ecliptic coordinates to equatorial, complementing existingequ2ecl()
. -
New
gal2equ()
for converting galactic coordinates to ICRS equatorial, complementing existingequ2gal()
. -
New
refract_astro()
complements the existingrefract()
but takes an unrefracted (astrometric) zenith angle as
its argument. -
New convenience functions to wrap
place()
for simpler specific use:place_star()
,place_icrs()
,
place_gcrs()
,place_cirs()
, andplace_tod()
. -
New
radec_star()
andradec_planet()
as the common point for existing functions such asastro_star()
local_star()
,virtual_planet()
,topo_planet()
etc. -
New time conversion utilities
tt2tdb()
,get_utc_to_tt()
, andget_ut1_to_tt()
make it simpler to convert
between UTC, UT1, TT, and TDB time scales, and to supplyut1_to_tt
arguments toplace()
or topocentric
calculations. -
Co-existing
solarsystem()
variants. It is possible to use the differentsolarsystem()
implementations
provided bysolsys1.c
,solsys2.c
,solsys3.c
and/orsolsys-ephem.c
side-by-side, as they define their
functionalities with distinct, non-conflicting names, e.g.earth_sun_calc()
vsplanet_jplint()
vs
planet_eph_manager
vsplanet_ephem_provider()
. See the section on
Building and installation further above on including a selection of these in your library
build.) -
New
novas_case_sensitive(int)
to enable (or disable) case-sensitive processing of object names. (By default NOVAS
object
names were converted to upper-case, making them effectively case-insensitive.) -
New
make_planet()
andmake_ephem_object()
to make it simpler to configure Solar-system objects.
Changed
-
Changed to support for calculations in parallel threads by making cached results thread-local.
This works using the C11 standard_Thread_local
or else the earlier GNU C >= 3.3 standard__thread
modifier.
You can also set the preferred thread-local keyword for your compiler by passing it via-DTHREAD_LOCAL=...
in
config.mk
to ensure that your build is thread-safe. And, if your compiler has no support whatsoever for
thread_local variables, then SuperNOVAS will not be thread-safe, just as NOVAS C isn't. -
SuperNOVAS functions take
enum
s as their option arguments instead of raw integers. These enums are defined in
novas.h
. The same header also defines a number of useful constants. The enums allow for some compiler checking,
and make for more readable code that is easier to debug. They also make it easy to see what choices are available
for each function argument, without having to consult the documentation each and every time. -
All SuperNOVAS functions check for the basic validity of the suppli...