Date Representations

Grand Cycle Notation

Storing and Collating Dates

You may have read elsewhere (see The Calendar of Lorelei) that Calmarendians have an all-numeric date format (Common Symbolic Notation (CSN)) which, for the most part, serves as a useful tool for tabulating and collating (that is, comparing and sorting) dates in a reasonably human readable form comparable to that of Earth's ISO 8601 date format.

Some random SQL code.
by Natasha Moorfield

Now, whereas Calmarendians rarely trouble themselves with dates either deep into the future or far into the past (and certainly not from the era Before Time Zero (BZ)) and have no need (or even any concept of what it means) to store or manipulate such data electronically, we certainly do. We are very much concerned with computerized collation in order that we may, for example, record dates of birth in a database or construct electronic chronologies and timelines.

If, like most Calmarendians, we were to satisfy ourselves with dates only in cycles 1 through 999 (which, incidentally, would almost certainly be fine for our purposes) then the Calmarendian "Common Symbolic Notation" (or "All Numeric") date format would fit the bill perfectly. But, of course, we cannot bring ourselves to settle for such restrictions when a better solution might be found, even if it is solving a problem that does not really exist.

 

Problems and Possible Improvements

Restricted Range

Using the Calmarendian three-digit representation of cycle numbers, there is, going forward, only another 222 cycles until we and the Calmarendians run out of dates. Now, presumably, they will, at some point, move to a four-digit format and all will be well deep into the future: 63,000 seasons into the future, by which time life on Calmarendi might well have been wiped out by Titánia's supernova or else the Calendar of Lorelei will have been overtaken by some other turn of events. But we can, nevertheless, do better than this.

Collation

The easiest way to collate dates, Calmarendian or otherwise, is to convert them into integers which represent a count of days before or since some arbitrary epoch. The drawback is that such numbers are essentially meaningless in most human applications. To store Calmarendian dates in a human useable form we are pretty much constrained to using character strings that closely resemble entries in the calendar. This is not really an issue if we are using a fixed format (such as the Calmarendian all-numeric Common Symbolic Notation) and, importantly, if we do not permit the use of dates before cycle zero. Once we get into the realm of negative numbers, however, dates held as character strings simply will not order properly.

To get around the negative numbers issue, we could just accept the restriction that dates before cycle zero simply cannot be stored. This should be fine; we are, after all, dealing with a culture which holds that such dates do not really exist. But we can do better.

 

The Solution

Grand Cycle Notation

Although they do not often use it, the Calmarendians do have a date format known as Grand Cycle Notation (GCN) in which dates are grouped into periods of 700 cycles - the Grand Cycles: periods after which the pattern of the Calendar of Lorelei begins to repeat. We are going to adopt this format, using a two-digit, zero-padded Grand Cycle number at the beginning of each date and using the cycle-within-grand-cycle number as the three-digit second element of the date but we are going to restrict the dates that can be thus represented to those of Grand Cycles zero and upward.

By way of example, the date Monday, Week 12 of Midwinter 778 in the Current Era will render as 02-078-1-12-1. (Because we feel there is no era ambiguity in this notation, within the specified constraints, we do not propose making era markers a part of this standard.)

Benefits

Our chosen solution of a somewhat restricted Grand Cycle Notation does permit dates up to 4,900 seasons prior to Time Zero and some 480,000 seasons into the future to be collated correctly. It also has the virtue of creating human readable and editable dates that do not require any intermediate processing beyond that of simple arithmetic on the part of a human user. Not having to bother with era markers and working out whether they need to be used simplifies the processing of dates and the formatting of date strings.

Restrictions

The restricted Grand Cycle Notation is not a perfect solution because it is not infinitely extensible, particularly in the Before Time Zero direction. However, from a 1992 Earth perspective compared to that of a Cycle 777 Calmarendian perspective, it is as restrictive as having a Gregorian calendar constrained to dates between c.8,300 BCE and c.477,500 CE but in a world where there was no human activity before c.3,450 BCE.

 

Grand Cycle Notation: Formal Specification

Grand Cycle Notation (GCN) is a thirteen character string broken into five, fixed-length, numeric date elements delimited by dashes (ASCII character 0x2D) thus:

 
GG-CCC-S-WW-D

where:

GG is the two-digit, zero-padded, decimal representation of the Grand Cycle Number. Within the two digit format, all possible values are considered valid so that the Grand Cycle Number can take any value between 0 and 99 inclusive.
CCC is the three digit, zero padded, decimal representation of the Cycle-in-Grand-Cycle Number. It must represent a valid cycle-in-grand-cycle number between 1 and 700 inclusive.
S is the one digit, decimal representation of the Season Number. It must represent a valid season number between 1 and 7 inclusive.
WW is the two digit, zero padded, decimal representation of the Week Number. It must represent a valid week number such that it is between 1 and 50 (inclusive) if the season number is less than or equal to 6 or between 1 and 51 (inclusive) if the season number is equal to 7.
D is the one digit, decimal representation of the Day-of-the-Week number. It must represent a valid day number such that it is between 1 and 7 (inclusive) if the week number is less than or equal to 50 or between 1 and f(CCC) if the week number is equla to 51, where f(CCC) is the number of festival days in Cycle CCC. This is determined by the divisibility of the Cycle number: if it is not divisible by seven then Festival is four days long; if it is divisible by 700, Festival is eight days long; otherwise, Festival is seven days long.
 

As is the case with the Common Symbolic Notation, all dates in periods of Festival are denoted as belonging to week 51 of season 7.

Example 1 Sunday of week 7 of Onset 777 is displayed as 02-077-7-07-7.

Example 2 Festival Four of 777 is displayed as 02-077-7-51-4.

 

Day-in-Season Notation

Overview

Day-in-Season Notation (DSN) is a date notation in which the day and week components of the date are combined into a single day value relative to the start of the season. So, for example, Thursday, Week 18 of Onset 777 would be expressed as 123 Onset 777. Like Grand Cycle Notation it has been devised to solve a real-world problem and we do not, therefore, envisage that it has any formal definition or official use on Calmarendi, though it is always possible, if unlikely, that some organizations or individuals have thought of it for themselves and make private use of it or something similar.

 

Motivation beyond Unreality

The Chronicles (or Advanced Timelines) feature of World Anvil has functionality to create arbitrary calendars. In order to create a calendar that, as near as possible, replicates the broad structure of the Calendar of Lorelei, it has been necessary to reduce the tiers of the calendar from four to three, that is from "cycle - season - week - day" to "cycle - season - day".

 

Formal Specification

Because it is not, essentially, a tool for storing or collating dates electronically, it has a slightly less rigid format specification which is broadly defined thus:

<day><sep><season><sep><cycle>[[<sep>]<era>]

where:

day is the number of the day relative to the start of the season. The day number may, optionally, be zero padded but, if it is, must be padded only to length three. As is the case with GCN and CSN, all days in periods of Festival are treated as being in week 51 of Onset (season 7).
season is the number, name or abbreviated name of the season. Because every season can be uniquely identified by its initial letter, the abbreviated name can be an arbitrary first n letters of its name. So for example, M for Midwinter, Spr for Spring, 7 for Onset are all acceptable.
cycle is the cycle number as would be specified in CSN. As with the day number, the cycle number may, optionally, be zero padded but, if it is, must be padded only to length three.
era is the era marker; one of BZ, BH or CE as would be specified in CSN. For dates before Time Zero, the BZ era marker is mandatory otherwise the era marker is optional and treated as decorative only.
sep is a separator between elements and can be either a dash (ASCII character 0x2D) or space. The separator between the season number and the era marker (if given) can be omitted.
 

Default Specification

Zero Padding

Numbers are unpadded.

 

Season

The season is specified by full name.

 

Era Marker

The era marker is only used where necessary, that is for dates before Time Zero and in any circumstances where dates before and after Time Zero are used in the same context and could be confused, one with the other.

 

Separators

A space is used in preference to a dash. A separator is used between the cycle number and the era marker.

 

Software Implementation

A Python package that can validate and manipulate Calmarendian dates - including converting between various date formats - is being developed. The latest version of the source code can be found on GitHub. It is an open source project: feel free to contribute.

Release versions are available on PyPI to install into your own projects.


Comments

Please Login in order to comment!