A GLib style wrapper library around the Swiss Ephemeris library, created by Astrodienst.
Go to file
2013-09-06 12:12:43 +02:00
data Fixed datafiles installation problems 2013-09-06 11:08:48 +02:00
docs/reference/swe-glib Changed documentation version number to reflect API version 2013-09-06 10:22:11 +02:00
po Added some missig files (e.g. .gitignore) 2013-09-05 12:33:33 +02:00
src Fixed minor issues for complete and perfect installation 2013-09-06 11:16:42 +02:00
swe Removed HTML documentation of Swiss Ephemeris. 2013-09-05 11:54:20 +02:00
.gitignore Added files generated by GObject Introspection to .gitignore 2013-09-06 11:11:01 +02:00
autogen.sh Fixed project name in autogen.sh 2013-09-05 17:14:51 +02:00
configure.ac Fixed datafiles installation problems 2013-09-06 11:08:48 +02:00
Makefile.am Added all header files for installation candidates 2013-09-06 10:22:33 +02:00
README.md Added a README.md file 2013-09-06 12:12:43 +02:00
swe-glib.pc.in Fixed swe-glib.pc dependencies 2013-09-06 11:32:54 +02:00

SWE-GLib

SWE-GLib is a GLib style wrapper library around the Swiss Ephemeris library, created by Astrodienst.

The source tree contains Astrodienst's (the writers/publishers of the Swiss Ephemeris library) ephemeride files, as requested by Alois Treindl of Astrodienst in a mail written to me on 24 July, 2013.

Usage

For exact calculations, you need to create a GsweTimestamp object:

GsweTimestamp *timestamp = gswe_timestamp_new_from_gregorian_full(1983, 3, 7, 11, 54, 45, 0, 1.0);

The GsweTimetamp object is used to convert dates between the Gregorian calendar dates and Julian Day values (not to be confused with Julian calendar dates!).

Next, you have to create a GsweMoment object:

GsweMoment *moment = gswe_moment_new_full(timestamp, 19.081599, 47.462485, 300.0, GSWE_HOUSE_PLACIDUS);

The GsweMoment object holds information of a given moment at a given place on earth. gswe_moment_new_full() requires a GsweTimestamp object, some geographical coordinates together with altitude above sea level (coordinates must be given in degrees, while altitude in meters!), and a house system to use.

About altitude

The Swiss Ephemeris library requires the altitude value to be specified for several calculations. It also notifies how important it is:

the altitude above sea must be in meters. Neglecting the altitude can result in an error of about 2 arc seconds with the moon and at an altitude 3000m.

2 arc seconds is about 0.000555 degrees of error, which is, well, kind of small. Of course, if you need very precise horoscopes, precise horoscopes; otherwise, it is safe to pass any value (well, that seems logical. The average level of all dry lands is about 840 meters; the average level of the whole planet Earth (including oceans and seas) is around 280 meters).

API stability

The project is currently marked as 1.0. However, without further notice, the API should not be seen as stable.

This means that some function prototypes may be modified in the near future. Mostly error handling routines are missing, so some functions will get a GError ** parameter.

Otherwise, the API is final, in term of future compatibility. New functions may be added later, though.