关于「抽样验收:接受概率曲线、kp 规则与全检零检的边界」,《三城分布式团队协同与验收》给出的定量结论是什么?

结论:第四、五章说明,过程稳定时 kp 规则只认全检或零检,内点最优只来自缺陷率不稳定时的信息价值:先抽 15 件再决定,每批省下 38.3 个工时;值得付钱的样本是 42 件,漂移时每 2.32 个工作日抽一次。

数据口径:书中的作息、午休、成本系数、汇率波动率与价格水平均为示意参数,全部计算由书中程序生成;本书是非个人化管理建议,不构成法律或税务建议,三城劳动、税务与准证事项须由当地持牌顾问确认;书中不以城市或国籍给任何人群贴标签,也不涉及任何多层分润。 书中以标注框区分已发表的证据、可运行的 Python 计算(20 段程序)、原典与作者的假说。

English version

对照数据表

下表数字由本章 Python 程序原样打印,可重新运行复现。 程序只用 Python 标准库与结论吻合的打印值: 15, 38.3

stable p f0 f=0.25 f=0.5 f=1 best
0.0125.0 43.8 62.5 100.0 none
0.0375.0 81.2 87.5 100.0 none
0.04100.0 100.0 100.0 100.0 tie
0.05125.0 118.8 112.5 100.0 all
0.10250.0 212.5 175.0 100.0 all
unstable mix: none 95.0 h, all 100.0 h per lot
sample n5 then decide: 68.2 h
sample n10 then decide: 58.7 h
sample n15 then decide: 56.7 h
sample n40 then decide: 68.0 h
sample n80 then decide: 83.9 h
best n15 saves 38.3 h per lot against the better boundary
perfect knowledge of p per lot would cost 40.0 h
查看完整验算程序
# Chapter 4. p42: Deming's kp rule, and where partial sampling earns its keep.
# k1 = 0.5 h to inspect one deliverable, k2 = 12.5 h of downstream rework
# when a defective one escapes (illustrative), so k1 / k2 = 0.04. A lot
# has N = 200 items. Inspecting a random fraction f of a lot whose
# defect rate p is stable costs N * (f * k1 + (1 - f) * p * k2): linear
# in f, so the optimum is f = 0 or f = 1 (the all-or-none rule).
# Part two: lots come from a process that is not stable, p = 0.01 with
# probability 0.8 and p = 0.15 with probability 0.2 (mean 0.038). Plan
# "sample n, inspect the rest if any defect is found" is then compared.
import math

K1, K2, N = 0.5, 12.5, 200


def lot_cost(p, f):
    return N * (f * K1 + (1 - f) * p * K2)


print("stable p   f=0     f=0.25  f=0.5   f=1    best")
for p in (0.01, 0.03, 0.04, 0.05, 0.10):
    row = [lot_cost(p, f) for f in (0, 0.25, 0.5, 1)]
    best = "none" if p < K1 / K2 else "all" if p > K1 / K2 else "tie"
    print("  %.2f  " % p + "".join("%7.1f " % x for x in row) + best)

MIX = [(0.01, 0.8), (0.15, 0.2)]


def p_zero(n, p):
    return (1 - p) ** n


def sample_plan(n):
    terms = []
    for p, w in MIX:
        pz = p_zero(n, p)
        c = n * K1 + (1 - pz) * (N - n) * K1 + pz * (N - n) * p * K2
        terms.append(w * c)
    return math.fsum(terms)


none = MIX[0][1] * lot_cost(MIX[0][0], 0) + \
    MIX[1][1] * lot_cost(MIX[1][0], 0)
allc = N * K1
best_n = min(range(1, N), key=lambda n: (sample_plan(n), n))
print("unstable mix: none %.1f h, all %.1f h per lot" % (none, allc))
for n in (5, 10, best_n, 40, 80):
    print("  sample n=%3d then decide: %6.1f h" % (n, sample_plan(n)))
print("best n = %d saves %.1f h per lot against the better boundary" % (
    best_n, min(none, allc) - sample_plan(best_n)))
print("perfect knowledge of p per lot would cost %.1f h" % (
    math.fsum(w * lot_cost(p, 0 if p < K1 / K2 else 1) for p, w in MIX)))

唯一数据源与引用

范雅福(Fan, Y.). (2026). 《跨时区多城市分布式团队协同、异步交付核验与区域人才配置效率母典》第 4 章「抽样验收:接受概率曲线、kp 规则与全检零检的边界」(版本 1.0.0). 5D Library. DOI 待发布

DOI 待发布 · 专著页正式发布后上线(本站暂无专著页) · 5DL-B-340 · v1.0.0 · CC-BY-NC-ND-4.0

BibTeX
@book{fan2026340,
  author    = {Fan, Yafu},
  title     = {Distributed Multi-City Team Coordination, Asynchronous Deliverable Verification and Regional Talent Allocation across KL, Taipei and HCMC},
  year      = {2026},
  publisher = {5D Library},
  edition   = {1.0.0},
  note      = {DOI pending}
}

本书其他章节结论