File Exchange

image thumbnail

A MATLAB Script for Predicting Solar Eclipses

version 1.2.0.0 (645 KB) by David Eagle
Predict local circumstances of solar eclipses.

5 Downloads

Updated 02 Apr 2019

View License

PDF document and a MATLAB script named seclipse.m that can be used to predict local circumstances of solar eclipses. This computer program provides the universal times and topocentric coordinates of the Sun and Moon at the beginning and end of the penumbra contacts, and the time and coordinates at maximum eclipse. The source ephemeris for this routine is a JPL binary ephemeris file. This application uses several functions ported to MATLAB from the Fortran version of the NOVAS (Naval Observatory Vector Astrometry Subroutines) source code developed at the United States Naval Observatory (www.usno.navy.mil/USNO/astronomical-applications/software-products/novas). JPL binary ephemeris files for Windows compatible computers can be downloaded at http://celestialandorbitalmechanicswebsite.yolasite.com/.

Cite As

David Eagle (2019). A MATLAB Script for Predicting Solar Eclipses (https://www.mathworks.com/matlabcentral/fileexchange/39358-a-matlab-script-for-predicting-solar-eclipses), MATLAB Central File Exchange. Retrieved .

Comments and Ratings (2)

BlueEyes

Screenshot to confirm Matlab code mistake http://imgbox.com/HWirwrI5
Cheers

BlueEyes

Please, be minded that the greatest eclipse conditions (only those) seem wrong. Below my test for Boise (Idaho) location, the time
attended of the event is 11:27 local time (=18:27 UTC), not 11:00 (=18:00 UTC). The discrepancy is high. Furthermore, the magnitude should be 0.993.
Best regards

local circumstances of solar eclipses
=====================================
please input the calendar date
(1 <= month <= 12, 1 <= day <= 31, year = all digits!)
? 8,21,2017
please input the search duration (days)
? 30
please input the geographic latitude of the observer
(-90 <= degrees <= +90, 0 <= minutes <= 60, 0 <= seconds <= 60)
(north latitude is positive, south latitude is negative)
? 43,37,8
please input the geographic longitude of the observer
(0 <= degrees <= 360, 0 <= minutes <= 60, 0 <= seconds <= 60)
(east longitude is positive, west longitude is negative)
? -116,12,54
please input the altitude of the observer (meters)
(positive above sea level, negative below sea level)
? 834

searching for solar eclipse ...

greatest eclipse conditions
---------------------------
calendar date 21-Aug-2017
UTC time 18:00:00.001 ????
UTC Julian date 2457987.2500

Updates

1.2.0.0

Added display of local circumstances during the total/annular phase of a solar eclipse. Included solar eclipse documentation from Volume 2 Number 2 of Celestial Computing.

1.1.0.0

Added MICE version of this script in the solar_eclipse_mice.zip archive.

MATLAB Release Compatibility
Created with R2018a
Compatible with any release
Platform Compatibility
Windows macOS Linux