SunAltitude is a command line utility that determines:

The software needs the observer's position (longitude, latitude, altitude above sea level) and optionally accounts for atmospheric refraction.
Very precise algorithms are used for the computation of the sun position, but local atmospheric conditions can affect the actual values.
Exceptionally, the algorithm might not converge for very specific combinations of time and observer's location, but this limitation should not be problem for most of the users.

It can output either data tables or graphs.

Data table output

The results are fomatted with three columns:
>SunAltitude.exe --day 12082007 --latitude 40 --longitude 3 --altitude 0.2 --verbose
Values for 12/08/2007 at 0.20 km height, 40° latitude and 3° longitude.
Interval is 600 seconds.

Column 1 is the time (HH:MM:SS).
Column 2 is the sun center angle with respect to the horizon, in degrees.
Column 3 is the minimum height at which the sun upper limb is visible, in km.

Time     	Alt (°)	Height (km)
00:00:00	-34.38	1365.54
00:10:00	-34.26	1354.97
00:20:00	-34.05	1335.50
00:30:00	-33.74	1307.53
00:40:00	-33.34	1271.59
00:50:00	-32.85	1228.35
01:00:00	-32.26	1178.58
01:10:00	-31.59	1123.14
01:20:00	-30.83	1062.95
01:30:00	-29.99	998.92
01:40:00	-29.08	931.99
01:50:00	-28.09	863.08
02:00:00	-27.03	793.05

Graph output

The graph x-axis is the time of the day of interest.
The red plot is the sun altitude in degrees, displayed against the left y-axis
The green plot is the minimum sun visibility height, displayed against the right y-axis

>SunAltitude.exe --day 12082007 --latitude 40 --longitude 3 --altitude 0.2 --graph 'test.png'
SunAltitude Graph Example


Current version is

SunAltitude binary and source can be downloaded through anonymous SVN at the following address:

SunAltitude has been developped in C# under MonoDevelop 2.0. It can also be compiled under Visual Studio 2008.
It has been tested under Linux Ubuntu 9.10/Mono, and under Windows XP/.NET 2.0.


Under Windows, it is necessary to install :
Under Linux, it is necessary to install :
In addition, gnuplot must be installed to generate graphs: Refer to the gnuplot homepage. Under Linux, gnuplot needs the Arial font that must be installed, and the environment variable GDFONTPATH must be initialized to the relevant font path, for instance:



 --start  --end 
              --longitude  --latitude  | --locator 
              --altitude  --step  [--refract|--r] [--verbose|--v]
              [--gnuplot ""] [--graph null|]
              [--height ] [--width ]

    help      Shows this message.
    day       Date for which the values are calculated.
              Format is DDMMYYYY (e.g. 12012006 for 12 January 2006).
    start     Start time of the calculations range.
              Format is HH:mm (e.g. 04:30). Default is 00:00.
    end       End time of the calculations range.
              Format is HH:mm (e.g. 18:15). Default is 24:00.
    longitude Value between -180 and 180 expressing the longitude of the
              location in degrees. String representations are accepted.
              Positive values in the eastern hemisphere. Default is 0.
    latitude  Value between -90 and 90 expressing the latitude of the
              location in degrees. String representations are accepted.
              Positive values in the northern hemisphere. Default is 0.
    locator   Maidenhead locator of the location. If set, latitude
              and longitude options must not be defined.
    altitude  Real non negative value expressing the height of the observer
              for which the sun altitudes are calculated.
              Expressed in kilometers. Default is 0km (ground level).
    step      Positive integer value representing the interval in seconds
              between two computations. Default is 600 (10 minutes).
    refract   Indicates if the atmospheric refraction is accounted for.
    verbose   Shows legend.
    gnuplot   Path to the gnuplot executable. If empty, default is:
              on Windows platforms [Program Files Directory]\gnuplot\bin\wgnuplot.exe.
              on Linux platforms /usr/bin/gnuplot.
    graph     Path to the png file that will be created -- requires gnuplot
              set to null or true if the image is to be sent to stdout.
    height    height of the png image, in pixels. Default is 400.
    width     width of the png image, in pixels. Default is 745.
Creative Commons License SID monitoring station by Lionel LOUDET is licensed under a
Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License.
Contact the webmaster
Last Update: 04 Apr 2013 Visitors Today:
Apache Web Server PHP
Apache/2.4.25 (Debian)
Valid XHTML + RDFa Valid CSS!
Page generated in 0.325 seconds.