View License

Download apps, toolboxes, and other File Exchange content using Add-On Explorer in MATLAB.

» Watch video

Highlights from
A MATLAB Script for Predicting Transits of Mercury and Venus

  • aberatthis function corrects position vector for aberration of light.
  • anglesthis function converts a vector to angular quantities
  • applan1this function computes the apparent geocentric or topocentric place
  • atan3four quadrant inverse tangent
  • brentsolve for a single real root of a nonlinear equation
  • brootbracket a single root of a nonlinear equation
  • deg2dmsconvert decimal degrees to degrees,
  • esfunc(x)equinox/solstice objective function
  • etilt1this function computes quantities related to the orientation
  • findleap(jdate)find number of leap seconds for utc julian date
  • funargthis subroutine computes fundamental arguments (mean elements)
  • gast2this function computes the greenwich sidereal time
  • gdateconvert Julian date to Gregorian (calendar) date
  • geocenthis function moves the origin of coordinates from the
  • getdateinteractive request and input of calendar date
  • getobsinteractive request of observer coordinates
  • hrs2hmsconvert decimal hours to hours,
  • jd2str(jdate)convert Julian date to string equivalent
  • jplephemreads the jpl planetary ephemeris and gives
  • julianJulian date
  • minimaone-dimensional minimization
  • nutate1this function nutates equatorial rectangular coordinates from
  • precessthis function precesses equatorial rectangular coordinates from
  • readleapread leap seconds data file
  • solsyspurpose
  • sunfldthis function corrects position vector for the deflection
  • tdtimesthis function computes the terrestrial time (tt)
  • terrathis functions computes the position and velocity vectors of
  • traeventpredict transit events
  • tranfunc(x)transit objective function
  • tranprt(iflag, jdutc)print transit conditions
  • utc2tdbconvert UTC julian date to TDB julian date
  • utc2tdtconvert UTC julian date to TDT julian date
  • equsol.m
  • transit.m
  • View all files
Be the first to rate this file! 4 Downloads (last 30 days) File Size: 452 KB File ID: #39355 Version: 1.1

A MATLAB Script for Predicting Transits of Mercury and Venus


David Eagle (view profile)


07 Dec 2012 (Updated )

Local circumstances of solar transits of the planets Mercury and Venus.

| Watch this File

File Information

PDF document and a MATLAB script named transit.m which can be used to predict the local circumstances of transits of Mercury and Venus across the Sun. This software provides the universal times and topocentric coordinates of the Sun at the beginning (ingress - exterior contact) and end (egress - exterior contact) of the solar transit, and the time and coordinates at least distance. 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 ( JPL binary ephemeris files for Windows compatible computers can be downloaded at

MATLAB release MATLAB 7.12 (R2011a)
Other requirements Requires platform specific version of MICE mex file and de421.bsp binary ephemeris file. Both are available at
Tags for This File   Please login to tag files.
Please login to add a comment or rating.
04 Feb 2013 1.1

Added MICE version in the archive.

Contact us