Copyright | Alexander Ignatyev 2017 |
---|---|
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
Stars.
Examples
Location
import Data.Astro.Time.JulianDate import Data.Astro.Coordinate import Data.Astro.Types import Data.Astro.Star ro :: GeographicCoordinates ro = GeoC (fromDMS 51 28 40) (-(fromDMS 0 0 5)) dt :: LocalCivilTime dt = lctFromYMDHMS (DH 1) 2017 6 25 10 29 0 -- Calculate location of Betelgeuse betelgeuseEC1 :: EquatorialCoordinates1 betelgeuseEC1 = starCoordinates Betelgeuse -- EC1 {e1Declination = DD 7.407064, e1RightAscension = DH 5.919529} betelgeuseHC :: HorizonCoordinates betelgeuseHC = ec1ToHC ro (lctUniversalTime dt) betelgeuseEC1 -- HC {hAltitude = DD 38.30483892505852, hAzimuth = DD 136.75755644642248}
Rise and Set
import Data.Astro.Time.JulianDate import Data.Astro.Coordinate import Data.Astro.Types import Data.Astro.Effects import Data.Astro.CelestialObject.RiseSet import Data.Astro.Star ro :: GeographicCoordinates ro = GeoC (fromDMS 51 28 40) (-(fromDMS 0 0 5)) today :: LocalCivilDate today = lcdFromYMD (DH 1) 2017 6 25 -- Calculate location of Betelgeuse rigelEC1 :: EquatorialCoordinates1 rigelEC1 = starCoordinates Rigel verticalShift :: DecimalDegrees verticalShift = refract (DD 0) 12 1012 -- DD 0.5660098245614035 rigelRiseSet :: RiseSetLCT rigelRiseSet = riseAndSetLCT ro today verticalShift rigelEC1 -- RiseSet (2017-06-25 06:38:18.4713 +1.0,DD 102.51249855335433) (2017-06-25 17:20:33.4902 +1.0,DD 257.48750144664564)
Synopsis
- data Star
- = Polaris
- | AlphaCrucis
- | Sirius
- | Betelgeuse
- | Rigel
- | Vega
- | Antares
- | Canopus
- | Pleiades
- starCoordinates :: Star -> EquatorialCoordinates1
Documentation
Some of the stars
starCoordinates :: Star -> EquatorialCoordinates1 Source #
Returns Equatorial Coordinates for the given star