Bill Pernell

Today is: Thursday, Copernicus 14, 55

The Tranquility Calendar

The Tranquility Calendar was an alternative calendar developed by Jeff Siggins and published in the July 1989 issue of Omni Magazine. Designed to correct some of the inconsistencies of the Gregorian calendar, it uses the 1969 moon landing as its starting point. The calendar has 13 months of 28 days, each named after a famous scientist, a special day each year on the anniversary of the moon landing (called Armstrong Day), and a leap day every four years (Aldrin Day). Neither of the special days has a day of the week or belong to a month.

For more on the Tranquility Calendar read:

I was a big fan of Omni during its publication, and when I read this article back then I was attracted to the idea of a calendar that was based on, as Siggins put it, "a recent, well-documented event" rather than a distant event that's a mixture of oral history and legend. With calendars being the the news at the end of 2012 I was reminded of it, found Scott M Harrison's Tranquility Calendar Home Page, and started playing around with his tranquilityDate.c code.


TranquilityDate.php is a PHP class I created based on Scott M. Harrison's tranquilityDate.c. The logic is almost entirely Harrison's (with some changes resulting from the change from C to PHP). It allows for the calculation and printing of a date on the Tranquility Calendar based on a given date. It has few useful methods and constants for printing Tranquility dates or doing calculations based on the Tranquility Calendar.

Usage is pretty simple. The constructor takes a DateTime object:

require('TranquilityDate.php'); $td = new TranquilityDate(new DateTime('2012-12-20')); echo $td->getDate(); # Prints 'Wednesday, Faraday 13, 44'

If no parameter is given the current time is used:

$default_td = new TranquilityDate(); echo $default_td->getDate(); # Prints 'Thursday, Copernicus 14, 55'

Most of the methods available are fairly straightforward; you can read the code for the complete list. The most useful methods and constants are displayed below:

Useful Methods ($tdate = new TranquilityDate())
Method Purpose Example
$tdate->getDate() Gets string formatted Tranquility Calendar date Thursday, Copernicus 14, 55
$tdate->getDayOfWeek() Gets day of the week (string) on Tranquility Calendar (often different than that on Gregorian Calendar). If date is a special day without a day of the week (e.g. Armstrong Day), returns false. Thursday
$tdate->getMonth() Gets zero-indexed numeric month (integer) on Tranquility Calendar. If date is a special day without a month, returns false. 2
$tdate->getMonthName() Gets name of Tranquility Month (string). If date is a special day without a month, returns false. Copernicus
$tdate->getDay() Gets day of month (integer) on Tranqulity Calendar. If date is a special day, returns day name (string, e.g. 'Armstrong Day') instead. 14
$tdate->getDayOfYear() Gets zero-indexed day of year (integer) on Tranquility Calendar. 70
$tdate->getYear() Gets Tranquility year. Returns false for Moon Landing Day, which does not have a year on the Tranquility Calendar. 55
$tdate->isSpecialDay() Returns true if date is "Armstrong Day," "Aldrin Day," or "Moon Landing Day." bool(false)
Useful Constants
Constant Description Value
TranquilityDate::DAYS_IN_TRANQUILITY_MONTH Number of days in a Tranquility Calendar month. int(28)
TranquilityDate::YEAR_OF_TRANQUILITY Starting CE year for Tranquility Calendar int(1969)
TranquilityDate::ARMSTRONG_DAY Day of Gregorian calendar year for Armstrong Day. int(201)
TranquilityDate::ALDRIN_DAY Day of Gregorian calendar year of Aldrin Day. int(60)

The class could certainly be developed further. I encourage you to do so if you wish; the code is completely open source. I only ask that you maintain all of the authorship and copyright information in the comments at the top.

As it stands the class is suitable for simple operations like creating a Tranquility Calendar page with the current date highlighted (or if it's a special day, the name of the day without a calendar page):

Copernicus 55
F Sa Su M Tu W Th
1 2 3 4 5 6 7
8 9 10 11 12 13 14
15 16 17 18 19 20 21
22 23 24 25 26 27 28

[show the code]

require('TranquilityDate.php'); $td = new TranquilityDate(); if ( $td->isSpecialDay() ) { echo '<div id="tcCalendar">'; echo $td->getDay(); if ( $td->getYear() ) echo " {$td->getYear()}"; echo '</div>'; } else { echo '<table id="tcCalendar">'; echo "\n<caption>{$td->getMonthName()} {$td->getYear()}</caption>\n"; echo '<tr> <th>F</th> <th>Sa</th> <th>Su</th> <th>M</th> <th>Tu</th> <th>W</th> <th>Th</th> </tr>'."\n"; foreach (range(1,28) as $dayOfMonth) { $current = $td->getDay() == $dayOfMonth ? ' class="current"' : ''; if ( ($dayOfMonth - 1) % 7 == 0 ) echo '<tr>'; echo "<td$current>$dayOfMonth</td>\n"; if ($dayOfMonth % 7 == 0) echo '</tr>'; } echo '</table>'; }