5D Library › Two-Process Sleep Architecture, Slow-Wave Glymphatic Clearance and Thermoregulatory Phase Control · 中文
Chapter 7. The Defensive Qi by Day and by Night: the Lingshu and the Sleeping Immortal
Why read these texts here
The Lingshu (the “Spiritual Pivot”, the second part of the Huangdi Neijing) contains one of the oldest explicit theories of why we sleep and wake. It is not physiology in the modern sense, and this chapter does not treat it as a precursor of the two-process model. It reads the text beside the model because the two share a structure — a quantity that circulates and a boundary it crosses — and because the text also describes, with striking accuracy, what ageing does to sleep. The correspondences below are analogies, marked as such.
Sleep as a crossing
Source text
Lingshu, “Ying Wei Sheng Hui” (The Generation and Meeting of the Nutritive and Defensive Qi).
衛氣行於陰二十五度,行於陽二十五度,分為晝夜。故氣至陽而起,至陰而止。
“The defensive qi travels twenty-five circuits in the yin and twenty-five in the yang, divided into day and night. So when the qi reaches the yang one rises, and when it reaches the yin one stops.”
Lingshu, “Kou Wen” (Oral Questions).
陽氣盡,陰氣盛,則目瞑;陰氣盡而陽氣盛,則寤矣。
“When the yang qi is exhausted and the yin qi abundant, the eyes close; when the yin qi is exhausted and the yang qi abundant, one wakes.”
Lingshu, “Da Huo Lun” (On Great Confusion).
夫衛氣者,晝日常行於陽,夜行於陰,故陽氣盡則臥,陰氣盡則寤。
“The defensive qi by day travels in the yang and by night in the yin; so when the yang qi is exhausted one lies down, and when the yin qi is exhausted one wakes.” (Hebei Medical College 1982)
Read beside Chapter 1, “when the yang qi is exhausted one lies down, when the yin qi is exhausted one wakes” has the shape of the two-process model: something is used up during waking and restored during sleep, and the transitions happen at the point of exhaustion. That is a correspondence of structure, not of mechanism: the text’s quantity circulates through channels, the model’s is a chemical pressure in the brain.
The arithmetic of fifty circuits
The fourteenth program puts the text’s units beside this book’s results.
Calculation
# Chapter 7. Arithmetic for the classical texts.
# 1. The water clock divided the day into 100 ke. The Lingshu says the
# defensive qi makes 50 circuits of the body a day, 25 in the yang by day
# and 25 in the yin by night.
# 2. Compare those units with the modern quantities this book computed: the
# length of a night's sleep (p01) and the interval between REM onsets
# (p05).
# 3. The longest single sleep the two-process model of p01 allows: start
# asleep with the highest possible pressure (S = 1) at any clock time and
# sleep until S reaches the lower threshold.
import math
TAU_D = 4.2
L0, AMP, PHASE = 0.17, 0.10, 16.0
def lower(t):
return L0 + AMP * math.cos(2 * math.pi * (t - PHASE) / 24.0)
if __name__ == "__main__":
ke = 24 * 60 / 100
circuit = 24 * 60 / 50
print(
"1. One ke = {:.1f} min; one circuit of the defensive qi = {:.1f} min"
" = {:.0f} ke".format(ke, circuit, circuit / ke)
)
print(
" 25 circuits 'in the yin' = {:.1f} h, whatever the season".format(
25 * circuit / 60
)
)
print("\n2. Against this book's modern quantities")
print(
" night in the yin (Lingshu) {:5.1f} h vs sleep in p01:"
" 7.68 h".format(25 * circuit / 60)
)
print(
" one circuit of the defensive qi {:5.1f} min".format(circuit)
)
print(" vs interval between REM onsets in p05: 92 min")
best = (0.0, 0.0)
for i in range(24 * 12):
t0 = i / 12.0
S, t = 1.0, t0
while S > lower(t):
S *= math.exp(-(1 / 60) / TAU_D)
t += 1 / 60
if t - t0 > best[1]:
best = (t0, t - t0)
print(
"\n3. Longest single sleep the two-process model allows: {:.1f} h"
"\n (starting at {:02d}:{:02d} with S = 1)".format(
best[1], int(best[0]), int(round((best[0] % 1) * 60)) % 60
)
)
print(
" A sleep of 'a hundred days and more' is {:.0f} times longer."
.format(100 * 24 / best[1])
)
# 1. One ke = 14.4 min; one circuit of the defensive qi = 28.8 min = 2 ke
# 25 circuits 'in the yin' = 12.0 h, whatever the season
#
# 2. Against this book's modern quantities
# night in the yin (Lingshu) 12.0 h vs sleep in p01: 7.68 h
# one circuit of the defensive qi 28.8 min
# vs interval between REM onsets in p05: 92 min
#
# 3. Longest single sleep the two-process model allows: 11.2 h
# (starting at 16:45 with S = 1)
# A sleep of 'a hundred days and more' is 215 times longer.With the water clock’s 100 ke to the day, one ke is 14.4 minutes and one circuit of the defensive qi is 28.8 minutes, two ke. Twenty-five circuits “in the yin” make 12.0 hours, whatever the season. Two comparisons follow, and both are negative. The text’s night is a fixed half-day, while the two-process model gives 7.68 hours of sleep. And a circuit of 28.8 minutes corresponds to nothing in the architecture of Chapter 3, whose cycle is 92 minutes. The fifty circuits are a calendar of the body, not a timetable of sleep stages, and reading the ultradian cycle into them would be wrong.
Why the old do not sleep at night
Source text
Lingshu, “Ying Wei Sheng Hui”. The Yellow Emperor asks:
老人之不夜瞑者,何氣使然?
“Why is it that old people do not sleep at night?” The answer ends:
……其營氣衰少而衛氣內伐,故晝不精,夜不瞑。
“… their nutritive qi is diminished and the defensive qi attacks within; therefore by day they are not alert, and by night they do not sleep.” (Hebei Medical College 1982)
Note
A textual variant. Some modern quotations of this passage end 夜不寐 instead of 夜不瞑; both mean “do not sleep at night”, and the reading here follows the collated edition cited.
“By day they are not alert, and by night they do not sleep” is a precise description of the weakened switch of Chapter 2. A switch with a shrinking margin holds neither state well: wake is invaded by sleep and sleep by wake. The program in Chapter 2 showed the night side (awakenings multiplied while total sleep fell by less than a tenth); the text adds the day side, which the model predicts and which is true of older adults. The text attributes it to depleted qi; the modern account attributes it, in part, to lost neurons in the switch (Lim et al. 2014). The observation is the same.
The Sleeping Immortal
Chen Tuan (陳摶, died 989), the Daoist recluse of Mount Hua whose biography stands in the “Hermits” section of the Song History (Tuo Tuo et al. 1977), became known in later tradition as the “Sleeping Immortal”, said to sleep for months at a time, and later Daoist manuals attribute sleep-practice methods to him. This book could not verify the exact wording of the Song History passage on his sleeping and therefore does not quote it; the attribution of specific sleep methods to him is, on the evidence available, later than his lifetime.
The fourteenth program’s last section asks what the two-process model allows. Starting asleep with the highest possible pressure, at the most favourable clock time, the longest single sleep it permits is 11.2 hours. A sleep of “a hundred days and more” is 215 times longer. That is not a refutation of a legend — the model describes ordinary physiology, and legends are not physiology — but it does say that if the stories describe anything real, it is not sleep in the sense this book uses the word.
Summary
The Lingshu describes sleep and waking as the defensive qi crossing between yin and yang, with sleep beginning when the yang is exhausted: a structural analogy to the two-process model, not a mechanism. Its fifty circuits make a 12.0-hour night and a 28.8-minute circuit that match neither sleep length nor the 92-minute cycle. Its account of the old — “by day not alert, by night not sleeping” — precisely describes a weakened sleep switch. The legend of Chen Tuan’s months-long sleep exceeds by two orders of magnitude the longest sleep the model allows, and the sleep methods later attributed to him cannot be traced to his lifetime.
References
Fan, Y. (2026). Two-Process Sleep Architecture, Slow-Wave Glymphatic Clearance and Thermoregulatory Phase Control: Adenosine Homeostasis, Flip-Flop Switch Bistability, Core-Distal Heat Flux and Sleep-Stage Markov Chains [双过程睡眠架构、慢波胶质淋巴清除与体温节律相位控制] (Version 1.0.0). 5D Library. https://doi.org/10.5281/zenodo.24090162 · Licensed under Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International (CC BY-NC-ND 4.0).