@zodiacs/engine 0.1.1-rc.16 → 1.1.0
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 +1478 -0
- package/LICENSING.md +184 -30
- package/NOTICE +81 -14
- package/README.md +345 -67
- package/dist/{api-VOW6Umy5.d.ts → api-ChL1N2Sr.d.ts} +44 -7
- package/dist/ayanamsa-ClFzkKmV.d.ts +135 -0
- package/dist/calc.d.ts +218 -21
- package/dist/calc.js +580 -160
- package/dist/chunk-2PZYJQV5.js +83 -0
- package/dist/chunk-47ERTK5X.js +27 -0
- package/dist/{chunk-O3NJRGJ2.js → chunk-4XOYTBLS.js} +1 -1
- package/dist/chunk-767FTO7O.js +48 -0
- package/dist/{chunk-N4B5JNMA.js → chunk-7Y2F2IWN.js} +40 -28
- package/dist/chunk-B4M2Y7FT.js +96 -0
- package/dist/{chunk-KHBLFXFG.js → chunk-B5LKF437.js} +29 -28
- package/dist/{chunk-ONBZ4HK7.js → chunk-BHJXUY67.js} +4 -2
- package/dist/{chunk-PFGUCNOK.js → chunk-BMDASNPB.js} +6 -6
- package/dist/chunk-I3L4POY7.js +18 -0
- package/dist/{chunk-I7O5EGFV.js → chunk-LNGURVNH.js} +3 -3
- package/dist/{chunk-4NV4ZEFZ.js → chunk-NNOSOOWS.js} +4 -4
- package/dist/chunk-OVXQQEXL.js +41 -0
- package/dist/{chunk-WOU7JVD3.js → chunk-QLIEEICB.js} +205 -194
- package/dist/chunk-RMBWKZI2.js +130 -0
- package/dist/{chunk-AECKV73C.js → chunk-TSS2SZWQ.js} +8 -2
- package/dist/{chunk-L6ZHWJZ6.js → chunk-TZVPZHZM.js} +51 -29
- package/dist/chunk-WBTWY2OB.js +478 -0
- package/dist/chunk-Y4E3WJU5.js +87 -0
- package/dist/chunk-YPU3MDNI.js +852 -0
- package/dist/conventions.d.ts +70 -0
- package/dist/conventions.js +26 -0
- package/dist/crossings.d.ts +22 -10
- package/dist/crossings.js +1 -1
- package/dist/de440-pack.d.ts +43 -0
- package/dist/de440-pack.js +16 -0
- package/dist/de440.d.ts +113 -0
- package/dist/de440.js +19 -0
- package/dist/deltat.d.ts +28 -3
- package/dist/deltat.js +1 -1
- package/dist/ephemeris-exTSqBgb.d.ts +60 -0
- package/dist/geo.d.ts +46 -13
- package/dist/geo.js +4 -2
- package/dist/{houses-q1O2GGp4.d.ts → houses-Bh7GCnPi.d.ts} +14 -4
- package/dist/houses-extra.d.ts +22 -7
- package/dist/houses-extra.js +4 -2
- package/dist/index.d.ts +36 -49
- package/dist/index.js +54 -34
- package/dist/{internal-math-CmJ9xtaW.d.ts → internal-math-CxenuGfm.d.ts} +41 -27
- package/dist/internal-math.d.ts +4 -3
- package/dist/internal-math.js +14 -12
- package/dist/internal.d.ts +16 -7
- package/dist/internal.js +27 -6
- package/dist/lite-composite.js +114 -0
- package/dist/lite-declinations.js +253 -0
- package/dist/lite-dignities.js +333 -0
- package/dist/lite-sect.js +72 -0
- package/dist/lite.d.ts +82 -0
- package/dist/lite.js +4 -0
- package/dist/receipt.d.ts +3 -268
- package/dist/receipt.js +202 -89
- package/dist/reference-span-CILpclrz.d.ts +40 -0
- package/dist/{rulers-9wljfVaO.d.ts → rulers-CSSWtiWF.d.ts} +7 -2
- package/dist/sky.d.ts +26 -10
- package/dist/sky.js +23 -14
- package/dist/techniques.d.ts +160 -21
- package/dist/techniques.js +157 -89
- package/dist/time-bands-CZA9AlLg.d.ts +36 -0
- package/dist/time-scale-DIFNa0gz.d.ts +47 -0
- package/dist/time.d.ts +81 -0
- package/dist/time.js +74 -0
- package/dist/timing.d.ts +55 -17
- package/dist/timing.js +33 -45
- package/dist/types-DpPdtXgO.d.ts +335 -0
- package/dist/vedic.d.ts +150 -123
- package/dist/vedic.js +398 -440
- package/dist/window.d.ts +102 -80
- package/dist/window.js +108 -51
- package/dist/zone-history-BxmDCcTK.d.ts +290 -0
- package/package.json +26 -3
- package/dist/chunk-2OWGBT3O.js +0 -219
- package/dist/types-B4MCoCCS.d.ts +0 -228
package/dist/sky.d.ts
CHANGED
|
@@ -1,11 +1,19 @@
|
|
|
1
|
-
import { B as BodyName,
|
|
2
|
-
import { T as TraditionalPlanet } from './rulers-
|
|
3
|
-
export { C as CHALDEAN_ORDER } from './rulers-
|
|
1
|
+
import { B as BodyName, e as DateInput } from './types-DpPdtXgO.js';
|
|
2
|
+
import { T as TraditionalPlanet } from './rulers-CSSWtiWF.js';
|
|
3
|
+
export { C as CHALDEAN_ORDER } from './rulers-CSSWtiWF.js';
|
|
4
4
|
import './deltat.js';
|
|
5
|
+
import './time-scale-DIFNa0gz.js';
|
|
5
6
|
|
|
6
7
|
/** A body the sky functions accept: the Sun, the Moon and the planets. */
|
|
7
8
|
type SkyBody = Exclude<BodyName, "North Node" | "South Node">;
|
|
8
|
-
/**
|
|
9
|
+
/**
|
|
10
|
+
* A place: geodetic latitude and longitude in degrees (east positive) and
|
|
11
|
+
* height in metres above the WGS84 ellipsoid, on which the sky functions place
|
|
12
|
+
* the observer. `@zodiacs/engine/calc`'s CalcPlace has the same three fields on
|
|
13
|
+
* the IERS 2003 ellipsoid, which its topocentric reduction uses, and accepts
|
|
14
|
+
* heights from −12,000 m: the two ellipsoids' equatorial radii differ by
|
|
15
|
+
* 0.4 m, and a height from −12,000 to −10,000 m is refused here.
|
|
16
|
+
*/
|
|
9
17
|
interface Observer {
|
|
10
18
|
latitude: number;
|
|
11
19
|
longitude: number;
|
|
@@ -18,15 +26,15 @@ type Limb = "upper" | "centre" | "lower";
|
|
|
18
26
|
type Refraction = "standard" | "none";
|
|
19
27
|
interface SkyOptions {
|
|
20
28
|
/** `"upper"` for the Sun and Moon unless given; the planets accept only `"centre"`. */
|
|
21
|
-
limb?: Limb;
|
|
29
|
+
readonly limb?: Limb | undefined;
|
|
22
30
|
/** `"standard"` unless given. */
|
|
23
|
-
refraction?: Refraction;
|
|
31
|
+
readonly refraction?: Refraction | undefined;
|
|
24
32
|
/** Most position evaluations the searches may make: a positive integer or `Infinity` (default). */
|
|
25
|
-
maxSamples?: number;
|
|
33
|
+
readonly maxSamples?: number | undefined;
|
|
26
34
|
}
|
|
27
35
|
interface SkyDayOptions extends SkyOptions {
|
|
28
36
|
/** The clock that defines the day, minutes east of UTC. Default: the observer's local mean time, longitude × 4. */
|
|
29
|
-
utcOffsetMinutes?: number;
|
|
37
|
+
readonly utcOffsetMinutes?: number | undefined;
|
|
30
38
|
}
|
|
31
39
|
type SkyEventKind = "rise" | "set" | "upper-transit" | "lower-transit";
|
|
32
40
|
interface SkyEvent {
|
|
@@ -124,7 +132,8 @@ interface PlanetaryDayBase {
|
|
|
124
132
|
* clock's midnight falls next to sunrise. `"no-sunset"`: the Sun rose but did
|
|
125
133
|
* not set within three days of the date's start, as polar day begins.
|
|
126
134
|
* `"no-next-sunrise"`: it rose and set but did not rise again within those
|
|
127
|
-
* three days, as polar night begins. `"refused"`: the sample budget ran out
|
|
135
|
+
* three days, as polar night begins. `"refused"`: the sample budget ran out,
|
|
136
|
+
* with `reason: "sample-budget"` as a refused skyEventsOn() gives it.
|
|
128
137
|
*/
|
|
129
138
|
type PlanetaryDay = (PlanetaryDayBase & {
|
|
130
139
|
readonly status: "complete";
|
|
@@ -133,7 +142,14 @@ type PlanetaryDay = (PlanetaryDayBase & {
|
|
|
133
142
|
readonly nextSunrise: Date;
|
|
134
143
|
readonly hours: readonly PlanetaryHour[];
|
|
135
144
|
}) | (PlanetaryDayBase & {
|
|
136
|
-
readonly status: "no-sunrise" | "no-sunset" | "no-next-sunrise"
|
|
145
|
+
readonly status: "no-sunrise" | "no-sunset" | "no-next-sunrise";
|
|
146
|
+
readonly sunrise: null;
|
|
147
|
+
readonly sunset: null;
|
|
148
|
+
readonly nextSunrise: null;
|
|
149
|
+
readonly hours: readonly [];
|
|
150
|
+
}) | (PlanetaryDayBase & {
|
|
151
|
+
readonly status: "refused";
|
|
152
|
+
readonly reason: "sample-budget";
|
|
137
153
|
readonly sunrise: null;
|
|
138
154
|
readonly sunset: null;
|
|
139
155
|
readonly nextSunrise: null;
|
package/dist/sky.js
CHANGED
|
@@ -4,23 +4,29 @@ import {
|
|
|
4
4
|
import {
|
|
5
5
|
equatorRows,
|
|
6
6
|
turn
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-4XOYTBLS.js";
|
|
8
|
+
import {
|
|
9
|
+
gastHours,
|
|
10
|
+
onChartClock,
|
|
11
|
+
refuseUnderSource
|
|
12
|
+
} from "./chunk-QLIEEICB.js";
|
|
8
13
|
import {
|
|
9
14
|
dateFrom
|
|
10
15
|
} from "./chunk-CPALRSPC.js";
|
|
11
|
-
import
|
|
12
|
-
|
|
13
|
-
} from "./chunk-AECKV73C.js";
|
|
14
|
-
import {
|
|
15
|
-
gastHours,
|
|
16
|
-
onChartClock
|
|
17
|
-
} from "./chunk-WOU7JVD3.js";
|
|
16
|
+
import "./chunk-B4M2Y7FT.js";
|
|
17
|
+
import "./chunk-2PZYJQV5.js";
|
|
18
18
|
import {
|
|
19
19
|
outsideReferenceSpan
|
|
20
|
-
} from "./chunk-
|
|
21
|
-
import
|
|
22
|
-
|
|
23
|
-
|
|
20
|
+
} from "./chunk-B5LKF437.js";
|
|
21
|
+
import {
|
|
22
|
+
searchLongitudeCrossingsWith
|
|
23
|
+
} from "./chunk-TSS2SZWQ.js";
|
|
24
|
+
import "./chunk-767FTO7O.js";
|
|
25
|
+
import "./chunk-YPU3MDNI.js";
|
|
26
|
+
import "./chunk-Y4E3WJU5.js";
|
|
27
|
+
import "./chunk-NNOSOOWS.js";
|
|
28
|
+
import "./chunk-RMBWKZI2.js";
|
|
29
|
+
import "./chunk-BHJXUY67.js";
|
|
24
30
|
|
|
25
31
|
// src/sky/riseset.ts
|
|
26
32
|
import { Body, GeoVector } from "astronomy-engine";
|
|
@@ -53,7 +59,7 @@ var RAD = Math.PI / 180;
|
|
|
53
59
|
var DAY_MS = 864e5;
|
|
54
60
|
var STEP_DAYS = 1 / 24;
|
|
55
61
|
var STANDARD_REFRACTION_ARCMIN = 34;
|
|
56
|
-
var SKY_RADII_KM = Object.freeze({ Sun: 696e3, Moon: 1737.4 });
|
|
62
|
+
var SKY_RADII_KM = /* @__PURE__ */ Object.freeze({ Sun: 696e3, Moon: 1737.4 });
|
|
57
63
|
var KM_PER_AU = 1495978707e-1;
|
|
58
64
|
var WGS84_A = 6378.137;
|
|
59
65
|
var WGS84_F = 1 / 298.257223563;
|
|
@@ -125,6 +131,7 @@ function conventionsOf(body, input) {
|
|
|
125
131
|
return Object.freeze({ limb, refraction, refractionArcmin: refraction === "standard" ? STANDARD_REFRACTION_ARCMIN : 0 });
|
|
126
132
|
}
|
|
127
133
|
function stateAt(body, site, conventions, ms) {
|
|
134
|
+
refuseUnderSource("@zodiacs/engine/sky's rising and setting");
|
|
128
135
|
return onChartClock(ms, "utc", void 0, (time) => {
|
|
129
136
|
const g = GeoVector(BODIES[body], time, true);
|
|
130
137
|
const [vx, vy, vz] = turn(equatorRows(time.tt, "true"), g.x, g.y, g.z);
|
|
@@ -303,7 +310,9 @@ function dayOf(site, input, midnightMs) {
|
|
|
303
310
|
const search = searchEvents("Sun", site, conventions, startMs, startMs + SPAN_DAYS * DAY_MS2, budgetOf(input.maxSamples), false);
|
|
304
311
|
const base = { date: isoDate(midnightMs), utcOffsetMinutes: offset, weekday, ruler, conventions, samples: search.samples };
|
|
305
312
|
const empty = { sunrise: null, sunset: null, nextSunrise: null, hours: Object.freeze([]) };
|
|
306
|
-
if (search.status === "refused")
|
|
313
|
+
if (search.status === "refused") {
|
|
314
|
+
return Object.freeze({ ...base, flags: Object.freeze([]), status: "refused", reason: "sample-budget", ...empty });
|
|
315
|
+
}
|
|
307
316
|
const rise = search.events.find((event) => event.kind === "rise" && event.at.getTime() < startMs + DAY_MS2);
|
|
308
317
|
const set = rise && search.events.find((event) => event.kind === "set" && event.at > rise.at);
|
|
309
318
|
const next = set && search.events.find((event) => event.kind === "rise" && event.at > set.at);
|
package/dist/techniques.d.ts
CHANGED
|
@@ -1,26 +1,37 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { E as EphemerisFallback, d as Chart, H as HouseSystem, e as DateInput, D as DetailedResult, B as BodyName, f as AspectType, Z as ZodiacSign, l as Element, j as Sect } from './types-DpPdtXgO.js';
|
|
2
|
+
import { N as NatalSource } from './api-ChL1N2Sr.js';
|
|
3
3
|
import './deltat.js';
|
|
4
|
+
import './time-scale-DIFNa0gz.js';
|
|
4
5
|
import './crossings.js';
|
|
5
6
|
|
|
6
|
-
/**
|
|
7
|
-
|
|
7
|
+
/**
|
|
8
|
+
* `"outside-reference-span"`: the ephemeris was read outside 1800 to 2200
|
|
9
|
+
* (`REFERENCE_SPAN`). `"de440-unavailable"` and `"outside-de440-span"`: a
|
|
10
|
+
* position was astronomy-engine's as a fallback from the shipped DE440 pack
|
|
11
|
+
* (the root entry's `EphemerisFallback`).
|
|
12
|
+
*/
|
|
13
|
+
type TechniqueFlag = "outside-reference-span" | EphemerisFallback;
|
|
8
14
|
/** Latitude in [−90, 90] and longitude east in [−180, 180], degrees. */
|
|
9
15
|
interface GeoPlace {
|
|
10
16
|
readonly latitude: number;
|
|
11
17
|
readonly longitude: number;
|
|
12
18
|
}
|
|
19
|
+
/** The ephemeris a result names: `{ name: "jpl-de440", version }` on the shipped pack, astronomy-engine's otherwise. */
|
|
20
|
+
interface TechniqueEphemeris {
|
|
21
|
+
readonly name: string;
|
|
22
|
+
readonly version: string;
|
|
23
|
+
}
|
|
13
24
|
|
|
14
25
|
/** Half-width of the solar return search around its date, days. */
|
|
15
|
-
declare const SOLAR_RETURN_WINDOW_DAYS
|
|
26
|
+
declare const SOLAR_RETURN_WINDOW_DAYS: number;
|
|
16
27
|
/** How far back `mostRecentSolarReturnInstant` searches, days. */
|
|
17
|
-
declare const SOLAR_RETURN_LOOKBACK_DAYS
|
|
28
|
+
declare const SOLAR_RETURN_LOOKBACK_DAYS: number;
|
|
18
29
|
/** Coarse step of the solar return search, days. */
|
|
19
|
-
declare const SOLAR_RETURN_STEP_DAYS
|
|
30
|
+
declare const SOLAR_RETURN_STEP_DAYS: number;
|
|
20
31
|
/** How far the lunar return search runs, days. */
|
|
21
|
-
declare const LUNAR_RETURN_HORIZON_DAYS
|
|
32
|
+
declare const LUNAR_RETURN_HORIZON_DAYS: number;
|
|
22
33
|
/** Coarse step of the lunar return search, days. */
|
|
23
|
-
declare const LUNAR_RETURN_STEP_DAYS
|
|
34
|
+
declare const LUNAR_RETURN_STEP_DAYS: number;
|
|
24
35
|
/** The solar return nearest the date, or the latest at or before it. */
|
|
25
36
|
type SolarReturnSelection = "nearest" | "most-recent";
|
|
26
37
|
interface ReturnOptions {
|
|
@@ -33,7 +44,8 @@ interface SolarReturnOptions extends ReturnOptions {
|
|
|
33
44
|
/** `"nearest"` by default. */
|
|
34
45
|
selection?: SolarReturnSelection | undefined;
|
|
35
46
|
}
|
|
36
|
-
|
|
47
|
+
/** A solar or lunar return: the instant the body is back on its natal longitude, and the chart then. */
|
|
48
|
+
interface ReturnChart {
|
|
37
49
|
readonly body: "Sun" | "Moon";
|
|
38
50
|
/** The body's longitude in the natal chart, degrees. */
|
|
39
51
|
readonly natalLongitude: number;
|
|
@@ -45,11 +57,17 @@ interface PlanetaryReturn {
|
|
|
45
57
|
/** From the natal instant and the ends of the searched window. */
|
|
46
58
|
readonly flags: readonly TechniqueFlag[];
|
|
47
59
|
}
|
|
48
|
-
|
|
60
|
+
/**
|
|
61
|
+
* A solar or lunar return, under its first name.
|
|
62
|
+
*
|
|
63
|
+
* @deprecated Use ReturnChart, the same type: `@zodiacs/engine/timing`'s PlanetaryReturn is another one.
|
|
64
|
+
*/
|
|
65
|
+
type PlanetaryReturn = ReturnChart;
|
|
66
|
+
interface SolarReturn extends ReturnChart {
|
|
49
67
|
readonly body: "Sun";
|
|
50
68
|
readonly selection: SolarReturnSelection;
|
|
51
69
|
}
|
|
52
|
-
interface LunarReturn extends
|
|
70
|
+
interface LunarReturn extends ReturnChart {
|
|
53
71
|
readonly body: "Moon";
|
|
54
72
|
}
|
|
55
73
|
/**
|
|
@@ -57,13 +75,24 @@ interface LunarReturn extends PlanetaryReturn {
|
|
|
57
75
|
* crossing solver at 1-day steps over ±200 days; a tie goes to the earlier.
|
|
58
76
|
*/
|
|
59
77
|
declare function solarReturnInstant(natalSunLongitude: number, near: DateInput): Date;
|
|
78
|
+
/**
|
|
79
|
+
* `solarReturnInstant`'s instant as `value`, with the ephemeris the Sun's
|
|
80
|
+
* longitudes came from and the flags that say why that is astronomy-engine
|
|
81
|
+
* where the shipped DE440 pack was the default (`DetailedResult`), over the
|
|
82
|
+
* whole window searched.
|
|
83
|
+
*/
|
|
84
|
+
declare function solarReturnInstantDetailed(natalSunLongitude: number, near: DateInput): DetailedResult<Date, TechniqueFlag>;
|
|
60
85
|
/** The latest instant at or before `at` when the apparent Sun is at `natalSunLongitude`, within 370 days. */
|
|
61
86
|
declare function mostRecentSolarReturnInstant(natalSunLongitude: number, at: DateInput): Date;
|
|
87
|
+
/** `mostRecentSolarReturnInstant`'s instant as `value`, labelled as `solarReturnInstantDetailed`'s is. */
|
|
88
|
+
declare function mostRecentSolarReturnInstantDetailed(natalSunLongitude: number, at: DateInput): DetailedResult<Date, TechniqueFlag>;
|
|
62
89
|
/**
|
|
63
90
|
* The first instant in (after, after + 40 days] when the apparent Moon is at
|
|
64
91
|
* `natalMoonLongitude`: the crossing solver at 6-hour steps.
|
|
65
92
|
*/
|
|
66
93
|
declare function lunarReturnInstant(natalMoonLongitude: number, after: DateInput): Date;
|
|
94
|
+
/** `lunarReturnInstant`'s instant as `value`, labelled over the 40 days searched as `solarReturnInstantDetailed`'s is. */
|
|
95
|
+
declare function lunarReturnInstantDetailed(natalMoonLongitude: number, after: DateInput): DetailedResult<Date, TechniqueFlag>;
|
|
67
96
|
/**
|
|
68
97
|
* The solar return of a natal chart or birth nearest `date` (or the latest at
|
|
69
98
|
* or before it), and its chart. The natal Sun is the chart's own.
|
|
@@ -91,6 +120,20 @@ interface CompositeAspect {
|
|
|
91
120
|
interface CompositeChart {
|
|
92
121
|
readonly bodies: readonly CompositePosition[];
|
|
93
122
|
readonly aspects: readonly CompositeAspect[];
|
|
123
|
+
/**
|
|
124
|
+
* The ephemeris both charts name (`chart.ephemeris`): `{ name: "jpl-de440", version }` on the shipped DE440
|
|
125
|
+
* pack, astronomy-engine's name and version otherwise; null where the two do not name one and the same, or a
|
|
126
|
+
* supplied chart from an earlier release names none. Set by `compositeChart` from 1.1.0-rc.11.
|
|
127
|
+
*/
|
|
128
|
+
readonly ephemeris: {
|
|
129
|
+
readonly name: string;
|
|
130
|
+
readonly version: string;
|
|
131
|
+
} | null;
|
|
132
|
+
/**
|
|
133
|
+
* The flags among `"outside-reference-span"`, `"de440-unavailable"` and `"outside-de440-span"` that either
|
|
134
|
+
* chart carries, in that order. Set by `compositeChart` from 1.1.0-rc.11.
|
|
135
|
+
*/
|
|
136
|
+
readonly flags: readonly ("outside-reference-span" | "de440-unavailable" | "outside-de440-span")[];
|
|
94
137
|
}
|
|
95
138
|
/**
|
|
96
139
|
* The composite positions of the bodies in both lists, in the first list's
|
|
@@ -106,19 +149,38 @@ declare function compositeMidpoints(first: readonly {
|
|
|
106
149
|
}[]): readonly CompositePosition[];
|
|
107
150
|
/** The major aspects among the composite Sun to Pluto, with the natal orbs of `ASPECTS`, by orb. */
|
|
108
151
|
declare function compositeAspects(points: readonly CompositePosition[]): readonly CompositeAspect[];
|
|
152
|
+
|
|
109
153
|
/** The composite of two charts or births: every body's midpoint and their aspects. No angles or houses. */
|
|
110
154
|
declare function compositeChart(first: NatalSource, second: NatalSource): CompositeChart;
|
|
111
155
|
/**
|
|
112
156
|
* `"coordinates"`: the mean latitude and the longitude halfway along the
|
|
113
157
|
* shorter arc. `"great-circle"`: halfway along the great circle.
|
|
158
|
+
*
|
|
159
|
+
* @experimental The conventions of a Davison chart here (the place's default,
|
|
160
|
+
* the house system, a known time only when both are known) may change in a
|
|
161
|
+
* minor release.
|
|
114
162
|
*/
|
|
115
163
|
type DavisonPlaceConvention = "coordinates" | "great-circle";
|
|
164
|
+
/**
|
|
165
|
+
* Options for davisonChart.
|
|
166
|
+
*
|
|
167
|
+
* @experimental The conventions of a Davison chart here (the place's default,
|
|
168
|
+
* the house system, a known time only when both are known) may change in a
|
|
169
|
+
* minor release.
|
|
170
|
+
*/
|
|
116
171
|
interface DavisonOptions {
|
|
117
172
|
/** `"coordinates"` by default. */
|
|
118
173
|
place?: DavisonPlaceConvention | undefined;
|
|
119
174
|
/** The first chart's by default. */
|
|
120
175
|
houseSystem?: HouseSystem | undefined;
|
|
121
176
|
}
|
|
177
|
+
/**
|
|
178
|
+
* A Davison chart, with the instant and the place it was cast for.
|
|
179
|
+
*
|
|
180
|
+
* @experimental The conventions of a Davison chart here (the place's default,
|
|
181
|
+
* the house system, a known time only when both are known) may change in a
|
|
182
|
+
* minor release.
|
|
183
|
+
*/
|
|
122
184
|
interface DavisonChart {
|
|
123
185
|
/** The mean of the two births' UTC instants, rounded down to the millisecond. */
|
|
124
186
|
readonly instant: Date;
|
|
@@ -129,11 +191,23 @@ interface DavisonChart {
|
|
|
129
191
|
readonly chart: Chart;
|
|
130
192
|
readonly flags: readonly TechniqueFlag[];
|
|
131
193
|
}
|
|
132
|
-
/**
|
|
194
|
+
/**
|
|
195
|
+
* The midpoint of two places. A place outside latitudes −90 to 90 and
|
|
196
|
+
* longitudes −180 to 180, or a convention not named, throws a RangeError, and
|
|
197
|
+
* so do antipodes, which have no great-circle midpoint.
|
|
198
|
+
*
|
|
199
|
+
* @experimental The conventions of a Davison chart here (the place's default,
|
|
200
|
+
* the house system, a known time only when both are known) may change in a
|
|
201
|
+
* minor release.
|
|
202
|
+
*/
|
|
133
203
|
declare function davisonPlace(first: GeoPlace, second: GeoPlace, convention?: DavisonPlaceConvention): GeoPlace;
|
|
134
204
|
/**
|
|
135
205
|
* The Davison chart of two charts or births (Davison, 1977): a chart for the
|
|
136
206
|
* midpoint in time and the midpoint in space of the two births.
|
|
207
|
+
*
|
|
208
|
+
* @experimental The conventions of a Davison chart here (the place's default,
|
|
209
|
+
* the house system, a known time only when both are known) may change in a
|
|
210
|
+
* minor release.
|
|
137
211
|
*/
|
|
138
212
|
declare function davisonChart(first: NatalSource, second: NatalSource, options?: DavisonOptions): DavisonChart;
|
|
139
213
|
|
|
@@ -158,6 +232,16 @@ declare const VOID_OF_COURSE_CONVENTION: Readonly<{
|
|
|
158
232
|
interface MoonIngress {
|
|
159
233
|
readonly at: Date;
|
|
160
234
|
readonly sign: ZodiacSign;
|
|
235
|
+
/**
|
|
236
|
+
* The ephemeris the Moon's and the bodies' longitudes behind it came from: `{ name: "jpl-de440", version }` on
|
|
237
|
+
* the shipped DE440 pack, astronomy-engine's name and version otherwise. From 1.1.0-rc.11.
|
|
238
|
+
*/
|
|
239
|
+
readonly ephemeris: TechniqueEphemeris;
|
|
240
|
+
/**
|
|
241
|
+
* `"de440-unavailable"` or `"outside-de440-span"` where those longitudes were astronomy-engine's as a fallback
|
|
242
|
+
* from the pack, `"outside-reference-span"` where one was read outside 1800 to 2200; none otherwise. From 1.1.0-rc.11.
|
|
243
|
+
*/
|
|
244
|
+
readonly flags: readonly TechniqueFlag[];
|
|
161
245
|
}
|
|
162
246
|
interface MoonAspect {
|
|
163
247
|
readonly at: Date;
|
|
@@ -165,6 +249,16 @@ interface MoonAspect {
|
|
|
165
249
|
readonly aspect: AspectType;
|
|
166
250
|
/** The Moon's longitude at `at`, degrees. */
|
|
167
251
|
readonly moonLon: number;
|
|
252
|
+
/**
|
|
253
|
+
* The ephemeris the Moon's and the bodies' longitudes behind it came from: `{ name: "jpl-de440", version }` on
|
|
254
|
+
* the shipped DE440 pack, astronomy-engine's name and version otherwise. From 1.1.0-rc.11.
|
|
255
|
+
*/
|
|
256
|
+
readonly ephemeris: TechniqueEphemeris;
|
|
257
|
+
/**
|
|
258
|
+
* `"de440-unavailable"` or `"outside-de440-span"` where those longitudes were astronomy-engine's as a fallback
|
|
259
|
+
* from the pack, `"outside-reference-span"` where one was read outside 1800 to 2200; none otherwise. From 1.1.0-rc.11.
|
|
260
|
+
*/
|
|
261
|
+
readonly flags: readonly TechniqueFlag[];
|
|
168
262
|
}
|
|
169
263
|
interface VoidOfCourseWindow {
|
|
170
264
|
/** The last aspect in the sign, or the entry into it when `lastAspect` is null. */
|
|
@@ -174,6 +268,16 @@ interface VoidOfCourseWindow {
|
|
|
174
268
|
readonly lastAspect: MoonAspect | null;
|
|
175
269
|
readonly sign: ZodiacSign;
|
|
176
270
|
readonly nextSign: ZodiacSign;
|
|
271
|
+
/**
|
|
272
|
+
* The ephemeris the Moon's and the bodies' longitudes behind it came from: `{ name: "jpl-de440", version }` on
|
|
273
|
+
* the shipped DE440 pack, astronomy-engine's name and version otherwise. From 1.1.0-rc.11.
|
|
274
|
+
*/
|
|
275
|
+
readonly ephemeris: TechniqueEphemeris;
|
|
276
|
+
/**
|
|
277
|
+
* `"de440-unavailable"` or `"outside-de440-span"` where those longitudes were astronomy-engine's as a fallback
|
|
278
|
+
* from the pack, `"outside-reference-span"` where one was read outside 1800 to 2200; none otherwise. From 1.1.0-rc.11.
|
|
279
|
+
*/
|
|
280
|
+
readonly flags: readonly TechniqueFlag[];
|
|
177
281
|
}
|
|
178
282
|
interface VoidOfCourseStatus {
|
|
179
283
|
readonly at: Date;
|
|
@@ -182,13 +286,23 @@ interface VoidOfCourseStatus {
|
|
|
182
286
|
readonly current: VoidOfCourseWindow | null;
|
|
183
287
|
/** The next period to begin after `at`. */
|
|
184
288
|
readonly next: VoidOfCourseWindow | null;
|
|
289
|
+
/**
|
|
290
|
+
* The ephemeris the Moon's and the bodies' longitudes behind it came from: `{ name: "jpl-de440", version }` on
|
|
291
|
+
* the shipped DE440 pack, astronomy-engine's name and version otherwise. From 1.1.0-rc.11.
|
|
292
|
+
*/
|
|
293
|
+
readonly ephemeris: TechniqueEphemeris;
|
|
294
|
+
/**
|
|
295
|
+
* `"de440-unavailable"` or `"outside-de440-span"` where those longitudes were astronomy-engine's as a fallback
|
|
296
|
+
* from the pack, `"outside-reference-span"` where one was read outside 1800 to 2200; none otherwise. From 1.1.0-rc.11.
|
|
297
|
+
*/
|
|
298
|
+
readonly flags: readonly TechniqueFlag[];
|
|
185
299
|
}
|
|
186
300
|
interface VoidOfCourseOptions {
|
|
187
301
|
/** `"modern"` by default. */
|
|
188
302
|
bodies?: VoidBodies | undefined;
|
|
189
303
|
}
|
|
190
|
-
/** The longest window the scans accept, days. */
|
|
191
|
-
declare const VOID_OF_COURSE_MAX_DAYS
|
|
304
|
+
/** The longest window the scans accept, days. A minor release may accept a longer one. */
|
|
305
|
+
declare const VOID_OF_COURSE_MAX_DAYS: number;
|
|
192
306
|
/** Every entry of the apparent Moon into a sign in (from, to], in time order (6-hour steps). */
|
|
193
307
|
declare function moonIngresses(from: DateInput, to: DateInput): readonly MoonIngress[];
|
|
194
308
|
/** Every exact Ptolemaic aspect of the Moon to the chosen bodies in (from, to]: 3-hour samples, 26 bisections. */
|
|
@@ -250,6 +364,19 @@ interface AspectPatterns {
|
|
|
250
364
|
/** Every pattern, sorted by id. */
|
|
251
365
|
readonly patterns: readonly AspectPattern[];
|
|
252
366
|
}
|
|
367
|
+
/** `chartAspectPatterns`'s result: the patterns, and the chart's label (from 1.1.0-rc.11). */
|
|
368
|
+
interface ChartAspectPatterns extends AspectPatterns {
|
|
369
|
+
/**
|
|
370
|
+
* The chart's `ephemeris`: `{ name: "jpl-de440", version }` on the shipped DE440 pack, astronomy-engine's name
|
|
371
|
+
* and version otherwise; null where a supplied chart from an earlier release names none.
|
|
372
|
+
*/
|
|
373
|
+
readonly ephemeris: {
|
|
374
|
+
readonly name: string;
|
|
375
|
+
readonly version: string;
|
|
376
|
+
} | null;
|
|
377
|
+
/** The flags among `"outside-reference-span"`, `"de440-unavailable"` and `"outside-de440-span"` the chart carries, in that order. */
|
|
378
|
+
readonly flags: readonly TechniqueFlag[];
|
|
379
|
+
}
|
|
253
380
|
/**
|
|
254
381
|
* The grand trines, T-squares, grand crosses and kites (Hand, 1981) that the
|
|
255
382
|
* aspect records form among the Sun to Pluto. Every aspect of a pattern must
|
|
@@ -258,7 +385,7 @@ interface AspectPatterns {
|
|
|
258
385
|
*/
|
|
259
386
|
declare function aspectPatterns(points: readonly PatternPoint[], aspects: readonly PatternEdgeInput[]): AspectPatterns;
|
|
260
387
|
/** The aspect patterns of a chart or birth, from its own bodies and aspects. */
|
|
261
|
-
declare function chartAspectPatterns(natal: NatalSource):
|
|
388
|
+
declare function chartAspectPatterns(natal: NatalSource): ChartAspectPatterns;
|
|
262
389
|
/** `roots`: the patterns inside no other. `included[id]`: those inside `id`. */
|
|
263
390
|
interface PatternContainment {
|
|
264
391
|
readonly roots: readonly AspectPattern[];
|
|
@@ -278,7 +405,12 @@ type SignDignity = "domicile" | "exaltation" | "detriment" | "fall";
|
|
|
278
405
|
type EssentialDignity = "domicile" | "exaltation" | "triplicity" | "term" | "face";
|
|
279
406
|
type Debility = "detriment" | "fall";
|
|
280
407
|
declare const CLASSICAL_PLANETS: readonly ClassicalPlanet[];
|
|
281
|
-
/**
|
|
408
|
+
/**
|
|
409
|
+
* Each sign's domicile ruler (Tetrabiblos I.17): the same rulers as
|
|
410
|
+
* `@zodiacs/engine/timing`'s TRADITIONAL_RULERS and `@zodiacs/engine/vedic`'s
|
|
411
|
+
* SIGN_LORDS. Each entry point carries its own copy, so that none imports
|
|
412
|
+
* another; a test keeps the three equal.
|
|
413
|
+
*/
|
|
282
414
|
declare const DOMICILE_RULERS: Readonly<Record<ZodiacSign, ClassicalPlanet>>;
|
|
283
415
|
/** Each planet's exaltation (Tetrabiblos I.19); its fall is the opposite sign. */
|
|
284
416
|
declare const EXALTATIONS: Readonly<Record<ClassicalPlanet, ZodiacSign>>;
|
|
@@ -374,8 +506,8 @@ declare const EVERY_ZONE_OFFSETS: Readonly<{
|
|
|
374
506
|
readonly earliestHours: 14;
|
|
375
507
|
readonly latestHours: -12;
|
|
376
508
|
}>;
|
|
377
|
-
/** The longest span `moonSignsBetween` accepts, days. */
|
|
378
|
-
declare const MOON_SIGN_MAX_SPAN_DAYS
|
|
509
|
+
/** The longest span `moonSignsBetween` accepts, days. A minor release may accept a longer one. */
|
|
510
|
+
declare const MOON_SIGN_MAX_SPAN_DAYS: number;
|
|
379
511
|
interface MoonSignCandidates {
|
|
380
512
|
/** YYYY-MM-DD, Gregorian. */
|
|
381
513
|
readonly date: string;
|
|
@@ -398,13 +530,20 @@ interface MoonSignOptions {
|
|
|
398
530
|
}
|
|
399
531
|
/** Every sign the apparent Moon is in during [from, to], at most 20 days, in order. */
|
|
400
532
|
declare function moonSignsBetween(from: DateInput, to: DateInput): readonly ZodiacSign[];
|
|
533
|
+
/**
|
|
534
|
+
* `moonSignsBetween`'s signs as `value`, with the ephemeris the Moon's two
|
|
535
|
+
* longitudes came from and the flags that say why that is astronomy-engine
|
|
536
|
+
* where the shipped DE440 pack was the default (`DetailedResult`).
|
|
537
|
+
*/
|
|
538
|
+
declare function moonSignsBetweenDetailed(from: DateInput, to: DateInput): DetailedResult<readonly ZodiacSign[], TechniqueFlag>;
|
|
401
539
|
/**
|
|
402
540
|
* The Moon signs possible over a civil date with an unknown birth time. With
|
|
403
541
|
* `timeZone`, from local midnight to local midnight, read as
|
|
404
542
|
* `resolveLocalToUtc` (`@zodiacs/engine/geo`) reads them; before 1970, await
|
|
405
|
-
* its `prepareLocalTime` first
|
|
543
|
+
* its `prepareLocalTime` first, or it throws geo's ZoneHistoryNotLoadedError,
|
|
544
|
+
* an Error and not a RangeError. Without, in every time zone: `sign` is set
|
|
406
545
|
* only when the Moon held it the whole date everywhere.
|
|
407
546
|
*/
|
|
408
547
|
declare function moonSignCandidates(date: string, options?: MoonSignOptions): MoonSignCandidates;
|
|
409
548
|
|
|
410
|
-
export { type AspectPattern, type AspectPatterns, CHALDEAN_FACES, CLASSICAL_PLANETS, type ClassicalPlanet, type CompositeAspect, type CompositeChart, type CompositePosition, DOMICILE_RULERS, type DavisonChart, type DavisonOptions, type DavisonPlaceConvention, type Debility, type DignityRulers, type DignitySpan, EGYPTIAN_TERMS, EVERY_ZONE_OFFSETS, EXALTATIONS, type EssentialDignity, type GeoPlace, LUNAR_RETURN_HORIZON_DAYS, LUNAR_RETURN_STEP_DAYS, type LunarReturn, MOON_SIGN_MAX_SPAN_DAYS, type MoonAspect, type MoonIngress, type MoonSignCandidates, type MoonSignOptions, type MutualReception, PATTERN_BODIES, type PatternBody, type PatternContainment, type PatternEdge, type PatternEdgeInput, type PatternKind, type PatternPoint, type PlanetDignities, type PlanetaryReturn, type ReceptionOptions, type ReturnOptions, SOLAR_RETURN_LOOKBACK_DAYS, SOLAR_RETURN_STEP_DAYS, SOLAR_RETURN_WINDOW_DAYS, type SignDignity, type SolarReturn, type SolarReturnOptions, type SolarReturnSelection, TRIPLICITY_LORDS, type TechniqueFlag, VOID_BODIES, VOID_OF_COURSE_CONVENTION, VOID_OF_COURSE_MAX_DAYS, type VoidBodies, type VoidBody, type VoidOfCourseOptions, type VoidOfCourseStatus, type VoidOfCourseWindow, aspectPatterns, chartAspectPatterns, compositeAspects, compositeChart, compositeMidpoints, davisonChart, davisonPlace, dignitiesFor, dignityFor, dignityRulersAt, essentialDignities, hasClassicalDignities, lunarReturn, lunarReturnInstant, moonAspects, moonIngresses, moonSignCandidates, moonSignsBetween, mostRecentSolarReturnInstant, mutualReceptions, patternContainment, solarReturn, solarReturnInstant, voidOfCourseAt, voidOfCourseWindows };
|
|
549
|
+
export { type AspectPattern, type AspectPatterns, CHALDEAN_FACES, CLASSICAL_PLANETS, type ChartAspectPatterns, type ClassicalPlanet, type CompositeAspect, type CompositeChart, type CompositePosition, DOMICILE_RULERS, type DavisonChart, type DavisonOptions, type DavisonPlaceConvention, type Debility, DetailedResult, type DignityRulers, type DignitySpan, EGYPTIAN_TERMS, EVERY_ZONE_OFFSETS, EXALTATIONS, type EssentialDignity, type GeoPlace, LUNAR_RETURN_HORIZON_DAYS, LUNAR_RETURN_STEP_DAYS, type LunarReturn, MOON_SIGN_MAX_SPAN_DAYS, type MoonAspect, type MoonIngress, type MoonSignCandidates, type MoonSignOptions, type MutualReception, PATTERN_BODIES, type PatternBody, type PatternContainment, type PatternEdge, type PatternEdgeInput, type PatternKind, type PatternPoint, type PlanetDignities, type PlanetaryReturn, type ReceptionOptions, type ReturnChart, type ReturnOptions, SOLAR_RETURN_LOOKBACK_DAYS, SOLAR_RETURN_STEP_DAYS, SOLAR_RETURN_WINDOW_DAYS, type SignDignity, type SolarReturn, type SolarReturnOptions, type SolarReturnSelection, TRIPLICITY_LORDS, type TechniqueEphemeris, type TechniqueFlag, VOID_BODIES, VOID_OF_COURSE_CONVENTION, VOID_OF_COURSE_MAX_DAYS, type VoidBodies, type VoidBody, type VoidOfCourseOptions, type VoidOfCourseStatus, type VoidOfCourseWindow, aspectPatterns, chartAspectPatterns, compositeAspects, compositeChart, compositeMidpoints, davisonChart, davisonPlace, dignitiesFor, dignityFor, dignityRulersAt, essentialDignities, hasClassicalDignities, lunarReturn, lunarReturnInstant, lunarReturnInstantDetailed, moonAspects, moonIngresses, moonSignCandidates, moonSignsBetween, moonSignsBetweenDetailed, mostRecentSolarReturnInstant, mostRecentSolarReturnInstantDetailed, mutualReceptions, patternContainment, solarReturn, solarReturnInstant, solarReturnInstantDetailed, voidOfCourseAt, voidOfCourseWindows };
|