What does Flying Stars, Compass and Facial Ratios conclude, in numbers, about “The Lo Shu, the Flight Path and the Dihedral Group”?

Answer: Chapter 1 proves that flying-star charts are affine permutations of the cyclic group of order nine: forward and backward flights make 18 charts, exactly the dihedral group of order 18, of which only the two with 5 at the centre are magic squares. The 9 periods × 24 mountains = 216 ordinary charts fall into four classes by where the period star lands: 48 each for prosperous mountain, prosperous facing and for mountain up, water down, and 60 each for double stars at the facing and at the sitting; the class depends only on the flight directions of the mountain and facing stars, and period 9 has no prosperous ordinary chart.

Scope of the numbers: Compass errors, declinations, facial dimensions and landmark errors are illustrative parameters; chart rules follow conventions stated in the book. Marked boxes separate evidence, runnable Python programs, classical sources and hypotheses.

中文版

Data table

The numbers below are printed verbatim by the chapter's Python program and can be reproduced by running it. standard-library Python onlyprinted values that match the answer: 216, 48, 60

   check, period 8, zi sitting: mountain star 8 and facing star
   8 at the facing palace S -> shuang xing hui xiang
   period   wang-wang   shang-xia   hui xiang   hui zuo
        1           0           0          12        12
        2           6           6           6         6
        3           6           6           6         6
        4           6           6           6         6
        5          12          12           0         0
        6           6           6           6         6
        7           6           6           6         6
        8           6           6           6         6
        9           0           0          12        12
      all          48          48          60        60
   shares of 216: 0.2222, 0.2222, 0.2778, 0.2778
   period 8, wang shan wang xiang sitting mountains:
     chou xun si wei qian hai
   period 9, wang shan wang xiang sitting mountains:
     none
Reading: the four classes exhaust all 216 charts, because
a side chart flown forward always carries P to the palace
opposite its start, and flown backward keeps it there. The
class of a chart is fixed by two polarities and nothing else.
Show the full program
# Chapter 1. p02: All 216 charts and their four classes.
# A house chart for period P and sitting mountain m has three layers:
# the period chart (P in the centre, flown forward); the mountain-star
# chart, whose centre is the period-chart number n found in the
# sitting palace; and the facing-star chart, whose centre is the
# number found in the facing palace. Each side chart flies forward or
# backward by the polarity of the mountain in the same position
# (earth, heaven or man) within the palace whose Lo Shu number is n;
# when n = 5, the palace where the 5 stands is used instead. The
# twenty-four mountains are listed from ren clockwise in pinyin; the
# facing mountain is the one opposite, in the same position.
# Classes, by where the period star P falls in the two side charts:
#   wang shan wang xiang: mountain star P sits, facing star P faces;
#   shang shan xia shui: the reverse of that;
#   shuang xing hui xiang / hui zuo: both P at the facing / sitting.
import collections

LOSHU = {"SE": 4, "S": 9, "SW": 2, "E": 3, "C": 5, "W": 7,
         "NE": 8, "N": 1, "NW": 6}
PALACE_OF = {v: k for k, v in LOSHU.items()}
PATH = ["C", "NW", "W", "NE", "S", "N", "SW", "E", "SE"]
OPP = {"N": "S", "S": "N", "E": "W", "W": "E", "NE": "SW", "SW": "NE",
       "NW": "SE", "SE": "NW"}
PAL_ORDER = ["N", "NE", "E", "SE", "S", "SW", "W", "NW"]
MOUNTAINS = ("ren zi gui chou gen yin jia mao yi chen xun si bing wu "
             "ding wei kun shen geng you xin xu qian hai").split()

def norm(x):
    return (x - 1) % 9 + 1

def fly(c, sign):
    return {p: norm(c + sign * k) for k, p in enumerate(PATH)}

def polarity(number, pos):
    cardinal = number in (1, 3, 7, 9)
    return (1, -1, -1)[pos] if cardinal else (-1, 1, 1)[pos]

def side(base, pal, pos):
    n = base[pal]
    ref = LOSHU[pal] if n == 5 else n
    return fly(n, polarity(ref, pos))

def chart(period, i):
    base = fly(period, 1)
    sit = PAL_ORDER[i // 3]
    face = OPP[sit]
    return base, side(base, sit, i % 3), side(base, face, i % 3), sit, face

def category(period, i):
    base, m, f, sit, face = chart(period, i)
    if m[sit] == period and f[face] == period:
        return "wang shan wang xiang"
    if m[face] == period and f[sit] == period:
        return "shang shan xia shui"
    if m[face] == period and f[face] == period:
        return "shuang xing hui xiang"
    return "shuang xing hui zuo"

if __name__ == "__main__":
    base, m, f, sit, face = chart(8, 1)
    print("   check, period 8, zi sitting: mountain star {} and facing star"
          .format(m["S"]))
    print("   {} at the facing palace S -> {}".format(
        f["S"], category(8, 1)))
    names = ["wang shan wang xiang", "shang shan xia shui",
             "shuang xing hui xiang", "shuang xing hui zuo"]
    print("\n   period   wang-wang   shang-xia   hui xiang   hui zuo")
    tot = collections.Counter()
    for p in range(1, 10):
        c = collections.Counter(category(p, i) for i in range(24))
        tot.update(c)
        print("   {:6d} {:11d} {:11d} {:11d} {:9d}".format(
            p, *[c[n] for n in names]))
    print("   {:>6s} {:11d} {:11d} {:11d} {:9d}".format(
        "all", *[tot[n] for n in names]))
    print("\n   shares of 216: " + ", ".join(
        "{:.4f}".format(tot[n] / 216) for n in names))
    for p in (8, 9):
        ws = [MOUNTAINS[i] for i in range(24) if category(p, i) == names[0]]
        print("   period {}, wang shan wang xiang sitting mountains:"
              .format(p))
        print("     " + (" ".join(ws) if ws else "none"))
    print("\nReading: the four classes exhaust all 216 charts, because")
    print("a side chart flown forward always carries P to the palace")
    print("opposite its start, and flown backward keeps it there. The")
    print("class of a chart is fixed by two polarities and nothing else.")

Single source and citation

Fan, Y. (2026). Xuankong Flying-Star Permutations, Twenty-Four-Mountain Compass Discretization and Craniofacial Ratio Metrology (Version 1.0.0), Chapter 1: The Lo Shu, the Flight Path and the Dihedral Group. 5D Library. https://doi.org/10.5281/zenodo.24090215

DOI: 10.5281/zenodo.24090215 · Read the monograph · 5DL-B-082 · v1.0.0 · CC-BY-NC-ND-4.0

BibTeX
@book{fan2026082,
  author    = {Fan, Yafu},
  title     = {Xuankong Flying-Star Permutations, Twenty-Four-Mountain Compass Discretization and Craniofacial Ratio Metrology},
  year      = {2026},
  publisher = {5D Library},
  edition   = {1.0.0},
  doi       = {10.5281/zenodo.24090215},
  url       = {https://doi.org/10.5281/zenodo.24090215}
}

Other chapter answers in this book