astro-0.4.1.0: Astro

CopyrightAlexander Ignatyev 2016
Safe HaskellSafe
LanguageHaskell2010

Data.Astro.Utils

Description

Utility functions.

Synopsis

Documentation

fromFixed :: (Fractional a, HasResolution b) => Fixed b -> a Source #

Convert From Fixed to Fractional

trunc :: RealFrac a => a -> a Source #

return the integral part of a number almost the same as truncate but result type is Real

fraction :: (RealFrac a, Num b) => a -> (b, a) Source #

Almost the same the properFraction function but result type

reduceToZeroRange :: RealFrac a => a -> a -> a Source #

Reduce to range from 0 to n

toRadians :: Floating a => a -> a Source #

Convert from degrees to radians

fromRadians :: Floating a => a -> a Source #

Convert from radians to degrees

roundToN :: RealFrac a => Int -> a -> a Source #

Round to a specified number of digits

tropicalYearLen :: Double Source #

Length of a tropical year in days