Calculate sunrise and sunset time

5 views (last 30 days)
JEREMIE
JEREMIE on 18 Jul 2012
Answered: Meysam Mahooti on 24 Sep 2019
Hi all,
I wish to know if it's possible to calculate sunrise and sunset time using one date/time and geographical position ? Maybe a toolbox already exists ?
Thanks,

Answers (3)

JEREMIE
JEREMIE on 18 Jul 2012
toolbox suncycle.m seems to do that...
  1 Comment
Star Strider
Star Strider on 18 Jul 2012
After I searched for and found that script, I discovered that Scripps Institute of Oceanography has a large collection of MATLAB files and toolboxes:

Sign in to comment.


Meysam Mahooti
Meysam Mahooti on 24 Sep 2019

Tobias Piechowiak
Tobias Piechowiak on 16 Sep 2015
Edited: Tobias Piechowiak on 16 Sep 2015
The connection between hour angle H, latitude phi and declination of sun delta is: cos(H) = -tan(phi)*tan(delta). delta can be approximated by: delta = sin(T)*23.5 where T is time from 21th, March or 23rd, September in days. Gives good enough results +- 20 min when you assume that H is 0 deg at noon.
Greetings

Categories

Find more on Earth and Planetary Science in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!