Module calendrica-akan
Akan day-name calendar.
A day name is a pair {prefix, stem} of two concurrent cycles; the pairs repeat every 42 days (the adaduanan).
prefix(1..6): the day of the six-day cycle, the nnanson.stem(1..7): the day of the seven-day week, the nnawɔtwe, which follows the Gregorian week: 1 Wednesday, 2 Thursday, 3 Friday, 4 Saturday, 5 Sunday, 6 Monday, 7 Tuesday.
Both are numbers; names are left to the caller. Ported from “Calendrical Calculations” (4th edition) by Nachum Dershowitz and Edward M. Reingold. Original Lisp code (CALENDRICA 4.0) is Apache 2.0 licensed.
Info:
- Release: 0.2 2026-10-13
Functions
| akan_name_from_fixed (date) | Akan day name for fixed date. |
| akan_day_name (n) | The n-th name of the 42-day Akan cycle. |
| akan_name_difference (a_name1, a_name2) | Days from a_name1 to the next occurrence of a_name2 in the Akan cycle. |
| akan_day_name_on_or_before (name, date) | Latest fixed date on or before date with the given Akan name. |
Functions
- akan_name_from_fixed (date)
-
Akan day name for fixed
date.Parameters:
- date number Fixed date.
Returns:
-
table
{prefix, stem}: the day of the nnanson (1..6) and of
the nnawɔtwe (1..7, 1 = Wednesday).
- akan_day_name (n)
-
The n-th name of the 42-day Akan cycle.
Parameters:
- n number Position in cycle.
Returns:
-
table
{prefix, stem}
- akan_name_difference (a_name1, a_name2)
-
Days from
a_name1to the next occurrence ofa_name2in the Akan cycle.Parameters:
Returns:
-
number
Count (1..42).
- akan_day_name_on_or_before (name, date)
-
Latest fixed date on or before
datewith the given Akanname.Parameters:
- name table Akan name {prefix, stem}.
- date number Fixed date.
Returns:
-
number
Fixed date.