Skip to content

Calculates today's times of sunrise and sunset for a given location.

License

Notifications You must be signed in to change notification settings

martinvlk/sunrise-equation

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

sunrise-equation

This will calculate todays times of sunrise and sunset for a given location.

It currently uses hard coded location, but it is easy to change in the source and rebuild using "cabal build".

I have just used this exercise to learn Haskell. Might make it more generic later on.

sunrise-equation.cws is a Cantor/Octave worksheet I used to learn the algorithm before implementing in Haskell.

The sources of the algorithms I used:

Sunrise equation http://users.electromagnetic.net/bu/astro/sunrise-set.php

Julian days calculation https://en.wikipedia.org/wiki/Julian_day#Converting_Julian_or_Gregorian_calendar_date_to_Julian_Day_Number

About

Calculates today's times of sunrise and sunset for a given location.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published