5D Library › Horary Dignity Scoring, Sidereal Nakshatra Precession and Vimshottari Dasha Chains · 中文

Chapter 1. Essential Dignity: a Step Function of Longitude

Five dignities and three debilities

Classical astrology grades a planet’s “essential” state on the zodiac by five dignities: domicile (the signs it rules), exaltation, triplicity (the day or night ruler of the three signs of an element), term (each sign is cut into five unequal terms, each belonging to a planet) and face (three faces of 10 degrees per sign); and by three debilities: detriment (the sign opposite a domicile), fall (opposite the exaltation) and peregrine (no dignity at all). William Lilly in his Christian Astrology of 1647 gives the points: domicile 5, exaltation 4, triplicity 3, term 2, face 1; detriment −5, fall −4, peregrine −5 (Lilly 1647).

The programs implement these conventions: domicile and exaltation by sign; triplicity by Lilly’s table (fire: Sun by day, Jupiter by night; earth: Venus and Moon; air: Saturn and Mercury; water: Mars by day and by night); the “Egyptian terms” given in Ptolemy’s Tetrabiblos (Ptolemy 1940); and faces in Chaldean order beginning with Mars at 0 degrees of Aries. Signs are numbered 0 to 11 from Aries.

Calculation

# Chapter 1. p01: Essential dignities as step functions of longitude.
# Signs 0..11 from Aries. Domiciles, exaltations (by sign), triplicity
# rulers as in Lilly (fire Sun/Jupiter, earth Venus/Moon, air Saturn/
# Mercury, water Mars by day and night), the Egyptian terms (five unequal
# bounds per sign) and the faces (decans, Chaldean order from Mars).
# Points (Lilly 1647): domicile 5, exaltation 4, triplicity 3, term 2,
# face 1; detriment -5, fall -4; peregrine (no positive dignity) -5.
PL = ("Sun", "Moon", "Mercury", "Venus", "Mars", "Jupiter", "Saturn")
DOM = {"Sun": (4,), "Moon": (3,), "Mercury": (2, 5), "Venus": (1, 6),
       "Mars": (0, 7), "Jupiter": (8, 11), "Saturn": (9, 10)}
EXALT = {"Sun": 0, "Moon": 1, "Mercury": 5, "Venus": 11, "Mars": 9,
         "Jupiter": 3, "Saturn": 6}
TRIP = {0: ("Sun", "Jupiter"), 1: ("Venus", "Moon"),
        2: ("Saturn", "Mercury"), 3: ("Mars", "Mars")}
J, V, Me, Ma, S = "Jupiter", "Venus", "Mercury", "Mars", "Saturn"
TERMS = (((J, 6), (V, 6), (Me, 8), (Ma, 5), (S, 5)),
         ((V, 8), (Me, 6), (J, 8), (S, 5), (Ma, 3)),
         ((Me, 6), (J, 6), (V, 5), (Ma, 7), (S, 6)),
         ((Ma, 7), (V, 6), (Me, 6), (J, 7), (S, 4)),
         ((J, 6), (V, 5), (S, 7), (Me, 6), (Ma, 6)),
         ((Me, 7), (V, 10), (J, 4), (Ma, 7), (S, 2)),
         ((S, 6), (Me, 8), (J, 7), (V, 7), (Ma, 2)),
         ((Ma, 7), (V, 4), (Me, 8), (J, 5), (S, 6)),
         ((J, 12), (V, 5), (Me, 4), (S, 5), (Ma, 4)),
         ((Me, 7), (J, 7), (V, 8), (S, 4), (Ma, 4)),
         ((Me, 7), (V, 6), (J, 7), (Ma, 5), (S, 5)),
         ((V, 12), (J, 4), (Me, 3), (Ma, 9), (S, 2)))
CHALDEAN = ("Mars", "Sun", "Venus", "Mercury", "Moon", "Saturn", "Jupiter")

def term_ruler(lon):
    sign, deg = int(lon // 30) % 12, lon % 30
    for p, w in TERMS[sign]:
        if deg < w:
            return p
        deg -= w

def face_ruler(lon):
    return CHALDEAN[int(lon // 10) % 7]

def score(planet, lon, day=True, double=True):
    sign = int(lon // 30) % 12
    pos = 0
    pos += 5 * (sign in DOM[planet])
    pos += 4 * (sign == EXALT[planet])
    pos += 3 * (TRIP[sign % 4][0 if day else 1] == planet)
    pos += 2 * (term_ruler(lon) == planet)
    pos += 1 * (face_ruler(lon) == planet)
    neg = 5 * ((sign + 6) % 12 in DOM[planet])
    neg += 4 * ((sign + 6) % 12 == EXALT[planet])
    if pos == 0 and (double or neg == 0):
        neg += 5
    return pos - neg

if __name__ == "__main__":
    widths = [w for row in TERMS for _, w in row]
    print("   every sign's terms sum to 30: {}".format(
        all(sum(w for _, w in row) == 30 for row in TERMS)))
    print("   term widths range from {} to {} degrees".format(
        min(widths), max(widths)))
    tot = {p: sum(w for row in TERMS for q, w in row if q == p)
           for p in (S, J, Ma, V, Me)}
    print("   degrees of terms per planet: " + ", ".join(
        "{} {}".format(p, d) for p, d in list(tot.items())[:3]))
    print("                                " + ", ".join(
        "{} {}".format(p, d) for p, d in list(tot.items())[3:]))
    print("   total {} degrees".format(sum(tot.values())))
    print("   faces: 36 decans, Chaldean order from Mars at 0 Aries;"
          " last = {}".format(face_ruler(355)))
    for p, lon in (("Sun", 15.0), ("Venus", 355.0), ("Saturn", 190.0),
                   ("Mars", 185.0), ("Moon", 222.0)):
        print("   {:7s} at {:5.1f} deg: day {:3d}, night {:3d}".format(
            p, lon, score(p, lon, True), score(p, lon, False)))
#    every sign's terms sum to 30: True
#    term widths range from 2 to 12 degrees
#    degrees of terms per planet: Saturn 57, Jupiter 79, Mars 66
#                                 Venus 82, Mercury 76
#    total 360 degrees
#    faces: 36 decans, Chaldean order from Mars at 0 Aries; last = Mars
#    Sun     at  15.0 deg: day   8, night   5
#    Venus   at 355.0 deg: day   4, night   4
#    Saturn  at 190.0 deg: day   8, night   5
#    Mars    at 185.0 deg: day -10, night -10
#    Moon    at 222.0 deg: day  -9, night  -9

An irregular step function

The program first checks the tables themselves: the five terms of every sign sum to 30 degrees; the terms range from 2 to 12 degrees wide, not the four to eight degrees often quoted; and summed by planet they give Saturn 57 degrees, Jupiter 79, Mars 66, Venus 82 and Mercury 76, 360 in all.

With these tables a planet’s essential score is a step function Ep(λ)E_p(\lambda) of the longitude λ\lambda, jumping at the boundaries of signs, terms and faces. The Sun at 15 degrees of Aries, for example, scores 8 by day (exaltation 4, triplicity 3, face 1) and 5 by night; Mars at 5 degrees of Libra is in detriment, −5, and has no dignity, so peregrine adds −5, −10 in all.

The essential score of Venus and of Mars by day as a function of longitude (p01).

Expected scores are not equal

If a planet’s longitude were uniform over a long time, its expected score would be 1360∫0360Ep(λ)dλ\frac{1}{360}\int_0^{360} E_p(\lambda)\,d\lambda. Real planets are not uniform: Mars is slow near aphelion, Mercury and Venus always stay near the Sun. The program compares the two with a low-precision ephemeris (the approximate Keplerian elements of the Jet Propulsion Laboratory plus the main periodic terms of the Moon) (Standish, n.d.; Meeus 1998), first checking it against several published events: at the new moon of 6 January 2000 the Moon and Sun differ by 0.04 degrees, at the opposition of Mars on 13 October 2020 Mars and the Sun differ by 180.01 degrees, and at the great conjunction of 21 December 2020 Jupiter and Saturn differ by 0.05 degrees.

Calculation

# Chapter 1. p02: A low-precision ephemeris with daily motions.
# Planets: JPL approximate Keplerian elements, valid 1800-2050 (Standish),
# heliocentric J2000 ecliptic, made geocentric by subtracting the
# Earth-Moon barycentre, plus general precession to the equinox of date.
# Moon: the six largest terms of its longitude; node: mean node.
# Daily motion by a central difference of one day. Then: where do the
# planets actually spend their time over 1900-2049, and what does that do
# to the expected essential score of p01 (uniform longitude vs real sky)?
import importlib.util
from math import sin, cos, atan2, radians, degrees, sqrt

EL = {  # a, e, I, L, long. peri, node; then rates per Julian century
    "Mercury": (0.38709927, 0.20563593, 7.00497902, 252.25032350,
                77.45779628, 48.33076593, 0.00000037, 0.00001906,
                -0.00594749, 149472.67411175, 0.16047689, -0.12534081),
    "Venus": (0.72333566, 0.00677672, 3.39467605, 181.97909950,
              131.60246718, 76.67984255, 0.00000390, -0.00004107,
              -0.00078890, 58517.81538729, 0.00268329, -0.27769418),
    "EMB": (1.00000261, 0.01671123, -0.00001531, 100.46457166,
            102.93768193, 0.0, 0.00000562, -0.00004392, -0.01294668,
            35999.37244981, 0.32327364, 0.0),
    "Mars": (1.52371034, 0.09339410, 1.84969142, -4.55343205,
             -23.94362959, 49.55953891, 0.00001847, 0.00007882,
             -0.00813131, 19140.30268499, 0.44441088, -0.29257343),
    "Jupiter": (5.20288700, 0.04838624, 1.30439695, 34.39644051,
                14.72847983, 100.47390909, -0.00011607, -0.00013253,
                -0.00183714, 3034.74612775, 0.21252668, 0.20469106),
    "Saturn": (9.53667594, 0.05386179, 2.48599187, 49.95424423,
               92.59887831, 113.66242448, -0.00125060, -0.00050991,
               0.00193609, 1222.49362201, -0.41897216, -0.28867794),
    "Uranus": (19.18916464, 0.04725744, 0.77263783, 313.23810451,
               170.95427630, 74.01692503, -0.00196176, -0.00004397,
               -0.00242939, 428.48202785, 0.40805281, 0.04240589),
    "Neptune": (30.06992276, 0.00859048, 1.77004347, -55.12002969,
                44.96476227, 131.78422574, 0.00026291, 0.00005105,
                0.00035372, 218.45945325, -0.32241464, -0.00508664),
    "Pluto": (39.48211675, 0.24882730, 17.14001206, 238.92903833,
              224.06891629, 110.30393684, -0.00031596, 0.00005170,
              0.00004818, 145.20780515, -0.04062942, -0.01183482)}

def helio(name, T):
    v = EL[name]
    a, e, I, L, wb, Om = (v[i] + v[i + 6] * T for i in range(6))
    M = radians((L - wb + 180) % 360 - 180)
    E = M + e * sin(M)
    for _ in range(8):
        E -= (E - e * sin(E) - M) / (1 - e * cos(E))
    xp, yp = a * (cos(E) - e), a * sqrt(1 - e * e) * sin(E)
    w, Om, I = radians(wb - Om), radians(Om), radians(I)
    x = ((cos(w) * cos(Om) - sin(w) * sin(Om) * cos(I)) * xp
         + (-sin(w) * cos(Om) - cos(w) * sin(Om) * cos(I)) * yp)
    y = ((cos(w) * sin(Om) + sin(w) * cos(Om) * cos(I)) * xp
         + (-sin(w) * sin(Om) + cos(w) * cos(Om) * cos(I)) * yp)
    return x, y

def moon(d):
    Lp, D = 218.3164477 + 13.17639648 * d, 297.8501921 + 12.19074912 * d
    M, Mp = 357.5291092 + 0.98560028 * d, 134.9633964 + 13.06499295 * d
    F = 93.2720950 + 13.22935024 * d
    r = radians
    return (Lp + 6.289 * sin(r(Mp)) + 1.274 * sin(r(2 * D - Mp))
            + 0.658 * sin(r(2 * D)) + 0.214 * sin(r(2 * Mp))
            - 0.186 * sin(r(M)) - 0.114 * sin(r(2 * F))) % 360

def positions(jd):
    d = jd - 2451545.0
    T = d / 36525
    prec = 1.396971 * T
    ex, ey = helio("EMB", T)
    out = {"Sun": (degrees(atan2(-ey, -ex)) + prec) % 360}
    out["Earth"] = (out["Sun"] + 180) % 360
    out["Moon"] = moon(d)
    out["NNode"] = (125.0445479 - 0.0529537648 * d) % 360
    out["SNode"] = (out["NNode"] + 180) % 360
    for p in ("Mercury", "Venus", "Mars", "Jupiter", "Saturn", "Uranus",
              "Neptune", "Pluto"):
        x, y = helio(p, T)
        out[p] = (degrees(atan2(y - ey, x - ex)) + prec) % 360
    return out

def speed(jd, body):
    a, b = positions(jd - 0.5)[body], positions(jd + 0.5)[body]
    return (b - a + 180) % 360 - 180

def load(name):
    spec = importlib.util.spec_from_file_location(name, name + ".py")
    m = importlib.util.module_from_spec(spec)
    spec.loader.exec_module(m)
    return m

if __name__ == "__main__":
    def rel(a, b):
        return (a - b + 180) % 360 - 180
    P = positions
    nm, op, gc = P(2451550.26), P(2459136.47), P(2459205.26)
    print("   checks: Moon - Sun at new moon 2000-01-06 {:.2f};"
          " Mars - Sun at".format(rel(nm["Moon"], nm["Sun"])))
    print("   opposition 2020-10-13 {:.2f}; Jupiter - Saturn 2020-12-21"
          " {:.2f}".format(rel(op["Mars"], op["Sun"]) % 360,
                           abs(rel(gc["Jupiter"], gc["Saturn"]))))
    dig = load("p01_dignity_tables")
    N = 40000
    jds = [2415020.5 + (2469807.5 - 2415020.5) * (i + 0.5) / N
           for i in range(N)]
    pos = [positions(jd) for jd in jds]
    print("   expected essential score, uniform longitude vs sky 1900-2049")
    print("   planet    uniform day  night    sky day  night")
    grid = [i / 10 + 0.05 for i in range(3600)]
    for p in dig.PL:
        u = [sum(dig.score(p, x, d) for x in grid) / 3600
             for d in (True, False)]
        s = [sum(dig.score(p, q[p], d) for q in pos) / N
             for d in (True, False)]
        print("   {:8s}  {:10.3f} {:6.3f}   {:8.3f} {:6.3f}".format(
            p, u[0], u[1], s[0], s[1]))
#    checks: Moon - Sun at new moon 2000-01-06 0.04; Mars - Sun at
#    opposition 2020-10-13 180.01; Jupiter - Saturn 2020-12-21 0.05
#    expected essential score, uniform longitude vs sky 1900-2049
#    planet    uniform day  night    sky day  night
#    Sun           -2.306 -3.472     -2.279 -3.435
#    Moon          -3.611 -2.028     -3.617 -2.036
#    Mercury       -2.286 -1.050     -2.368 -1.106
#    Venus         -0.586 -1.878     -0.809 -2.093
#    Mars          -1.008 -1.008     -1.228 -1.228
#    Jupiter       -1.950 -0.672     -1.877 -0.627
#    Saturn        -1.211 -2.294     -0.907 -1.940

For a uniform longitude the expected score by day runs from −0.586 for Venus to −3.611 for the Moon, and by night from −0.672 for Jupiter to −3.472 for the Sun; all are negative, because the −5 of peregrine covers most of the zodiac. The Sun and Moon have only one domicile each and are given no terms, a structural handicap; Mars has the same expectation by day and by night (−1.008) because the water triplicity belongs to Mars both ways. With the real positions of 1900 to 2049 the numbers move a little: Venus by day falls to −0.809, Saturn by day rises to −0.907 and Mars falls to −1.228; the order hardly changes.

Expected essential score of each planet for a uniform longitude, by day and by night (p01, p02).

Evidence

Conclusion: essential dignity scoring is not neutral between planets. Before any chart is looked at, Venus at a random longitude expects about three points more than the Moon. When the “strength” of two planets is compared, this structural gap should be taken out first.

Summary

Essential dignity is a step function of longitude; the Egyptian terms are 2 to 12 degrees wide and total 57, 79, 66, 82 and 76 degrees for the five planets. The planets’ expected essential scores are not equal, and all are negative both for uniform longitudes and in the real sky; Venus is highest, the Moon and Sun lowest.

References

Lilly, William. 1647. Christian Astrology. Thomas Brudenell for John Partridge; Humphrey Blunden.
Meeus, Jean. 1998. Astronomical Algorithms. 2nd ed. Willmann-Bell.
Ptolemy, Claudius. 1940. Tetrabiblos. Translated by F. E. Robbins. Vol. 435. Loeb Classical Library. Harvard University Press.
Standish, E. Myles. n.d. Keplerian Elements for Approximate Positions of the Major Planets. Jet Propulsion Laboratory, Solar System Dynamics. https://ssd.jpl.nasa.gov/planets/approx_pos.html.

Fan, Y. (2026). Horary Dignity Scoring, Sidereal Nakshatra Precession and Vimshottari Dasha Chains: Reception Matrix Algebra, Ayanamsha Drift Kinetics and Non-Uniform Planetary Period Partitions [古典卜卦尊贵度积分、恒星二十七宿岁差与维姆肖塔里运限链] (Version 1.0.0). 5D Library. https://doi.org/10.5281/zenodo.24090195 · Licensed under Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International (CC BY-NC-ND 4.0).