Epact

The epact (epactae, from ἐπακται ἡμεραι (epaktai hēmerai) = added days) used to be described by medieval computists as the age of a phase of the Moon in days on 22 March; in the newer Gregorian calendar, however, the epact is reckoned as the age of the ecclesiastical moon on 1 January. Its principal use is in determining the date of Easter by computistical methods. It varies (usually by 11 days) from year to year, because of the difference between the solar year of 365–366 days and the lunar year of 354–355 days.

Lunar calendar
Epacts can also be used to relate dates in the lunar calendar to dates in the common solar calendar.

Solar and lunar years
A solar calendar year has 365 days (366 days in leap years). A lunar calendar year has 12 lunar months which alternate between 30 and 29 days for a total of 354 days (in leap years, one of the lunar months has a day added; since a lunar year lasts a little over $354 1⁄3$ days, a leap year arises every second or third year rather than every fourth.)

If a solar and lunar year start on the same day, then after one year the start of the solar year is 11 days after the start of the lunar year. These excess days are epacts, and have to be added to the lunar year to complete the solar year; or from the complementary perspective they are added to the day of the solar year to determine the day in the lunar year.

After two years the difference is 22 days, and after 3 years, 33 days. Whenever the epact reaches or exceeds 30 days, an extra (embolismic or intercalary) lunar month is inserted into the lunar calendar, and the epact is reduced by 30 days.

Leap days extend both the solar and lunar year, so they do not affect epact calculations for any other dates.

19-year cycle
The tropical year is slightly shorter than $365 1⁄4$ days, while the synodic month is slightly longer than $29 1⁄2$ days, on average; both are non-integers. This gets corrected in the following way. Nineteen tropical years are deemed to be as long as 235 synodic months (Metonic cycle). A cycle can last 6939 or 6940 full days, depending on whether there are 4 or 5 leap days in this 19-year period.

After 19 years the lunations should fall the same way in the solar years, so the epact should repeat after 19 years. However, 19 × 11 = 209, and this is not an integer multiple of the full cycle of 30 epact numbers (209 modulo 30 = 29, not 0). So after 19 years the epact must be corrected by +1 in order for the cycle to repeat over 19 years. This is the saltus lunae ("leap of the moon"). The sequence number of the year in the 19-year cycle is called the golden number. The extra 209 days fill 7 embolismic months, for a total of 19 × 12 + 7 = 235 lunations.

Lilian (Gregorian) epacts
When the Gregorian calendar reform was instituted in 1582, the lunar cycle previously used with the Julian calendar to complete the calculation of Easter dates was adjusted also, in accordance with a (modification of the) scheme devised by Aloysius Lilius. There were two adjustments to the old lunar cycle:
 * a "solar equation", decrementing the epact by 1, whenever the Gregorian calendar drops a leap day (3 times in 400 calendar years), and
 * a "lunar equation", incrementing the epact by 1, 8 times in 2500 calendar years (7 times after an interval of 300 years, and the 8th time after an interval of 400 years).

The revised "solar equation" was intended to adjust for the Gregorian change in the solar calendar, if they were applied at 1 January of the Julian calendar instead of the Gregorian calendar as the reformers implemented it; moreover the corrections to the solar calendar are leap days, whereas there are 30 epact values for a mean lunar month of $29 1⁄2$ days and a bit: Therefore changing the epact by 1 day does not exactly compensate for a dropped leap day. The "lunar equation" only approximately adjusts for what had (by 1582) been seen after many centuries of recording, that the Moon moves a little faster than the expectation of the rate used for it in the old lunar cycle. By 1582 it was noted (for example, in the text of the bull Inter gravissimas itself) that the new and full moons were at that point occurring "four days and something more" sooner than the old lunar cycle indicated.

History
The discovery of the epact for computing the date of Easter has been attributed to Patriarch Demetrius I of Alexandria, who held office from 189–232. In the year 214 he used the epact to produce an Easter calendar, which has not survived, which used an eight-year luni-solar cycle. A subsequent application of the epact to an Easter calendar, using a sixteen-year cycle, is found in the Paschal Table of Hippolytus, a 112 year list of Easter dates beginning in the year 222 which is inscribed on the side of a statue found in Rome. Augustalis, whose dates had been disputed from the third to the fifth century, computed a laterculus ("little tablet") of Easter dates. As reconstructed, it uses epacts (here the age of the moon on 1 January) and an 84 year luni-solar cycle to compute the dates of Easter using a base date of 213. If we accept Augustalis's earlier dates, his laterculus extends from 213–312 and Augustalis originated the use of epacts to compute the date of Easter.

As early as the fourth century we see Easter computus using the epact and the nineteen-year Metonic cycle in Alexandria, and subsequent computistical tables were influenced by the structure of the Alexandrian calendar. The epact was taken as the age of the Moon on 26 Phamenoth (22 March in the Julian calendar) but that value of the epact also corresponded to the age of the Moon on the last epagomenal day of the preceding year. Thus the epact can be seen as having been established at the beginning of the current year. Subsequent Easter tables, such as those of Bishop Theophilus of Alexandria, which covered 100 years beginning in 380, and of his successor Bishop Cyril, which covered 95 years beginning in 437 discussed the computation of the epact in their introductory texts. Under the influence of Dionysius Exiguus and later, of Bede, the Alexandrian Easter Tables were adopted throughout Europe where they established the convention that the epact was the age of the Moon on 22 March. This Dionysian epact fell into disuse after the introduction of a perpetual calendar based on the golden number, which made the calculation of epacts unnecessary for ordinary computistical calculations.

Two factors led to the creation of three new forms of the epact in the fifteenth and sixteenth centuries. The first was the increasing error of computistical techniques, which led to the introduction of a new Julian epact around 1478, to be used for practical computations of the phase of the Moon for medical or astrological purposes. With the Gregorian reform of the calendar in 1582, two additional epacts came into use. The first was the Lilian epact, developed by Aloisius Lilius as an element of the ecclesiastical computations using the Gregorian calendar. The Lilian epact included corrections for the motions of the Sun and the Moon that broke the fixed relationship between the epact and the golden number. The second new epact was a simple adjustment of the practical Julian epact to account for the ten-day change produced by the Gregorian Calendar.