yantra/drk-grahana.js
प्रमाण: दृक् + स्वामी-परम्परा (Pardeep Sehrawat). Value by value:
617 lines · 28 exports
The header, as the file states it
What it loads
- yantra/spanda-lattice.jsmodule
- yantra/purnanka-bandha-tantra.jsmodule
- yantra/udaya-bija.jsmodule
- yantra/madhava-ganita.jsmodule
- yantra/bija-samskara.jsmodule
- yantra/meridian.jsmodule
- yantra/ss8-dhruva.jsmodule
- yantra/drk-udaya.jsmodule
What it exports
eclipsesgeometryAtwithJdspanoverlapFractionrefractionDegOWN_CONVENTIONSCONSTANTSAU_KMEARTH_A_KMEARTH_INV_FK_MEANK_UMBRASUN_SD_1AU_ARCSECSUN_R_KMDANJONMOON_HORIZON_DEGSUN_HORIZON_DEGREFRACTION_ARCMINNODESHALF_WINDOWSEARCH_HALFEDGE_MARGINPRUNE_LAT_DEGPRAMANAlabelLABELsourceSS verses named in the header
- SS 2.28verseparamāpakramajyā tu saptarandhraguṇendavaḥ । tadguṇā jyā trijīvāptā taccāpaṃ krāntirucyate ।।
- SS 3.9versetriṃśatkṛtyo yuge bhānāṃ cakraṃ prākparilambate । tadguṇādbhūdinairbhaktāddyugaṇādyadavāpyate ।।
- SS 1.34versebhānāṃ aṣṭākṣivasvadritridvidvyaṣṭaśarendavaḥ । bhodayā bhagaṇaiḥ svaiḥ svairūnāḥ svasvodayā yuge ।।
- SS 4.16versesphuṭatithyavasāne tu madhyagrahaṇaṃ ādiśet । sthityardhanāḍikāhīne grāso mokṣastu saṃyute ।।
- SS 4.17versetadvadeva vimardārdhanāḍikāhīnasaṃyute । nimīlanonmīlanākhye bhavetāṃ sakalagrahe ।।
- SS 1.45verseṣaṇmanūnāṃ tu sampīḍya kālaṃ tatsandhibhiḥ saha । kalpādisandhinā sārdhaṃ vaivasvatamanostathā ।।
- SS 1.46verseyugānāṃ trighanaṃ yātaṃ tathā kṛtayugaṃ tvidam । projjhya sṛṣṭestataḥ kālaṃ pūrvoktaṃ divyasaṃkhyayā ।।
- SS 1.47versesūryābdasaṃkhyayā jñeyāḥ kṛtasyānte gatā amī । khacatuṣkayamādryagniśararandhraniśākarāḥ ।।
The channels it runs in
Every function, what it calls, who calls it
68 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.
[jyā, koṭijyā] of an angle in radians: Mādhava's series, the quadrant taken on the lattice (purnanka-bandha-tantra.js jyaK).
the arc of (y, x), radians in (−π, π]: Mādhava's arc series with the tri-karaṇī step (madhava-ganita.js capa).
── small vector helpers ────────────────────────────────────────────────────────────────────────────────────────────────
Fraction of disc 1 (radius r1) covered by disc 2 (radius r2) at centre distance d (planar; small angles). गणित
दृक्: Bennett's (1982) refraction in degrees from the true geometric altitude altDeg — display only (the contacts are geometric).
[first, last] civil day served: bija-patra.json `window` (the owner's sky as the engine measured it) on the served day count.
a civil instant on the 1e-9-day grid (86 µs), as the exact rational the bandha tier takes
civil t → the series' uniform day τ: the record's own day + the kāla-bīja (purnanka-bandha-tantra.js tauOf)
the kāla-bīja at civil t: seconds by which the civil day lags the series' uniform day (bija-patra.json params.kala)
the frame at civil t, degrees: θ turns the series' frame onto the true equinox of date (series λ + θ = the true sāyana λ), ε the measured obliquity of date (udaya-bija.js ayanamshaIAE and epsilon; bandha-patra.json frame.offsetDeg)
the Greenwich meridian's sāyana place (its right ascension), degrees, at civil t: udaya-bija.js rotation (the measured star-rotation)
the series' frame → the true equator and equinox of date: θ about the ecliptic's pole, then ε about the equinox line
the apparent geocentric Sun and Moon at civil t in the series' frame: position vectors (AU) and unit vectors (apparentB)
a state from the two apparent position vectors (AU) on the true equator of date
the state straight from the series (or the comparison source) at civil t; null outside the span
── the Chebyshev interpolant of the apparent Sun and Moon (series frame, AU) and the frame angles over [cT − 0.35, cT + 0.35] ──
the geocentric apparent Sun and Moon on the true equator of date, km, at civil t
Global minimum of f on [a, b]: a 48-point scan, then golden section on the best bracket, to 1e-9 d.
The root of f between x0 (f < 0) and x1 (f > 0) by bisection with a secant step, to 1e-9 d; null if f does not change sign.
── lunar eclipses ──────────────────────────────────────────────────────────────────────────────────────────────────────
f = R − γ is > 0 inside a phase and < 0 outside it; findRoot() wants f(x0) < 0 < f(x1)
── solar eclipses ──────────────────────────────────────────────────────────────────────────────────────────────────────
The ellipsoid's support point in direction n (the limb point nearest the axis when the axis misses the Earth).
The near-side meeting of the axis with the ellipsoid (geocentric km), or null.
geodetic latitude and east longitude (degrees) of a geocentric point P (km) under the star-rotation gastDeg
the observer on the ellipsoid (km, the true equator of date) and the local vertical, under the star-rotation gastDeg
Topocentric disc geometry at an observer position O (km); mKm = the observer's distance from the shadow axis.
Geometric syzygies (elongation 0 or 180 on the series' raw vectors; light's time and aberration left out: a search aid only) in [t0, t1] (civil days inside the span, whose last day is endT). The rate is the series' own mean synodic motion: the Moon's mean longitude rate less the Earth's (bandha-patra.json angles L_M, L_E).
an estimate or iterate past the span's end is decided at the end itself: the elongation has not reached the target there → this syzygy falls after the span, so after t1, and is not needed (the search ends; nothing outside is asked for); reached → the syzygy lies inside and the secant resumes from the end
A finite number, or TypeError (null is kept for "outside the span").
the site: null → none (the global rows only); omitted or without a latitude → the default site read from meridian.js (D13)
The Sun's and the Moon's places at civil t from the series (the bandha tier's apparent places), in the served nirayaṇa frame: series λ − the record's frame constant (the IAE zero) + dhruva (D21: Citrā at 180°); the Moon's latitude on the ecliptic of date.
Eclipses whose greatest phase falls in [t1, t2] (civil days since Laṅkā midnight at the Kali start, the served meridian), oldest first; with the local rows at the site (see the header). null when the search window (t1 − 0.6 d … t2 + 0.6 d), or an eclipse's ±0.35-d window, leaves the span. A day that is not a finite number throws TypeError; t2 before t1, RangeError.
The eclipse geometry at one instant (civil t), straight from the series (no interpolant); see the header. null outside the span.
The rows with a `jd` mirror of every instant (max, contacts, phases; the local ones too), made by the door's own day-number function — web.js passes meridian.js jdOfDays, so the Julian day is read at the door and this module counts civil days only.