भारत · ग्रहगणित
स्थान उज्जयिनी Ujjayinī · change it on a tool⌕ search the कोश ⌘Kप्रहर — · —:—:—ours, from sunriseउज्जयिनी —:—:—UTC + λ/15 h, λ = 75.7682° E (D13)IST Error −26.9 minlocal mean time − IST = 4λ − 330 min (K12)engine 3f94072the site ↗

gurutva/purnanka-gurutva-jala.js

our own N-body on the Sūrya-Siddhānta's integer lattice (owner, 2026-10-27).

171 lines · 10 exports

लेख · the header

The header, as the file states it

purnanka-gurutva-jala.js — our own N-body on the Sūrya-Siddhānta's integer lattice (owner, 2026-10-27). THE LATTICE time the spanda of the turn, N = 30⁸ (purnanka-bandha-tantra.js N_DAY; D1/D1a/D1c); the step is one civil ghaṭī, 1/60 of a civil day = N·R/(60·S) spandas (an exact rational: the civil day is not whole on the turn clock) length 30¹⁴ units to Earth's orbit (a⊕ = 1, as the text's śīghra epicycles measure every orbit against it) state every position an exact integer; the step x(k+1) = x(k) + d(k+1), d(k+1) = d(k) + F(x(k)) with d and F integers — the Störmer–Verlet step on the lattice: exactly reversible (run it backward and every integer returns), and the same integers on any machine. F is the pull, h²·a·30¹⁴ rounded to the lattice; a is computed from the integer positions (IEEE doubles, correctly rounded), so F is a fixed function of the state. THE BĪJA (the seed, at the Kali start, Laṅkā midnight, ahargaṇa 0) — the locks alone (§12 of the bandha tantra): each graha's rate n (its bhagaṇa ÷ the civil days), mean place, ucca and pāta (1.29–1.47), e from its manda epicycle, i from its greatest latitude (1.68–1.70); for Budha and Śukra the śīghrocca is their own wheel. GM☉: Kepler's third law in its discrete form on the text's own year — the lattice step turns a circular orbit of radius a by θ when GM = 2a³(1 − cos θ)/h², so Earth (a = 1) at θ = n⊕h fixes GM☉, and every other orbit's a follows from its own bhagaṇa: a³ = (1 − cos θ⊕)/(1 − cos θ) (each a the radius the lattice orbit needs to keep the text's rate exactly). The sine is the true sine (Mādhava's series, to double precision). THE MASSES are not in the text. They are measured from the locks: each planet's mass from the pulse it raises on the others (scripts/gurutva/masses-from-locks.js), given here as μ = m/m☉.
आवश्यक · requires

What it loads

required by
nothing in the registry
निर्यात · exports

What it exports

guardMassesN_DAYSTEP_SPANDASLENH_DAYBODIESelementskeplerPossystemtuneRates
पाठ · the verses it cites

SS verses named in the header

none in the registry

नलिका · channels

The channels it runs in

not on a channel
कार्य · the functions

Every function, what it calls, who calls it

12 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.

guardMasses(mu)lines 37–45exported

Refuse a mass the Loha ledger forbids: masses-from-locks.json gives Mars NEGATIVE, Mercury 1e-12 (unresolved) and Jupiter 1/1849 (77% off the accepted 1/1047) — only Venus, Earth, Saturn are usable there; Guru/Śani come from masses-fb.json (1571.99, 5256.69).

calls nothing in the registry
called by nothing in the registry
calls nothing in the registry
called by nothing in the registry
vers(th)lines 49–49
calls nothing in the registry
called by nothing in the registry
keplerPos(el, GM, t)lines 69–76exported

heliocentric position (AU, the text's sidereal ecliptic) on the Kepler orbit at time t (days from the Kali start).

calls nothing in the registry
called by helio

The system on the lattice. masses: { mercury, venus, earth, mars, jupiter, saturn } as μ = m/m☉ (absent = 0). The seed is heliocentric Kepler at t = 0 and t = −h, moved to the barycentre (Σ μx = 0 with the Sun's μ = 1).

calls nothing in the registry
called by nothing in the registry
toLat(v)lines 87–87
calls nothing in the registry
called by nothing in the registry
helio(t)lines 88–95
calls keplerPos
called by nothing in the registry
bary(P)lines 96–96
calls nothing in the registry
called by nothing in the registry
pull()lines 102–113
calls nothing in the registry
called by step
step()lines 114–118
calls pull
called by nothing in the registry
places()lines 120–128

heliocentric ecliptic longitude (deg), latitude (deg) and distance (AU) of every body, from the integer state.

calls nothing in the registry
called by nothing in the registry

The bīja-saṃskāra of the seed: run the system `years`, fit each body's heliocentric mean motion, and scale its seed rate by n_text / n_N-body (the radius follows by Kepler, so the response is one to one); repeat until every rate is the text's to `tol`. The fit, every 10 days: λ = a + n·t + (cos, sin) of the 2:5 lock 2λ̄_Guru − 5λ̄_Śani (the great inequality, a wave of ~982 years on the text's rate

calls nothing in the registry
called by nothing in the registry