@zodiacs/engine 0.1.1-rc.14 → 0.1.1-rc.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +797 -6
- package/LICENSING.md +354 -21
- package/NOTICE +166 -9
- package/README.md +327 -84
- package/dist/api-VOW6Umy5.d.ts +197 -0
- package/dist/calc.d.ts +279 -0
- package/dist/calc.js +853 -0
- package/dist/{chunk-NAJ735VN.js → chunk-2OWGBT3O.js} +1 -1
- package/dist/{chunk-4OSOCZY2.js → chunk-4NV4ZEFZ.js} +21 -6
- package/dist/chunk-A3U2ZS2W.js +29 -0
- package/dist/chunk-I7O5EGFV.js +25 -0
- package/dist/chunk-KFTJMMG7.js +61 -0
- package/dist/chunk-KHBLFXFG.js +227 -0
- package/dist/chunk-L6ZHWJZ6.js +355 -0
- package/dist/chunk-N4B5JNMA.js +473 -0
- package/dist/chunk-O3NJRGJ2.js +56 -0
- package/dist/{chunk-RETEVD4F.js → chunk-WOU7JVD3.js} +293 -154
- package/dist/crossings.d.ts +1 -1
- package/dist/deltat.d.ts +8 -8
- package/dist/geo.d.ts +137 -8
- package/dist/geo.js +28 -166
- package/dist/houses-extra.d.ts +81 -0
- package/dist/houses-extra.js +337 -0
- package/dist/houses-q1O2GGp4.d.ts +128 -0
- package/dist/index.d.ts +8 -201
- package/dist/index.js +38 -315
- package/dist/internal-math-CmJ9xtaW.d.ts +160 -0
- package/dist/internal-math.d.ts +3 -2
- package/dist/internal-math.js +2 -2
- package/dist/internal.d.ts +2 -1
- package/dist/internal.js +4 -4
- package/dist/receipt.d.ts +74 -29
- package/dist/receipt.js +194 -33
- package/dist/rulers-9wljfVaO.d.ts +10 -0
- package/dist/sky.d.ts +158 -0
- package/dist/sky.js +377 -0
- package/dist/techniques.d.ts +410 -0
- package/dist/techniques.js +830 -0
- package/dist/timing.d.ts +473 -0
- package/dist/timing.js +904 -0
- package/dist/{types-CeafogFp.d.ts → types-B4MCoCCS.d.ts} +35 -4
- package/dist/tzdb-2025c-00-6GVG6RYL.js +6 -0
- package/dist/tzdb-2025c-01-CEYMG3LE.js +6 -0
- package/dist/tzdb-2025c-02-NWQJCVUU.js +6 -0
- package/dist/tzdb-2025c-03-PLHP6VH4.js +6 -0
- package/dist/tzdb-2025c-04-MEKUJA6M.js +6 -0
- package/dist/tzdb-2025c-05-3K5YKZBL.js +6 -0
- package/dist/tzdb-2025c-06-L2VV5XJV.js +6 -0
- package/dist/tzdb-2025c-07-H3GLGJGY.js +6 -0
- package/dist/tzdb-2025c-08-DA7QQIGD.js +6 -0
- package/dist/tzdb-2025c-09-MTXIO3QL.js +6 -0
- package/dist/tzdb-2025c-10-ASL4UW5C.js +6 -0
- package/dist/tzdb-2025c-11-EQEOANYB.js +6 -0
- package/dist/tzdb-2025c-12-NKCCXJ5G.js +6 -0
- package/dist/tzdb-2025c-13-DYTF3UC7.js +6 -0
- package/dist/tzdb-2025c-14-C25H45R5.js +6 -0
- package/dist/tzdb-2025c-15-7OYYZWRY.js +6 -0
- package/dist/vedic.d.ts +393 -0
- package/dist/vedic.js +930 -0
- package/dist/window.d.ts +178 -0
- package/dist/window.js +961 -0
- package/package.json +31 -3
- package/dist/chunk-GFT24GFR.js +0 -25
- package/dist/internal-math-BE2hcSHd.d.ts +0 -271
package/README.md
CHANGED
|
@@ -2,18 +2,25 @@
|
|
|
2
2
|
|
|
3
3
|
Pure TypeScript astrology calculations for browsers and Node.js. The package
|
|
4
4
|
computes tropical planetary positions, natal charts, transit snapshots,
|
|
5
|
-
synastry, secondary progressions, Moon phase, and Saturn-return seasons
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
5
|
+
synastry, secondary progressions, Moon phase, and Saturn-return seasons, and,
|
|
6
|
+
in separate entries, one calculation API over frames, centers and
|
|
7
|
+
corrections with bounds and receipts, birth-time windows, house positions and
|
|
8
|
+
cusp speeds, rise, set and transit times and planetary hours, returns and
|
|
9
|
+
relationship charts, Hellenistic timing techniques, and sidereal positions
|
|
10
|
+
and Jyotish techniques. Its calculations are synchronous; only loading a zone's
|
|
11
|
+
history before 1970 (`prepareLocalTime`) and the GeoNames client, both in
|
|
12
|
+
`@zodiacs/engine/geo`, are asynchronous. It is ESM-only, has no import-time
|
|
13
|
+
side effects, and performs no network request from its core entry point. Its
|
|
14
|
+
one runtime side effect is the ΔT it installs in astronomy-engine (see Time
|
|
15
|
+
below).
|
|
16
|
+
|
|
17
|
+
**Release candidate: 0.1.1-rc.16.** Public npm lookups for this package returned
|
|
11
18
|
404 on 2026-09-26. The expansion release remains held for review and operator
|
|
12
19
|
publication authority. Install the exact candidate tarball supplied with the
|
|
13
20
|
review, retaining its SHA-256 receipt:
|
|
14
21
|
|
|
15
22
|
```sh
|
|
16
|
-
pnpm add ./zodiacs-engine-0.1.1-rc.
|
|
23
|
+
pnpm add ./zodiacs-engine-0.1.1-rc.16.tgz
|
|
17
24
|
```
|
|
18
25
|
|
|
19
26
|
The package runs in browsers through a bundler, and in Node.js 20.19.0 or a
|
|
@@ -28,7 +35,7 @@ themselves and are not affected.
|
|
|
28
35
|
|
|
29
36
|
From a source checkout, run `npm ci` and `npm run build`, then
|
|
30
37
|
`npm pack --ignore-scripts`. Test the packed file in a clean consumer using
|
|
31
|
-
`npm run consumer:smoke -- /absolute/path/to/zodiacs-engine-0.1.1-rc.
|
|
38
|
+
`npm run consumer:smoke -- /absolute/path/to/zodiacs-engine-0.1.1-rc.16.tgz`.
|
|
32
39
|
The smoke check
|
|
33
40
|
downloads the artifact's public dependencies and TypeScript 5.9.3; its output
|
|
34
41
|
records the artifact hash and runtime, and it removes its temporary consumer
|
|
@@ -57,19 +64,26 @@ dependencies afresh with `npm ci` and takes nothing from the checkout's
|
|
|
57
64
|
needs merge commits: a squash or rebase merge drops the source commits it
|
|
58
65
|
checks against, and the check then fails.
|
|
59
66
|
|
|
60
|
-
This candidate
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
67
|
+
This candidate brings five opt-in entry points onto rc.15:
|
|
68
|
+
`@zodiacs/engine/calc`, one calculation API over eight frames, four centers
|
|
69
|
+
and three corrections, with speeds, bounds and receipts; `/window`, birth-time
|
|
70
|
+
window partitions; `/techniques`, returns, composite and Davison charts, the
|
|
71
|
+
void-of-course Moon, aspect patterns, dignities and Moon signs; `/houses`,
|
|
72
|
+
house positions of bodies with latitude, co-ascendants and cusp speeds; and
|
|
73
|
+
`/sky`, rise, set, transit and planetary hours. `@zodiacs/engine/timing`
|
|
74
|
+
gains planetary returns. The root imports none of them. The nutation is now
|
|
75
|
+
the full IAU 2000B series, which the engine evaluates itself (see Nutation):
|
|
76
|
+
every longitude moves from rc.15's by the change in Δψ, up to 0.2701″ from
|
|
77
|
+
1800 to 2200, and the angles and cusps by the change in the sidereal time and
|
|
78
|
+
the true obliquity, up to 0.8003″ over 9,697 synthetic charts at places up to
|
|
79
|
+
60.17° N, and more toward the polar circle. Receipts gain a
|
|
80
|
+
conventions set that names the nutation; rc.15's receipts stay readable. As
|
|
81
|
+
in rc.15, a chart's instant is read on a time basis: from 1972 to 2027-10-02
|
|
82
|
+
as UTC, with TT from the leap seconds and UT1 from IERS UT1 − UTC, and
|
|
83
|
+
otherwise as UT1 with the ΔT model, or on UT1 or TT when `timeScale` says so
|
|
84
|
+
(see Time). The ephemeris is still astronomy-engine 2.1.19. See CHANGELOG.md
|
|
85
|
+
for the release history and `docs/evidence/rc16-20260930/` for this
|
|
86
|
+
candidate's checks. Site adoption is reviewed separately.
|
|
73
87
|
|
|
74
88
|
## Natal chart in 10 lines
|
|
75
89
|
|
|
@@ -106,6 +120,9 @@ const birth = resolveBirth({
|
|
|
106
120
|
const chart = natalChart(birth);
|
|
107
121
|
```
|
|
108
122
|
|
|
123
|
+
For a date before 1970, first `await prepareLocalTime(date, timeZone)`, also
|
|
124
|
+
from `@zodiacs/engine/geo`: it loads the zone's history (see Time).
|
|
125
|
+
|
|
109
126
|
## Compatibility
|
|
110
127
|
|
|
111
128
|
```ts
|
|
@@ -156,14 +173,53 @@ for (const aspect of today.aspects) {
|
|
|
156
173
|
body crosses a longitude, and `searchLongitudeCrossings` does the same under
|
|
157
174
|
a sample budget. `@zodiacs/engine/crossings` provides the same solver for a
|
|
158
175
|
longitude function of your own, without the ephemeris.
|
|
159
|
-
- `@zodiacs/engine/geo` provides IANA local-time resolution
|
|
160
|
-
separately hosted, sharded GeoNames index.
|
|
176
|
+
- `@zodiacs/engine/geo` provides IANA local-time resolution, Julian calendar
|
|
177
|
+
dates and a client for a separately hosted, sharded GeoNames index.
|
|
178
|
+
- `@zodiacs/engine/techniques` provides solar and lunar returns, composite and
|
|
179
|
+
Davison charts, the void-of-course Moon, aspect patterns, essential
|
|
180
|
+
dignities and the Moon signs possible over a date (see `docs/techniques.md`).
|
|
181
|
+
- `@zodiacs/engine/timing` provides profections, firdaria, zodiacal releasing
|
|
182
|
+
and solar arc directions (see `docs/timing-hellenistic.md`), and planetary
|
|
183
|
+
returns (see `docs/houses.md`).
|
|
184
|
+
- `@zodiacs/engine/houses` provides the house position of a body with ecliptic
|
|
185
|
+
latitude in each house system, the co-ascendants and the polar ascendant,
|
|
186
|
+
and the speeds of the cusps and the angles (see `docs/houses.md`). It
|
|
187
|
+
imports no ephemeris and no module of the root entry.
|
|
188
|
+
- `@zodiacs/engine/vedic` provides the sidereal zodiac: ayanamsas, sidereal
|
|
189
|
+
charts, nakshatras, vargas, KP sub-lords and dashas (see `docs/vedic.md`).
|
|
190
|
+
- `@zodiacs/engine/sky` provides rise, set and transit times for an observer
|
|
191
|
+
and planetary hours (see `docs/sky.md`).
|
|
192
|
+
- `@zodiacs/engine/window` partitions a birth-time window into cells within
|
|
193
|
+
which the chart's signs, houses and aspects are constant (see *Birth-time
|
|
194
|
+
windows*).
|
|
195
|
+
|
|
196
|
+
### Uniform calculation API
|
|
197
|
+
|
|
198
|
+
`@zodiacs/engine/calc` offers `calc`, `houses`, `events` and `chart` with one
|
|
199
|
+
vocabulary: instants as ISO strings, Dates or `{ jd, scale: "UTC" | "UT1" | "TT" }`
|
|
200
|
+
on the engine's time basis, as `positions()` reads them;
|
|
201
|
+
eight frames (the ecliptic or the equator; true or mean of date, J2000.0 or
|
|
202
|
+
the ICRS); geocentric, heliocentric, barycentric and topocentric centers; and
|
|
203
|
+
apparent, astrometric or geometric positions with distances and speeds.
|
|
204
|
+
Results carry bounds and a receipt of convention ids. A measured bound is the
|
|
205
|
+
largest difference from JPL Horizons on 32 instants from 1802 to 2188: a
|
|
206
|
+
sample maximum, not a limit. An estimated bound names what it rests on. What
|
|
207
|
+
this version does not compute comes back as a typed refusal, such as the
|
|
208
|
+
sidereal zodiac, or an instant whose UT1 or TT is outside 1800 to 2200: there
|
|
209
|
+
calc has no comparison to take a bound from, while the root entry's functions
|
|
210
|
+
still compute such an instant and flag it `outside-reference-span`. With
|
|
211
|
+
every default, `calc({ body, time })` is the position `positions()` gives, to
|
|
212
|
+
the bit. The root entry loads none of it. The reference, with the Swiss Ephemeris flag
|
|
213
|
+
mapping and the measured accuracy, is
|
|
214
|
+
[docs/calc.md](https://github.com/zodiacs-org/engine/blob/main/docs/calc.md).
|
|
161
215
|
|
|
162
216
|
Returned longitudes use degrees in `[0, 360)` and positions include sign and degree
|
|
163
217
|
annotations. Charts use the tropical ecliptic of date. Planetary positions are
|
|
164
218
|
geocentric and corrected for light time and aberration, but not for the Sun's
|
|
165
|
-
gravitational deflection; the Moon's series carries neither correction.
|
|
166
|
-
|
|
219
|
+
gravitational deflection; the Moon's series carries neither correction. The
|
|
220
|
+
chart functions do not calculate topocentric parallax; `@zodiacs/engine/calc`
|
|
221
|
+
gives topocentric positions (`center: { topocentric }`), and
|
|
222
|
+
`@zodiacs/engine/sky` finds rise and set for a topocentric observer.
|
|
167
223
|
|
|
168
224
|
Positions have been compared with an independent ephemeris from 1800-01-01T00:00Z
|
|
169
225
|
up to 2200-01-01T00:00Z, exported as `REFERENCE_SPAN`. A chart outside that span
|
|
@@ -329,24 +385,27 @@ Out-of-bounds means strictly `abs(dec) > trueObliquity`, without an
|
|
|
329
385
|
uncertainty allowance. Each row also carries `boundMarginArcsec`, the signed
|
|
330
386
|
margin `(abs(dec) − trueObliquity) × 3600`: positive beyond the bound, negative
|
|
331
387
|
inside it. For every row but the exempt Sun below, `outOfBounds` is exactly
|
|
332
|
-
`boundMarginArcsec > 0`. In `chartDeclinations`, `trueObliquity` is
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
388
|
+
`boundMarginArcsec > 0`. In `chartDeclinations`, `trueObliquity` is the
|
|
389
|
+
engine's true obliquity of date at the chart instant on the chart's clock: the
|
|
390
|
+
IAU 2006 mean obliquity plus the IAU 2000B nutation in obliquity, all 77 terms
|
|
391
|
+
(see *Nutation*). It equals ERFA's `obl06` plus `nut00b` within the tests'
|
|
392
|
+
tolerances (1e-9″ and 1e-10″), and at 20,000 instants from 1850 to 2150 it was
|
|
393
|
+
within 1.63 mas of `obl06` plus `nut06a` (IAU 2000A), where astronomy-engine's
|
|
394
|
+
five-term value, used until this change, was up to 85.6 mas from both. The
|
|
395
|
+
pure functions use the obliquity they are given.
|
|
338
396
|
|
|
339
397
|
The flag describes the ephemeris's position, and it agrees with the real sky
|
|
340
398
|
only where the margin exceeds the ephemeris's error in declination. Against
|
|
341
|
-
JPL's DE440s at those 20,000 instants, the largest declination errors were
|
|
399
|
+
JPL's DE440s at those 20,000 instants, the largest declination errors were,
|
|
400
|
+
rounded up (`docs/evidence/nutation-2026-09-29/results/declination-truth.json`):
|
|
342
401
|
|
|
343
402
|
| Body | Largest error | Body | Largest error |
|
|
344
403
|
| --- | ---: | --- | ---: |
|
|
345
404
|
| Sun | 2.7″ | Jupiter | 16.1″ |
|
|
346
405
|
| Moon | 3.4″ | Saturn | 21.6″ |
|
|
347
406
|
| Mercury | 12.2″ | Uranus | 19.3″ |
|
|
348
|
-
| Venus | 14.
|
|
349
|
-
| Mars | 14.
|
|
407
|
+
| Venus | 14.8″ | Neptune | 15.5″ |
|
|
408
|
+
| Mars | 14.6″ | Pluto | 4.6″ |
|
|
350
409
|
|
|
351
410
|
These are sample maxima, not bounds, and they grow outside `REFERENCE_SPAN`.
|
|
352
411
|
Within them the flag can be wrong either way: at 2022-10-22T08:11:10.756Z the
|
|
@@ -396,7 +455,11 @@ not include this analysis; the result states that scope explicitly.
|
|
|
396
455
|
`houseSystem` takes one of thirteen systems. Each is the definition Swiss
|
|
397
456
|
Ephemeris uses, and every one agrees with Swiss's `swe_houses_armc` to within
|
|
398
457
|
0.0001″ given the same sidereal time, latitude and obliquity (Placidus, which
|
|
399
|
-
iterates, to 0.01″).
|
|
458
|
+
iterates, to 0.01″). End to end, from an instant read as UT1 as Swiss reads
|
|
459
|
+
it, every system was within 0.055″ of Swiss's `swe_houses_ex` from 1850 to
|
|
460
|
+
2049, on a ladder of latitudes from 55° to 66.6° and on 3,000 draws within 66°
|
|
461
|
+
of the equator (`docs/evidence/nutation-2026-09-29/results/ladder.json`);
|
|
462
|
+
outside those years Swiss uses a long-term sidereal time of its own.
|
|
400
463
|
|
|
401
464
|
| `houseSystem` | System | Cusps |
|
|
402
465
|
| --- | --- | --- |
|
|
@@ -426,6 +489,11 @@ meridian, as in Swiss Ephemeris. When the birth time is unknown, pass a
|
|
|
426
489
|
conventional UTC instant with `timeKnown: false`; angles and houses remain
|
|
427
490
|
absent and the chart carries the `no-time` flag.
|
|
428
491
|
|
|
492
|
+
`@zodiacs/engine/houses` places a body with ecliptic latitude in any of these
|
|
493
|
+
systems, as Swiss Ephemeris's `swe_house_pos` defines the position, and gives
|
|
494
|
+
the co-ascendants, the polar ascendant and the speeds of the cusps and angles
|
|
495
|
+
(`docs/houses.md`).
|
|
496
|
+
|
|
429
497
|
### Points
|
|
430
498
|
|
|
431
499
|
`chartPoints(natal)` takes a birth or a chart and returns `{ sect, points }`.
|
|
@@ -442,9 +510,11 @@ Each point has a longitude, a latitude, a sign and a degree, like a body.
|
|
|
442
510
|
The mean node and Black Moon Lilith come from the Moon's mean elements: the
|
|
443
511
|
IERS Conventions' fundamental arguments (Simon et al. 1994), with a mean
|
|
444
512
|
inclination of 5.1453964°. The nutation in longitude puts them on the true
|
|
445
|
-
equinox of date, like every other longitude here.
|
|
446
|
-
|
|
447
|
-
|
|
513
|
+
equinox of date, like every other longitude here. At 2,000 instants from 1800
|
|
514
|
+
to 2199 they were within 0.4503″ and 0.4887″ of Swiss Ephemeris's
|
|
515
|
+
`SE_MEAN_NODE` and `SE_MEAN_APOG`
|
|
516
|
+
(`docs/evidence/nutation-2026-09-29/results/swiss.json`). Both carry a speed in
|
|
517
|
+
degrees per day.
|
|
448
518
|
|
|
449
519
|
Every chart gets those three. The Vertex, the East Point, the sect and the
|
|
450
520
|
lots need a birth time and place.
|
|
@@ -473,11 +543,14 @@ slots, accessor slots, non-array iterables and simultaneous `dst-gap`/`dst-fold`
|
|
|
473
543
|
claims reject with a `RangeError` that does not include supplied flag values.
|
|
474
544
|
|
|
475
545
|
`dst-gap`, `dst-fold` and `lmt` remain caller assertions: a UTC instant alone
|
|
476
|
-
cannot verify a historical local-time resolution.
|
|
546
|
+
cannot verify a historical local-time resolution. The geo resolver sets
|
|
547
|
+
`dst-gap` or `dst-fold` for a skipped or repeated wall time of any cause (the
|
|
548
|
+
names are kept; its `jump.cause` gives the cause) and `lmt` when a local mean
|
|
549
|
+
time clock read it. `no-time`,
|
|
477
550
|
`polar-fallback` and `outside-reference-span` may be echoed for compatibility,
|
|
478
551
|
but must agree with the calculation. Set `timeKnown: false` for unknown time; a flag never overrides that
|
|
479
552
|
setting. A fallback assertion requires the actual requested Placidus calculation
|
|
480
|
-
to produce whole-sign houses,
|
|
553
|
+
to produce whole-sign houses, which it does only inside the polar circle.
|
|
481
554
|
|
|
482
555
|
`natalChart` stores only distinct time-resolution assertions in `chart.input.flags`
|
|
483
556
|
and derives result flags once. This is canonical semantic input, not a lossless
|
|
@@ -507,11 +580,13 @@ houses, including in either polar hemisphere. At exact geographic poles no
|
|
|
507
580
|
point physically rises; at ecliptic/horizon coincidence an ascendant is not
|
|
508
581
|
unique. Those degenerate configurations are outside the verified angle scope.
|
|
509
582
|
Near tangencies the selected axis can change by 180 degrees. Placidus uses a
|
|
510
|
-
bounded iteration and
|
|
511
|
-
|
|
583
|
+
bounded iteration and, where it does not settle, bisection on each cusp's
|
|
584
|
+
bracket, which cannot fail outside the polar circle; it never returns the last
|
|
585
|
+
unconverged iterate. Near the polar limit a cusp carries the rounding of asin
|
|
586
|
+
near ±1: up to 6.5e-7° one unit in the last place below it.
|
|
512
587
|
|
|
513
588
|
See [CHANGELOG.md](CHANGELOG.md) for candidate changes. Reference coverage and
|
|
514
|
-
known limits are recorded in the site [platform evidence ledger](https://github.com/
|
|
589
|
+
known limits are recorded in the site [platform evidence ledger](https://github.com/zodiacs-org/site/blob/75ae549c6bcedba67ccce7d467e1b54af0c83070/docs/platform/EVIDENCE.md).
|
|
515
590
|
The date parser's representable range is not a claim of astronomical accuracy
|
|
516
591
|
across that range. Reference cases are finite; broader numerical scope review
|
|
517
592
|
remains a release gate.
|
|
@@ -569,6 +644,121 @@ Invalid input throws `RangeError` before any sampling: an invalid `Date`,
|
|
|
569
644
|
shorter than a millisecond, or a `maxSamples` that is not a positive integer or
|
|
570
645
|
`Infinity`. A non-finite longitude from the ephemeris throws `RangeError` too.
|
|
571
646
|
|
|
647
|
+
### Birth-time windows
|
|
648
|
+
|
|
649
|
+
```ts
|
|
650
|
+
import { birthWindow } from "@zodiacs/engine/window";
|
|
651
|
+
|
|
652
|
+
const result = birthWindow({
|
|
653
|
+
start: "1990-06-15T12:20:00Z",
|
|
654
|
+
end: "1990-06-15T12:40:00Z",
|
|
655
|
+
latitude: 40.7128,
|
|
656
|
+
longitude: -74.006,
|
|
657
|
+
houseSystem: "placidus",
|
|
658
|
+
rounding: { recorded: "1990-06-15T12:30:00Z", minutes: 5 }
|
|
659
|
+
});
|
|
660
|
+
for (const cell of result.cells) console.log(cell.start, cell.share, cell.roundedShare, cell.features.ascendant);
|
|
661
|
+
for (const change of result.switches) console.log(change.at, change.changes);
|
|
662
|
+
```
|
|
663
|
+
|
|
664
|
+
`birthWindow` divides a window of possible birth instants into cells within
|
|
665
|
+
which every discrete feature of the chart is constant: each body's sign and
|
|
666
|
+
house, the signs of the ascendant and the midheaven, the aspects in orb and,
|
|
667
|
+
for Placidus and Koch, whether the houses fall back to whole signs. The
|
|
668
|
+
features are natalChart's: houses are `houseOf` on the chart's cusps, and
|
|
669
|
+
aspects are its five major aspects with their orbs. Each switch gives the
|
|
670
|
+
first millisecond of its new cell and every change at it, from and to. Each
|
|
671
|
+
cell gives its share of the window under a uniform prior and, when `rounding`
|
|
672
|
+
is given, under that rounding model. Nothing else is partitioned: two instants
|
|
673
|
+
in one cell can differ in natalChart's retrograde flags, positions within a
|
|
674
|
+
sign, speeds, orbs and whether they apply, the degrees of angles and cusps,
|
|
675
|
+
declinations and chart points.
|
|
676
|
+
|
|
677
|
+
The window is `start` to `end`, excluding `end`, at most 48 hours; or `at`
|
|
678
|
+
and `minutes`, for `minutes` either side of `at`; or only `rounding`, whose
|
|
679
|
+
unit is then the window. It must lie inside `REFERENCE_SPAN` (1800-01-01 to
|
|
680
|
+
2200-01-01, UTC), where the search's bounds were scanned. `rounding:
|
|
681
|
+
{ recorded, minutes, mode }` says the recorded time was rounded to `minutes`,
|
|
682
|
+
to the nearest (the default) or `"down"`; the true instant is taken as
|
|
683
|
+
uniform over that unit, which must lie inside the window. Resolve local times
|
|
684
|
+
first, for example with `resolveLocalToUtc` from `@zodiacs/engine/geo`.
|
|
685
|
+
|
|
686
|
+
Every value is the engine's own at a millisecond, as natalChart computes it
|
|
687
|
+
on UTC and the engine's time basis (not a pinned `deltaT`). Where the search's
|
|
688
|
+
bounds hold, each cell holds
|
|
689
|
+
natalChart's features at every millisecond in it, and at each switch
|
|
690
|
+
natalChart's value at the millisecond before `at` differs from its value at
|
|
691
|
+
`at` exactly as listed, except inside an interval listed in `unresolved`.
|
|
692
|
+
|
|
693
|
+
The search halves the window until each feature is settled, dropping an
|
|
694
|
+
interval for a feature when enclosures of the quantities it depends on keep
|
|
695
|
+
clear of every threshold and the feature agrees at both ends; single
|
|
696
|
+
milliseconds are compared directly. The enclosures rest on bounds scanned
|
|
697
|
+
from 1800 to 2200: `WINDOW_RATE_BOUNDS` (about twice each body's largest
|
|
698
|
+
rate), the obliquity's rate, and the true node's millisecond jitter, J =
|
|
699
|
+
5e-5·(1 + |T|)° with T in centuries from 2000, at least 3.01 times every
|
|
700
|
+
departure found at 3,000 consecutive milliseconds every five days
|
|
701
|
+
(`docs/evidence/birth-window/rc16/node-jitter.json`). They assume TT and
|
|
702
|
+
UT1 run on continuously. The time basis steps at the ΔT model's seam,
|
|
703
|
+
1940-12-31T18:00:00Z, where ΔT steps from
|
|
704
|
+
24.834 s to 24.820 s; at 1972-01-01, where the leap seconds begin; at each
|
|
705
|
+
leap second, where TT and UT1 step by a second; and where the IERS UT1 table
|
|
706
|
+
ends, 2027-10-02. Each sample installs its own ΔT, so every position and
|
|
707
|
+
angle steps there together: the search finds each step inside the window
|
|
708
|
+
from the engine's own arithmetic, splits at its millisecond and compares
|
|
709
|
+
both sides. Within 1e-8° of the Placidus
|
|
710
|
+
or Koch polar limit, near the RAMCs where their cusps carry the rounding of
|
|
711
|
+
asin near ±1, the house system and the houses are compared at every
|
|
712
|
+
millisecond. A failed check of an enclosure adds `bound-exceeded`, and
|
|
713
|
+
completeness is then not established; a failure that does not show in an
|
|
714
|
+
interval's end-to-end change goes unseen. The method in full is in
|
|
715
|
+
`docs/evidence/birth-window/RESULTS.md`.
|
|
716
|
+
|
|
717
|
+
Near a sign boundary the true node's jitter makes its sign change back and
|
|
718
|
+
forth between milliseconds, for about 4J/|rate| days around an ingress: 1.5
|
|
719
|
+
minutes at the fastest from 1800 to 2200, 4.5 at the median, 2.3 hours at the
|
|
720
|
+
slowest. Every change is reported where the budget of two million evaluated
|
|
721
|
+
instants allows (299 at the ingress of March 2028,
|
|
722
|
+
`docs/evidence/birth-window/rc16/node-flicker.json`). Where the node
|
|
723
|
+
would need more, the stretch is left unresolved, found before any of the
|
|
724
|
+
budget is spent on it: the nodes' signs, and their houses where the houses are
|
|
725
|
+
whole signs, are null there, the interval is listed in `unresolved`, and the
|
|
726
|
+
result carries `node-unresolved`; a change to or from null is its edge, not a
|
|
727
|
+
crossing. 24 of the 294 ingresses from 1800 to 2200 flicker for longer than
|
|
728
|
+
the budget, in 1810, 1842 (two), 1848, 1865 (two), 1882 (two), 1946 (two),
|
|
729
|
+
1981 (two), 2007, 2032 (two), 2049 (two), 2071, 2090 (four), 2113 and 2127
|
|
730
|
+
(`node-ingresses.json`). A true node from the Moon's analytic velocity,
|
|
731
|
+
instead of astronomy-engine's 1.728 s difference, would be smooth and leave
|
|
732
|
+
nothing unresolved; it changes natalChart's node in its last digits and is
|
|
733
|
+
left for a later release.
|
|
734
|
+
|
|
735
|
+
Results carry `verification: "sampled at one-second resolution"`: checked
|
|
736
|
+
against natalChart at every whole second, not proven. On 1,000 preregistered
|
|
737
|
+
random windows (1800 to 2200, all thirteen systems, two thirds at 60° of
|
|
738
|
+
latitude or more), all 24,188 sampled transitions were matched, none missed
|
|
739
|
+
and none extra, and natalChart confirmed every switch at its millisecond
|
|
740
|
+
(`docs/evidence/birth-window/RESULTS.md`); on this candidate's build, after
|
|
741
|
+
the time basis and the nutation, again (`docs/evidence/birth-window/rc16/`).
|
|
742
|
+
|
|
743
|
+
In one thread, a 10-minute window takes about 2 ms, two hours about 20 ms and
|
|
744
|
+
a whole day about 0.23 s (medians, Node.js 22; `timing.json`). A window over a
|
|
745
|
+
node ingress takes from seconds to a few minutes, as the node is compared at
|
|
746
|
+
every millisecond of its flicker (1,950 s around the ingress of 2032-11-25:
|
|
747
|
+
77 s, 18,315 switches); an unresolved stretch costs a fraction of a second.
|
|
748
|
+
Within 1e-8° of the polar limit each passage of a sensitive RAMC adds about
|
|
749
|
+
20 s, and at 89.999999° a 48-hour window takes up to three minutes
|
|
750
|
+
(Alcabitius).
|
|
751
|
+
|
|
752
|
+
Other flags are `polar-fallback`, when a cell uses whole-sign houses in place
|
|
753
|
+
of Placidus or Koch, `bound-exceeded` and `node-unresolved`. Invalid input
|
|
754
|
+
throws `RangeError`, including a window outside `REFERENCE_SPAN` and a
|
|
755
|
+
latitude within 1e-6° of either pole, where the ascendant is undefined or
|
|
756
|
+
turns too fast for the search. A search that would evaluate more than two
|
|
757
|
+
million instants outside the unresolved intervals throws `WindowBudgetError`,
|
|
758
|
+
which is an `Error` and not a `RangeError`. The entry point carries the
|
|
759
|
+
ephemeris and is separate from the root entry point, so that the root does not
|
|
760
|
+
grow.
|
|
761
|
+
|
|
572
762
|
### Resolved instant inputs
|
|
573
763
|
|
|
574
764
|
`DateInput` values passed to the calculation APIs accept a valid `Date`, a finite
|
|
@@ -619,43 +809,72 @@ only within `REFERENCE_SPAN`, and it falls away from it. The Sun's ecliptic
|
|
|
619
809
|
latitude, which in reality stays within about 1.2″ of zero, comes out as
|
|
620
810
|
−9.9″ on 1000-06-01, +13.3″ on 3000-06-01 and −57.5″ on 3998-09-02.
|
|
621
811
|
|
|
622
|
-
Birth settings accept only a `houseSystem` from the thirteen above
|
|
623
|
-
a
|
|
624
|
-
`null` and other unsupported values throw
|
|
625
|
-
coordinates are absent. Latitude and longitude
|
|
626
|
-
within `[-90, 90]` and
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
812
|
+
Birth settings accept only a `houseSystem` from the thirteen above, a boolean
|
|
813
|
+
`timeKnown` and a `timeScale` (see Time). Omitting them defaults to `"whole"`,
|
|
814
|
+
`true` and `"utc"`; explicit `null` and other unsupported values throw
|
|
815
|
+
`RangeError`, including when coordinates are absent. Latitude and longitude
|
|
816
|
+
must be supplied together as finite numbers within `[-90, 90]` and
|
|
817
|
+
`[-180, 180]` respectively.
|
|
818
|
+
|
|
819
|
+
## Time
|
|
820
|
+
|
|
821
|
+
A chart reads the Earth's rotation (sidereal time, the angles) on UT1 and the
|
|
822
|
+
planets on Terrestrial Time (TT). `utc` is on UTC unless `timeScale` says
|
|
823
|
+
`"ut1"` or `"tt"`; any other value throws `RangeError`.
|
|
824
|
+
|
|
825
|
+
- From 1972 to 2027-10-02, TT = UTC + (TAI − UTC) + 32.184 s, with TAI − UTC
|
|
826
|
+
from the IERS leap-second list of 2026-07-06 (it expires 2027-06-28; its
|
|
827
|
+
last value is carried after that), and UT1 = UTC + (UT1 − UTC) from IERS:
|
|
828
|
+
the EOP 20 C04 series in 1972, then `finals2000A.all` of 2026-09-24,
|
|
829
|
+
observed then predicted. ΔT = TT − UT1 is then reported with
|
|
830
|
+
`model: "iers-utc/1"`.
|
|
831
|
+
- Before 1972 and after that table the instant is read as UT1, and TT = UT1 +
|
|
832
|
+
ΔT from the engine's model `zodiacs-deltat/1`: Stephenson, Morrison &
|
|
833
|
+
Hohenkerk 2016 (CC BY 4.0) up to 1941, then USNO and IERS observations,
|
|
834
|
+
Bulletin A's predictions and a damped extrapolation, with a 1-σ band. After
|
|
835
|
+
the table UT1 − UTC is taken as 0 within ±0.9 s.
|
|
836
|
+
- `deltaT` (seconds) in a birth input pins ΔT; the chart reports
|
|
837
|
+
`model: "pinned"`.
|
|
838
|
+
|
|
839
|
+
`chart.deltaT` is `{ seconds, sigma, model, table, tableDigest, segment }`, and
|
|
840
|
+
`chart.timeScale` says how the instant became UT1 and TT (`{ input, basis,
|
|
841
|
+
ut1MinusUtc, leapSeconds }`). `@zodiacs/engine/deltat` exports the model with
|
|
842
|
+
no dependencies. astronomy-engine keeps one ΔT for its whole module; every
|
|
843
|
+
engine call leaves the model installed, and code that calls astronomy-engine
|
|
844
|
+
directly should install it too: `SetDeltaTFunction(deltaT)`.
|
|
845
|
+
|
|
846
|
+
`@zodiacs/engine/geo` reads wall times before 1970 on the tzdb 2025c history
|
|
847
|
+
with backzone, shipped as 16 lazily imported chunks: `prepareLocalTime(date,
|
|
848
|
+
timeZone)` loads the one a zone needs, and a wall time before 1970 throws until
|
|
849
|
+
it has. From 1970 the host's Intl answers. A `longitude` reads a time in a
|
|
850
|
+
zone's local mean time era on the birthplace's own mean time; `calendar:
|
|
851
|
+
"julian"` takes an Old Style date, and `country` adds a note from the country's
|
|
852
|
+
Gregorian adoption. Each resolution names the tzdb version, the transition
|
|
853
|
+
behind the offset and its cause (`dst`, `legal-change` or `date-line`).
|
|
854
|
+
[docs/time.md](docs/time.md) describes every field.
|
|
855
|
+
|
|
856
|
+
## Nutation
|
|
857
|
+
|
|
858
|
+
Longitudes, the sidereal time and the obliquity of date use the IAU 2000B
|
|
859
|
+
nutation (McCarthy & Luzum 2003; IERS Conventions 2003, chapter 5), all 77 of
|
|
860
|
+
its luni-solar terms and its two fixed planetary offsets, which the engine
|
|
861
|
+
evaluates itself (`src/nutation.ts`, transcribed from NOVAS C 3.1). Its Δψ and
|
|
862
|
+
Δε equal ERFA's `nut00b` within 1e-10″ at 101 instants from 1800 to 2200
|
|
863
|
+
(`src/nutation.test.ts`). astronomy-engine's vectors on the J2000 mean equator
|
|
864
|
+
are turned to the ecliptic of date with astronomy-engine's own IAU 2006
|
|
865
|
+
precession (`src/frame.ts`) and that nutation. Measured against ERFA's IAU
|
|
866
|
+
2006/2000A chain applied to the same vectors at 4,001 instants from 1800 to
|
|
867
|
+
2200, that rotation puts a longitude at most 0.003691″ off, and the ascendant
|
|
868
|
+
and midheaven at latitudes within 60° at most 0.006284″ and 0.003358″ off; with
|
|
869
|
+
astronomy-engine's five-term nutation, used until this change, they were up to
|
|
870
|
+
0.2520″, 0.8235″ and 0.2457″ off
|
|
871
|
+
(`docs/evidence/nutation-2026-09-29/results/erfa-frame.json`). The equation of
|
|
872
|
+
the equinoxes adds the two largest IAU 2000 complementary terms (IERS
|
|
873
|
+
Conventions 2010, table 5.2e). The opt-in entries use the same precession,
|
|
874
|
+
nutation and sidereal time: `@zodiacs/engine/calc` for its true-of-date
|
|
875
|
+
frames and its topocentric observer, `@zodiacs/engine/window` for the angles,
|
|
876
|
+
and `@zodiacs/engine/sky` for its apparent places and the observer's
|
|
877
|
+
sidereal angle.
|
|
659
878
|
|
|
660
879
|
## Accuracy and licensing
|
|
661
880
|
|
|
@@ -670,9 +889,13 @@ Table S15 in the package's ΔT module (`@zodiacs/engine/deltat`, which the build
|
|
|
670
889
|
places in a shared chunk under `dist/` that `dist/deltat.js` re-exports) are
|
|
671
890
|
CC BY 4.0, attributed in [NOTICE](NOTICE).
|
|
672
891
|
|
|
673
|
-
The npm package contains no place
|
|
674
|
-
|
|
675
|
-
|
|
892
|
+
The npm package contains no place database. It carries tzdb 2025c's zone
|
|
893
|
+
histories before 1970, the IERS leap-second list, an IERS UT1 − UTC table, a
|
|
894
|
+
table of Gregorian adoption dates from public-domain sources, 22 catalogue
|
|
895
|
+
values for the stars of the Vedic ayanamsas, and the IAU 2000B nutation series
|
|
896
|
+
from NOVAS C 3.1, a US Government work; [NOTICE](NOTICE) records their sources
|
|
897
|
+
and the GeoNames attribution, and downstream users should retain it.
|
|
898
|
+
[LICENSING.md](LICENSING.md) gives the terms of each.
|
|
676
899
|
|
|
677
900
|
## Internal site entry points
|
|
678
901
|
|
|
@@ -680,7 +903,9 @@ which downstream users should retain.
|
|
|
680
903
|
compatibility boundaries for Zodiacs.org. They let the site consume the exact
|
|
681
904
|
package implementation while keeping its scanner-oriented functions and lazy
|
|
682
905
|
bundle boundary intact. They are not covered by semantic-versioning guarantees;
|
|
683
|
-
third-party code must use the documented
|
|
906
|
+
third-party code must use the documented entry points: the root, `/calc`,
|
|
907
|
+
`/geo`, `/houses`, `/sky`, `/techniques`, `/timing`, `/vedic`, `/window`,
|
|
908
|
+
`/receipt`, `/crossings` and `/deltat`.
|
|
684
909
|
|
|
685
910
|
## GeoNames request recovery
|
|
686
911
|
|
|
@@ -766,6 +991,24 @@ and that the Moon has neither correction. Receipts from rc.3 to rc.7 are still
|
|
|
766
991
|
read, each under the conventions its engine recorded, and a set is accepted
|
|
767
992
|
only from the engine versions that wrote it.
|
|
768
993
|
|
|
994
|
+
The time-basis sets, written from 0.1.1-rc.15 on, also record the instant's
|
|
995
|
+
scale (`receipt.timeScale`) and its time basis (`result.timeScale`), and a
|
|
996
|
+
local resolution records the calendar, the tzdb version and form, the clock,
|
|
997
|
+
the transition behind the offset and any birthplace mean time, each checked
|
|
998
|
+
against the offsets and flags. The current set, written from 0.1.1-rc.16 on,
|
|
999
|
+
also names the nutation, the engine's IAU 2000B (`nutation`), and takes the
|
|
1000
|
+
Moon from astronomy-engine's geocentric series turned by the engine's frame
|
|
1001
|
+
(`moonPosition`); rc.15's set, which does not name the nutation, stays
|
|
1002
|
+
readable. Receipts under the rc.8 set (rc.8 to rc.14), which read the instant
|
|
1003
|
+
as UT1, stay readable and replay as UTC requests (see docs/time.md). A
|
|
1004
|
+
receipt's engine, ephemeris and package versions must be SemVer 2.0.0
|
|
1005
|
+
versions. The codec accepts an earlier set only under the versions that wrote
|
|
1006
|
+
it, rc.15's under 0.1.1-rc.15 alone, and compares the engine's version in
|
|
1007
|
+
SemVer order with 0.1.1-rc.16, which brought the current set, and with the
|
|
1008
|
+
releases that brought each house system: a receipt of the current set that
|
|
1009
|
+
names a version before 0.1.1-rc.16, such as 0.1.1-rc.15.1 or 0.1.1-beta, is
|
|
1010
|
+
refused.
|
|
1011
|
+
|
|
769
1012
|
`natalReplayInput` recovers the recorded request. It does not select or install
|
|
770
1013
|
the original engine. Recalculation with another engine, ephemeris dependency or
|
|
771
1014
|
runtime may differ; verify trusted artifact identity and runtime provenance
|