yantra/patha/ss-ahargana.js
अहर्गण and the lords: the Sūrya-Siddhānta's own day-count from a lunisolar date, and the lords of
199 lines · 0 exports
The header, as the file states it
What it loads
What it exports
SS verses named in the header
none in the registry
The channels it runs in
Every function, what it calls, who calls it
18 top-level functions read from the source; the doc line is the comment above each; calls and callers are resolved across the registry’s modules by name. Line numbers are the file’s at engine 3f94072.
1.48-1.50: the civil days since creation, at midnight at Laṅkā, from the years gone since creation, the lunar months gone since Caitra śukla, and the tithis gone in the current month. Every division keeps the quotient ("labdha").
The text's count is a mean count: the tithis are true, the kṣaya and adhimāsa quotients mean. A reckoner checks it by the weekday (1.51 read backwards) [reading: the standard practice; the text gives the lord, not the check]: the day within ±span of the count, `monthShift` months on (−1 when the mean adhimāsa of 1.49 has already counted the year's adhika month and the true one is still to come), w
The same from Kali years gone (years since the Kali epoch).
The exact civil day (Kali day number) of a lunisolar date, by the true calendar `P` (panchanga.js, passed in): the day at whose start (midnight at Laṅkā, as 1.50 counts) the given true month (name, adhika or not) and tithi are current, in the year whose nija Caitra began `kaliYearsGone` years after the Kali epoch. The text's count (1.48-1.50) is the first guess; its own offsets (0, ±1, a month eit
1.51-1.52: the lords from a day-count since creation (BigInt or number).
The lords for a day counted from the Kali epoch (kala-dvara's day numbers).
12.78-79 sequences, each as the next lord's step from the current one.
12.79: the lord of horā h (0 = the first, at sunrise) of a day whose lord is `dayLord`: downward one a horā.
The horā running at t (days since the Kali epoch) on civil day N, given that day's sunrise and the next: equal horās of the ahorātra (24 from sunrise) [reading — the text does not say equal or unequal], or "unequal": twelve of the day and twelve of the night (needs opts.sunset) [unverified].
The Meṣa saṅkrānti nearest the mean one of Kali year k (k mean years after the epoch, 14.10) and the new moon before it: the start of the month that holds it, Caitra.
The lunisolar year whose nija Caitra begins k Kali years gone (k = Kali years gone at the year's start), by the true calendar P (panchanga.js, passed in, as exactDay takes it): { k, shakaGone, vikramaGone, start, end, mesha, yearStartRule, months, sankrantis }. Months are amānta, new moon to new moon, each named by P.nameMonth from the saṅkrāntis inside it (adhika, kṣaya); a 13th month is an adhik
The year of yearOfKali that holds the instant t (start ≤ t < end).