Thursday, January 31, 2019

Go Towards the Light | Direction and Time from the Sun

Finding North using primitive means is a frequently discussed outdoor skill. But what about deriving the current time? I hadn't seen this discussed until I came across a chapter in this book: Graves' Bushcraft: Time & Direction. Near the start of the chapter is this description of how the Sun moves:

As you know, the sun crosses the imaginary North-South line (Meridian) every day when it reaches its highest point (Zenith) above the horizon.

Therefore when the sun is at its highest point in the sky it is North or South of you, depending upon your position on the earth's surface, and the sun's position relative to the earth's equator.

For all practical purposes there are twenty-four hours between each sun crossing of your North-South line, or Meridian. During the twenty-four hours the earth will have revolved apparently 360 degrees; therefore it will move 15 degrees for each hour, or one degree in four minutes. This is very convenient to know, because if you know the North or South accurately, you can easily measure off the number of degrees the sun is from the North-South line, and this will give you the number of hours and minutes before, or after noon.

Whoa. I'd always appreciated that for most of the world the Sun doesn't rise due East and it doesn't set due West. But the above description started me thinking about what could be learned from the position of the Sun. After further research I've come to appreciate just how closely mapped our definition of time is to the position of the Sun. In short, with the right math, you can derive one from the other.

You might think, thanks to clocks, compasses and GPSs that such math had been relegated to the history books. But thanks to the popularity of solar power, the need to understand the relationship between the Sun, time and its location is more important than ever. This explains why the most useful resource I found on the topic was provided by a photovoltaics education site, pveducation.org. The site not only includes textual and mathematical descriptions of each of the concept needed to understand solar motion, it also provides useful Adobe Flash Animations for the visual learners among us.

Using the formulas provided by pveducation.org my goal was to write sun-posn, a function that would take in latitude, longitude, timezone offset, day of year and hour of day and return elevation (how many degrees above the horizon the Sun appears) and azimuth (the compass location of the Sun) of the Sun. You can find my code here, and it's little more than a direct translation of the math on pveducation.org.

Here's an example of my code in action; pveducation.org even provides a Sun Position Calculator to check my work.

(define dc-lat  39)
(define dc-lng  -77)
(define dc-tz  -5)

> (sun-posn dc-lat dc-lng dc-tz 30 14.75)
(23.801254841102036 . 217.5548315173389)

This is a clumsy way of saying that on the 30th day of the year (January 30th), at 14.75 hours into the day (2:45pm for us Americans), in Washington, DC (located roughly at 39° latitude, -77° longitude), the Sun will be 23.8° above the horizon, and at a compass heading of 217°. The Sun Position Calculator agrees:

The calculator reports that sunrise is at 7:23am on the 30th. We can verify this by running sun-posn for 7:23am:

> (sun-posn dc-lat dc-lng dc-tz 30 (ts->hh '(7 23)))
(0.08264850607002976 . 113.56028175854931)

Sure enough, the elevation of the Sun at 7:23am is essentially 0 degrees, or at the horizon. This also confirms that the Sun won't rise due East on that day (that is, 90°), but will rise a bit to the South-East, at 113°.

I can see at least two practical uses for the above code. First, I could imagine printing out a table of times, elevations and azimuths to take along on a backpacking trip. For example, suppose we were going to spend a week tramping through Yellowstone this summer. The following cheat sheet would be useful to take along:

(let ((ys-lat 44.560184)
      (ys-lng -110.574387)
      (ys-tz -7)
      (doy 196)) ; July 15th
  (for-each (lambda (hour)
              (show hour ': (sun-posn ys-lat ys-lng ys-tz doy hour)))
            (range 6 22)))

(6 : (-8.122303097656218 . 48.6594818098441))
(7 : (0.5365311423839506 . 59.630576190043215))
(8 : (10.190122452394226 . 69.75648575008768))
(9 : (20.484132757573843 . 79.53460931955374))
(10 : (31.109204936949766 . 89.60026010481032))
(11 : (41.737732404109586 . 100.87684292551032))
(12 : (51.90078297793876 . 114.94012790883353))
(13 : (60.700607362562444 . 134.66593632819524))
(14 : (66.2502736763883 . 163.72111937212864))
(15 : (66.02370239562663 . 198.65009244190927))
(16 : (60.156074073818786 . 226.9987719193552))
(17 : (51.213200952664465 . 246.19564570960074))
(18 : (40.995394625941636 . 259.98702370894995))
(19 : (30.35442787972579 . 271.1370821667874))
(20 : (19.74268533460884 . 281.1568990798108))
(21 : (9.483505182779895 . 290.9408405387917))
(22 : (-0.11225447575466428 . 301.1113559320821))

Whoa - in theory, we'd have daylight from just after 7am until nearly 10pm. With this data in hand, a quick glance at a watch and the Sun would tell you direction. Alternatively, you could use your compass and the Sun to derive the current time. This information on a laminated card would be a weightless, indestructible, battery-free navigation and time telling tool. That's hard to argue with, no? Technically, the elevations and azimuths would vary day to day, but for all practical purposes, a chart showing a single day of the week should be effective.

A second use for this data: to help you buy tickets at an outdoor sporting event. After having baked in the sun at a number of outdoor tennis matches, I can see how invaluable it would be to understand the path of Sun throughout the day. In winter, sunshine may be a precious resource worth coveting. Either way, adding the Sun's position throughout the day to the list of variables you factor into buying tickets is an obvious win.

Next up I plan to repackage the above functionality into an easier to use facility. Stay tuned.

No comments:

Post a Comment