# DMSD Phase 3B — Prime Multiscale Local Structure

**日期：** 2026-09-30  
**狀態：** COMPLETE  
**Exact domain：** \(L_0\)–\(L_6\), i.e. primes below \(10^7\)

---

## 1. 本輪目的

Phase 3A 先建立：

\[
\texttt{EXACT\_COMPUTED},
\quad
\texttt{EXACT\_MERGED},
\quad
\texttt{UNKNOWN}.
\]

Phase 3B 才開始真正「看」質數。

但本輪所有 local-structure 指標都只作用於：

\[
L_k=[10^k,10^{k+1}),
\qquad
0\le k\le6,
\]

因為這些尺度已經 exact-computed。

我們不從 UNKNOWN 區塊生成假 histogram。

---

# 2. Normalized Local Position

對：

\[
p\in L_k,
\]

定義：

\[
\lambda_k(p)
=
\frac{p-10^k}{10^{k+1}-10^k}
=
\frac{p-10^k}{9\cdot10^k}.
\]

因此：

\[
0\le\lambda_k(p)<1.
\]

不同 decade 的 prime 可以被投影到同一個 normalized coordinate。

這讓：

\[
L_2,\;L_4,\;L_6
\]

不需要使用相同絕對數值區間，也能比較它們在各自 decade 中的相對位置。

---

# 3. Center Bias

定義：

\[
\mu_k
=
\frac1{\pi_k}
\sum_{p\in L_k}\lambda_k(p),
\]

以及：

\[
B_k=\mu_k-\frac12.
\]

若：

\[
B_k<0,
\]

代表該 finite scale 上質數平均位置偏向 decade 左半。

本輪 exact data：

| \(k\) | prime count | density | center bias |
|---:|---:|---:|---:|
| 0 | 4 | 44.444444% | -0.138889 |
| 1 | 21 | 23.333333% | -0.059259 |
| 2 | 143 | 15.888889% | -0.027840 |
| 3 | 1,061 | 11.788889% | -0.018351 |
| 4 | 8,363 | 9.292222% | -0.015020 |
| 5 | 68,906 | 7.656222% | -0.012937 |
| 6 | 586,081 | 6.512011% | -0.010933 |

在目前有限資料中：

\[
B_k<0
\]

對所有 \(k=0,\ldots,6\) 成立，而且絕對值隨 scale 增大而下降。

**這裡只記錄 finite observation，不宣稱一般定理。**

---

# 4. Prime Density

定義：

\[
d_k
=
\frac{\#(\mathbb P\cap L_k)}{|L_k|}.
\]

目前 exact scales 中，density 由：

\[
44.444444\%
\]

下降到：

\[
6.512011\%.
\]

這在 DMSD Pyramid 中提供一個很自然的 scale-level summary。

但 density 本身仍不是足以重建 prime local structure 的完整 state。

---

# 5. Local-Position Histogram

對 resolution \(R\)，將：

\[
[0,1)
\]

切成：

\[
R
\]

個 normalized bins。

定義：

\[
H_{k,R}(j)
=
\#\left\{
p\in L_k:
\frac{j}{R}
\le
\lambda_k(p)
<
\frac{j+1}{R}
\right\}.
\]

本輪計算：

\[
R=10,\;100,\;1000.
\]

這使同一 scale 可以用不同 Mathematical LOD 觀看。

---

# 6. Refinement Consistency

因為 100 與 1000 都是 10 的 refinement，

必須滿足：

\[
H_{k,10}(j)
=
\sum_{r=10j}^{10j+9}
H_{k,100}(r),
\]

以及：

\[
H_{k,100}(j)
=
\sum_{r=10j}^{10j+9}
H_{k,1000}(r).
\]

本輪：

```text
7 scales × 3 refinement relations
= 21 exact checks
```

全部：

```text
PASS
```

另做：

```text
300
```

組隨機 exact subinterval checks，
100-bin 聚合回 10-bin 也全部 PASS。

所以 histogram refinement 本身已成為 DMSD 的另一種 exact certificate：

\[
\boxed{
\text{Fine Histogram}
\rightarrow
\text{Coarse Histogram}
}
\]

必須守恆。

---

# 7. Refinement Consistency 不等於極限收斂

這點必須特別分開。

本輪證明的是：

\[
\boxed{
\text{同一 exact data 的不同 partition resolution 可以一致聚合。}
}
\]

它不是：

\[
\boxed{
H_{k,R}
\text{ 已證明在 }k\to\infty
\text{ 收斂到某極限分布。}
}
\]

因此本文使用：

**partition consistency**

而不是把它寫成 asymptotic convergence theorem。

---

# 8. Internal Prime Gaps

對同一 \(L_k\) 中排序後的質數：

\[
p_1<p_2<\cdots<p_m,
\]

定義 internal gaps：

\[
g_i=p_{i+1}-p_i.
\]

本輪不把：

\[
\text{上一個 decade 的最後 prime}
\]

與：

\[
\text{下一個 decade 的第一 prime}
\]

之間 gap 算入。

得到：

| \(k\) | mean internal gap | max internal gap |
|---:|---:|---:|
| 0 | 1.667 | 2 |
| 1 | 4.300 | 8 |
| 2 | 6.310 | 20 |
| 3 | 8.457 | 36 |
| 4 | 10.761 | 72 |
| 5 | 13.061 | 114 |
| 6 | 15.356 | 154 |

目前 finite exact data 中，mean 與 max internal gap 都隨 scale 增大。

同樣只作 finite observation。

---

# 9. Staircase 與 Pyramid 現在開始真正分工

## Pyramid

適合看：

- density by scale；
- center bias by scale；
- mean / max gap by scale；
- shape distance by scale。

## Staircase

適合看：

- normalized position histogram；
- interval-local density；
- local gaps；
- selected subblock refinement。

因此兩者不只是 UI 換方向，而是在回答不同問題：

\[
\boxed{
\text{Pyramid}=\text{scale relation}
}
\]

\[
\boxed{
\text{Staircase}=\text{within-scale sequence relation}.
}
\]

---

# 10. Adjacent-Scale Shape Distance

為了量化不同 decade 的 normalized local-position histogram 差異，
本輪對 100-bin normalized histogram 計算：

- L1 distance；
- Jensen–Shannon divergence。

結果：

| Pair | L1 | JS bits |
|---|---:|---:|
| \(L_0\to L_1\) | 2.0000 | 1.00000 |
| \(L_1\to L_2\) | 1.5524 | 0.59995 |
| \(L_2\to L_3\) | 0.4575 | 0.07675 |
| \(L_3\to L_4\) | 0.1279 | 0.00468 |
| \(L_4\to L_5\) | 0.0417 | 0.00050 |
| \(L_5\to L_6\) | 0.0144 | 0.00006 |

這是一個很強的 finite empirical pattern：

> normalized 100-bin shapes 在目前 exact scales 中越來越接近。

但仍然不能把：

\[
\text{distance decreasing for }k\le6
\]

直接改寫成：

\[
\text{distance}\to0.
\]

如果未來要提出 convergence conjecture，必須另外提出並驗證。

---

# 11. 第一個真正的 Multiscale Prime Picture

把目前 finite observations 合在一起：

1. prime density 隨 scale 下降；
2. internal mean gap 增加；
3. normalized mean position 位於 center 左側；
4. center bias magnitude 隨 scale 下降；
5. adjacent normalized histogram distance 快速下降；
6. histogram refinement 在 resolution 10/100/1000 間 exact consistent。

這是 DMSD 第一次提供：

\[
\boxed{
\text{scale statistics}
+
\text{local geometry}
+
\text{resolution algebra}
}
\]

三者同時存在的 prime view。

---

# 12. 但還不能說什麼

本輪不能宣稱：

- prime normalized distribution 已證明存在極限；
- center bias 必然趨近 0；
- adjacent-scale JS divergence 必然趨近 0；
- observed gap growth 是新 theorem；
- DMSD 本身已解決任何 prime conjecture。

本輪只建立：

\[
\boxed{
\text{可驗證的 multiscale observation machinery}.
}
\]

---

# 13. 為什麼這仍然重要

傳統線性看法通常把：

\[
1,2,3,\ldots,N
\]

放成單一序列。

DMSD 則把同一 exact prime data 重新組成：

\[
\boxed{
\text{Scale}
\times
\text{Normalized Local Position}
\times
\text{Resolution}.
}
\]

這使我們可以同時問：

- 同一尺度內的分布如何？
- 不同尺度 normalized 後是否相似？
- pattern 是 coarse-resolution artifact 嗎？
- 下一級 refinement 是否保存 parent summary？
- 某種偏移是 decimal projection 還是跨 representation 仍存在？

這才是本路線原本想做的「用尺度去看」。

---

# 14. 下一步

下一輪最值得做：

# DMSD Phase 3C — Cross-Base Prime Projection Audit

因為現在已經看到漂亮的 decimal normalized geometry。

所以必須立即問：

> 如果把 scale grammar 從 base 10 換成 base 2、base 8、base 16，哪些圖樣還存在？

需要比較：

- density；
- normalized center bias；
- local-position histogram；
- adjacent-scale shape distance；
- refinement consistency。

如果某個 phenomenon 只在 decimal decade 中漂亮，
就標為：

\[
\text{representation-sensitive}.
\]

如果跨 base 仍以相似形式存在，
才值得進一步研究是否有更深的 scale invariant。

---

# 15. 結論

DMSD Prime Layer 已從：

\[
\texttt{UNKNOWN}/\texttt{EXACT}
\]

進一步走到：

\[
\boxed{
\text{Exact Multiscale Prime Geometry}.
}
\]

目前至少可精確保存：

\[
S_k
=
(
\text{count},
\text{density},
\text{center bias},
\text{histogram},
\text{gap summary}
).
\]

並且 histogram resolution 滿足 exact refinement conservation。

因此 Phase 3B 的真正產物不是「一個新的質數規律」，

而是：

\[
\boxed{
\text{一個能分清楚 scale、position、resolution、
finite observation 與 theorem boundary 的質數觀測框架。}
}
\]

---

```text
DMSD Phase 3B: COMPLETE
Validation: PASS

Next:
DMSD Phase 3C — Cross-Base Prime Projection Audit
```
