swiss-ephemeris-1.2.1.1: Haskell bindings for the Swiss Ephemeris C library
Safe HaskellNone
LanguageHaskell2010

Foreign.SwissEphemeris

Description

Exposes very low-level FFI bindings to the C library. Use the SwissEphemeris module and its more Haskell-friendly exports.

Synopsis

Documentation

newtype PlanetNumber Source #

Constructors

PlanetNumber 

Fields

Instances

Instances details
Eq PlanetNumber Source # 
Instance details

Defined in Foreign.SwissEphemeris

Show PlanetNumber Source # 
Instance details

Defined in Foreign.SwissEphemeris

newtype GregFlag Source #

Constructors

GregFlag 

Fields

Instances

Instances details
Eq GregFlag Source # 
Instance details

Defined in Foreign.SwissEphemeris

Show GregFlag Source # 
Instance details

Defined in Foreign.SwissEphemeris

newtype CalcFlag Source #

Constructors

CalcFlag 

Fields

Instances

Instances details
Eq CalcFlag Source # 
Instance details

Defined in Foreign.SwissEphemeris

Show CalcFlag Source # 
Instance details

Defined in Foreign.SwissEphemeris

newtype SplitDegFlag Source #

Constructors

SplitDegFlag 

Fields

Instances

Instances details
Eq SplitDegFlag Source # 
Instance details

Defined in Foreign.SwissEphemeris

Show SplitDegFlag Source # 
Instance details

Defined in Foreign.SwissEphemeris

c_swe_revjul :: CDouble -> GregFlag -> Ptr CInt -> Ptr CInt -> Ptr CInt -> Ptr CDouble -> IO () Source #

Reverse of c_swe_julday: produce a gregorian date

c_swe_calc_ut :: CDouble -> PlanetNumber -> CalcFlag -> Ptr CDouble -> CString -> IO CalcFlag Source #

Calculate the position of a body, given a time in Universal Time. Note that this is marginally more expensive than swe_calc, but I use this one to keep consistency with swe_houses.

c_swe_houses :: CDouble -> CDouble -> CDouble -> CInt -> Ptr CDouble -> Ptr CDouble -> IO CInt Source #

Get the house cusps and other relevant angles for a given time and place. Note that there's also a swe_houses_armc if one happens to have the ARMC and the ecliptic obliquity handy from other calculations.

c_swe_house_pos :: CDouble -> CDouble -> CDouble -> CInt -> Ptr CDouble -> CString -> IO CDouble Source #

Calculate the house a planet is in. Takes into account obliquity of the ecliptic. Works for all house systems, except Koch.

c_swe_cotrans_sp :: Ptr CDouble -> Ptr CDouble -> CDouble -> IO () Source #

Low-level function to translate between coordinate systems, with speed position included.

c_swe_split_deg :: CDouble -> SplitDegFlag -> Ptr CInt -> Ptr CInt -> Ptr CInt -> Ptr CDouble -> Ptr CInt -> IO () Source #

Split a given ecliptic longitude into sign (number) degrees, minutes and seconds.

c_swe_deltat :: CDouble -> IO CDouble Source #

Calculate the delta time for a given julian time, delta time + julian time = ephemeris time NOTE: there's also swe_deltat_ex which takes an ephemeris flag explicitly, vs. the current global value. my calculations work in one ephemeris, so this one is suitable.

c_swe_sidtime :: CDouble -> IO CDouble Source #

Calculate the sidereal time for a given julian time. NOTE: there's also swe_sidtime0 which requires obliquity and nutation, this one computes them internally.

c_swe_sidtime0 :: CDouble -> CDouble -> CDouble -> IO CDouble Source #

Calculate the sidereal time for a given julian time, obliquity and nutation.