Introduction
If you’re a programmer like me, you likely have nerdy interests other than programming, be it sci-fi (I was 9 years old when the original Star Wars was released and I saw it five times in the theater), or, as in my case, time-keeping devices as in pocket watches, grandfather clocks, and sundials.
I’ve owned a pocket watch since I was a kid, a grandfather clock since I moved to California in 1995, and, now that I have my own home and garden, I’ve finally been able to own my very own sundial.
Installing a sundial that actually tells the correct time (well, as correct as possible) is non-trivial and has lots of nerdy details. You can’t just buy a ready-made sundial and expect it to work well. Any accurate sundial has to be custom-made and positioned for a specific location on Earth.
Sundial Primer
There are several different kinds of sundials. The most common are:
- Equatorial.
- Armillary.
- Horizontal.
Equatorial Sundials
An equatorial sundial is perhaps the simplest. It’s a circular dial carved into 24 major slices with each of the 24 hours written on it:
Each hour slice is 15° wide (because 360° ÷ 24 = 15°). To make a sundial with it:
- Insert a stick perpendicular to the dial through the center. (The formal name for the stick is the gnomon, pronounced “no-mahn.”)
- Tilt the gnomon and dial to an angle equal to your latitude where 0° is horizontal. (My latitude near San Francisco is approximately 37.8° north.)
- If you’re in the northern hemisphere, point the gnomon to true north; otherwise, true south.
If you’re thinking of using your iPhone’s Compass app to locate true north, don’t. (More on how to orient a sundial without a compass later.)
You want everything to be like this where we’re looking at the Earth in space from within the ecliptic and the sun to the right:
where:
- The red line shows San Francisco’s latitude of 37.8°.
- The brown line represents “horizontal ground” in San Francisco, i.e., is the tangent line to the Earth’s surface at that point.
- The orange line is the gnomon pointed true north, hence its angle relative to the brown line (ground) is also 37.8°.
- The green disc is the sundial plate.
For now, we’ll ignore the Earth’s axial tilt because it makes things simpler.
Hence, the gnomon is oriented in space to match the direction of Earth’s axis. As the sun appears to move around the center of the gnomon, it will cast a shadow onto the plate. The location of the shadow tells you the apparent solar time where “solar noon” occurs when the sun is at its highest point in the sky.
From the perspective of being on the ground in San Francisco, an equatorial sundial would look like:
where we’re looking at the dial plate edge on. A curious thing about an equatorial sundial is that during the summer (in the northern hemisphere), the gnomon will cast a shadow onto the top of the dial, but in the winter, it will cast a shadow onto the bottom of the dial; and on the equinoxes, it will cast a shadow on both sides.
Armillary Sundials
Armillary sundials are generally more ornate than equatorial sundials, but solve the problem of always being able to tell the time without having to look under the dial plate in winter (in the northern hemisphere). A typical armillary sundial looks like:
In an armillary sundial, the dial plate in an equatorial sundial has been replaced with an equatorial ring where the hours are marked at the same 15° intervals on the inside. The arrow is the gnomon and casts a shadow onto the ring that can easily be read from any position at any time of year.
A curious thing about an armillary sundial is that on the days of the equinoxes, the gnomon casts no shadow since the top side of the equatorial ring casts a shadow over the bottom side because the sun’s path is exactly parallel to the ring.
In some designs, the equatorial ring is only partial since it only has to show daylight hours when the sun is above the horizon. The advantage of such designs is that the gnomon will still cast a shadow on the equinoxes so you can still tell what time it is.
The only other ring that’s necessary is the one in line with the gnomon (the longitudinal ring) to hold both the gnomon and equatorial ring in place. Other rings, if present, typically represent the tropic of cancer and tropic of capricorn, but none are needed for telling time.
Armillary spheres are closely related to armillary sundials except the former are typically even more ornate and used primarily to show various astronomical facets rather than tell time.
Armillary sundials are my favorite kind.
Horizontal Sundials
Horizontal sundials take up less space than armillary sundials, but also solve the problem of always being able to tell the time without having to look under the dial plate in winter (in the northern hemisphere). My horizontal sundial looks like:
Even though armillary sundials are my favorite, I got a horizontal sundial because an armillary sundial would have taken up too much space for the location in my garden.
My sundial was custom-made for my latitude and pedestal diameter by Robert Foster, specifically the Presentation model. It’s solid brass that will develop a patina over time. It includes a custom Latin inscription Tu Lux Mea that means “You are my light.”
While horizontal sundials may look simple, they’re actually more complicated because the shadow cast by the gnomon on an armillary equatorial ring is now being cast instead onto a flat surface. This has the effect making the hour lines no longer at equal 15° intervals. However, you can calculate the adjusted angles for the hour lines.
Given 𝜙 (latitude) = 37.8° and h for a given hour between, say, 1–6pm, you can calculate the angle of the hour line using this equation (with degrees converted into radians first, then back):
\theta = \arctan(\sin(\phi)) \times \tan(h \times 15\degree)
Doing the math yields: 1pm = 9.32°, 2pm = 19.48°, 3pm = 31.5°, 4pm = 46.7°, 5pm = 66.38°, and 6pm = 90°.
The hours between 6–11am are a mirror image of 1–6pm. Noon is, of course, 0°; 6am and 6pm are always 90°.
This has the effect of “squishing” the hours clustered around 12 making reading the time harder.
Horizontal sundials work better the farther away from the equator (higher latitude) they are because the hour lines become more evenly spaced. At a pole, a horizontal sundial would become an equatorial sundial.
For horizontal sundials, a distinction needs to be made regarding the gnomon:
The gnomon is the entire triangular wedge that’s perpendicular to the dial plate; the style is only the upper straight edge of the gnomon. When reading the time, it’s only the straight edge of the shadow cast by the style that matters. Before noon, read the left edge; after noon, read the right.
Additionally, it’s only the style that must point true north and be parallel to the Earth’s axis. (This matters if doing longitudinal corrections — more later.)
Earth’s Axial Tilt and Orbit
In the old days after sundials were invented, but before clocks were, whatever time the sundial indicated was the time. After clocks were invented, however, if you had an accurate clock and a sundial in the same location, as the year progressed, the time indicated by the sundial would vary from being either slow (behind the time indicated by the clock) or fast (ahead of the clock).
As you know, the Earth is tilted on its axis approximately 23.5°. As you also know, the Earth’s orbit is unfortunately not a circle, but slightly elliptical (thanks, Kepler!). As you might suspect, both of these realities affect the time indicated by a sundial and cause a discrepancy over the course of a year.
However, both these effects can be corrected for by using the equation of time:
where:
- The Y-axis is the difference in time between clock time and sundial time in minutes. A negative value means the sundial is slow; a positive value, fast.
- The X-axis is the day of the year (hence 1 = Jan-1 and 365 = Dec-31).
- The blue line is the Earth’s orbital eccentricity contribution to the discrepancy.
- The green line is the Earth’s axial tilt contribution to the discrepancy.
- The red line is the sum of the blue and green lines’ discrepancies yielding the “Equation of Time.”
From this chart, you can see:
- The discrepancy is 0 on exactly four days a year around April 15, June 13, September 1, and December 25.
- The discrepancy can be as much as approximately 16 minutes fast (around November 3) and approximately 14 minutes slow (around February 11).
When sundials were the only time-keeping devices, civilization was a lot simpler without either trains or instantaneous communication, so the discrepancies just didn’t matter.
To use the Equation of Time:
- Read the apparent solar time from a sundial.
- Using the Equation of Time, locate the current day along the X-axis.
- Subtract the corresponding value on the Y-axis from the apparent solar time to yield the correct clock time. (If the value is negative, add its absolute value.)
Some sundial designs have the equation of time chart engraved into them so you can look up the correction on the spot (but it’s not traditional).
Daylight Savings Time
To confound sundial readers even further, daylight savings time (DST) was invented. This means that, for most of the year, a sundial will be 1 hour behind clock time. Hence, when DST is in effect, you need to add 1 hour to the apparent solar time.
It is possible to make a sundial that takes DST into account by either:
- Rotating only the hour labels 1 hour clockwise. The gnomon must continue to point true north (in the northern hemisphere). This would make the sundial right for approximately 8 months of the year rather than only 4; or:
- Have two sets of hour labels: an outer set for standard time and an inner set for DST.
Of course, neither solution is traditional since DST wasn’t a thing back when sundials were the primary time-keeping devices.
Time Zones
Lastly, time zones were invented that designate each of the 24 1000+ mile wide wedges of the Earth have the same clock time ignoring where the sun is in the sky. The only places where solar and clock times equal is at the longitude of the central meridian of each time zone. To calculate such a longitude where Z is your time zone offset:
\lambda = Z \times 15\degree
Hence for my location in California in the Pacific Time Zone, λ = –8 × 15° = –120°. That’s approximately in Groveland, California on the way to Yosemite.
For every degree east of a time zone’s central meridian, a sundial will be ahead of clock time by 4 minutes (because 24 hours × 60 minutes = 1440 minutes ÷ 360° = 4 minutes); for every degree west, behind by 4 minutes. Hence for me at approximately –122.2°, my sundial is nearly 9 minutes behind.
The convention for longitude is that you can express it either as (1) a decimal number where negative values are west of the Prime Meridian, positives are east; or (2) a positive triple of degrees-minutes-seconds numbers with either “W” (west) or “E” (east) explicitly appended, e.g., 122°12’2″W. The same is true for latitude but with negative values south of the equator.
It is possible to make a sundial that takes longitude into account by either:
- Similarly to taking DST into account, rotate only the hour lines and labels on the dial plate (clockwise for east of a meridian or counter-clockwise for west); or:
- Tilt the dial plate so that it’s parallel to the tangent line of Earth’s surface at the meridian and rotate the plate so the gnomon again points at true north.
To illustrate the second option (where we’re looking north from the south pole and the curvature of the Earth has been greatly exaggerated for the distance between the cities):
My sundial’s west edge would need to be tilted up by angle T so that its plate is parallel to one in Groveland. That can be calculated with the equation (again, with degrees converted into radians first, then back):
T = sin(\lambda_{diff}) \times cos(\phi)
where λdiff\lambda_{diff}
(the difference in longitude between my location and the meridian) = 2.2 (because 122.2° – 120° = 2.2°) and 𝜙 (latitude) = 37.8°. Doing the math yields T = 1.76°. To convert that into a distance, multiply by my sundial’s diameter of 9.5″ to get T” = .288″.
My sundial would also need to be rotated counter-clockwise to compensate for the tilt so that the style once again points true north:
In (a), we’re looking down on the gnomon from directly above before the plate has been tilted. In (b), the west edge of the plate has been tilted up, but this causes the style no longer to point true north. To compensate, the plate must be rotated counter-clockwise by angle R to yield (c). That angle can be calculated with the equation:
R = sin(\lambda_{diff}) \times sin(\phi)
Doing the math yields R = 1.35°. To convert that into a distance, again multiply by my sundial’s diameter of 9.5″ to get R” = .244″.
Orienting a Sundial without a Compass
As I mentioned, it’s not a good idea to orient a sundial using your iPhone’s Compass app. To orient a sundial without a compass, you can point the gnomon’s shadow at 12 exactly at just the right clock time by taking both the equation of time and the longitude of the sundial into account and calculating.
While I could have used a spreadsheet, being a programmer, I wrote a program in C to do the calculations (of course I did):
#include <math.h>
#include <stdbool.h>
#include <stdio.h>
#include <time.h>
double calc_eot_min( unsigned year, unsigned day_of_year ) { // See https://en.wikipedia.org/wiki/Equation_of_time double const D = 6.24004077 + 0.01720197 * (365.25 * (year - 2000) + day_of_year); double const orbit = -7.659 * sin( D ); double const tilt = 9.863 * sin( 2 * D + 3.5932 ); return orbit + tilt;
} double calc_long_min( double sundial_long ) { double const central_long = round( sundial_long / 15 ) * 15; return (sundial_long - central_long) * 4;
} void print_sundial_time( unsigned month, unsigned day_of_month, bool is_dst, unsigned solar_hour, double eot_min, double long_min ) { unsigned clock_hour = solar_hour + is_dst; int clock_min = round( -(long_min + eot_min) ); if ( clock_min < 0 ) { --clock_hour; clock_min += 60; } printf( "%2u/%02u %02u:00 %+d %+6.2f %+6.2f %02u:%02d\n", month, day_of_month, solar_hour, is_dst, - eot_min, - long_min, clock_hour, clock_min );
} int main() { double const sundial_long = -122.2006; time_t const now = time( /*tloc=*/NULL ); struct tm const *const tm = localtime( &now ); print_sundial_time( tm->tm_mon + 1, // month of year (0 - 11) tm->tm_mday, // day of month (1 - 31) tm->tm_isdst, 12, calc_eot_min( tm->tm_year + 1900, tm->tm_yday ), calc_long_min( sundial_long ) );
}
When executed, the program prints a line of output like:
7/25 12:00 +1 +6.39 +8.80 13:15
where:
- +1 is for one additional hour since DST is in effect in July.
- +6.39 is the equation of time correction in minutes (which is the negative of the value from the chart).
- +8.8 is the longitude correction in minutes.
- Their sum is the total correction added to 12:00 to yield 13:15.
In English, the output means: On July 25, when the gnomon’s shadow is at 12 exactly, it is actually 1:15pm. Hence, if at 1:15pm you orient the gnomon so its shadow is pointing at 12, it will be pointing at true north.
If you’ve understood the equations thus far, the C program is a straightforward coding of them. Even if you don’t know C, you should be able to understand the code. The only initial condition the program needs is the sundial’s longitude.
The program should ideally accept the sundial’s longitude as a command-line argument and perhaps an option to specify a date other that the current one, but such things are left as exercises for the reader.
If you’re not inclined to use either a spreadsheet or program, I found this SunAngle online tool. If you input the same values I’ve been using (for time basis, select Solar time) and click calculate, it outputs the same answer for clock time (so I’m confident my program is correct).
Confusingly, that online tool outputs the equation of time in hours rather than in minutes as is conventional (6.39 ÷ 60 = .11).
Side note: that tool must have been around for a long time since its FAQ includes a question about a Palm OS version.
Once the gnomon is oriented correctly, the tilt and rotation adjustments due to its longitude can be done.
Miscellaneous
At low latitudes (including the equator) where horizontal sundials don’t work as well, you can use a vertical sundial mounted on a south facing wall (in the northern hemisphere), ideally facing true south, but, if not, the hour lines and labels can be skewed to compensate.
Sundials also work in the southern hemisphere, of course, but the direction of their hours is reversed, i.e., counter-clockwise.
If you’ve ever wondered why clockwise is, well, clockwise (turns to the right at the top), there is a likely answer.
TL;DR: 68% of the land on Earth is in the northern hemisphere (77% if you discount Antarctica), so most humans (87%) have lived there, including clock-makers. It therefore should come as no surprise that they made clocks whose hands turn in the same direction as gnomon shadows in the northern hemisphere.
Any sundial would “work” at either the north or south pole, but asking “What time is it?” at a pole is a nonsensical question.
Conclusion
I hope you got something out of my nerdy descent into the fiddly (but interesting) details of sundials.