目录文档-技术白皮书23-EFT.WP.Metrology.PathCorrection v1.0

附录A 接口参考(I80 全集)


一句话目标:汇总本卷全部 I80-* 实现绑定接口的签名、参数、返回与不变量,并给出与 TimeBase/Sync/Instrument/Cleaning 的映射与错误口径。


I. 说明与范围


II. 统一约定(命名/版本/类型/错误)

  1. 命名:动词短语 + 名词;版本字段统一 ver;方法枚举 method ∈ {...}。
  2. 单位/量纲:unit(x) 与 dim(x) 必在接口文档或元数据中出现;落盘前执行 check_dim。
  3. 哈希与追溯:.hash 以内容寻址;trace_id 幂等。
  4. 错误码 E80-*(摘录)
    • E80-001 invalid_dim(量纲不符)
    • E80-002 contract_fail(契约断言失败)
    • E80-003 not_fresh(数据新鲜度越界)
    • E80-004 coverage_insufficient(覆盖度不足)
    • E80-005 non_convergent(求解不收敛)
    • E80-006 cache_escalated_miss(多级缓存升级未命中)
    • E80-007 trace_missing(追溯信息缺失)
    • E80-008 not_idempotent(幂等性破坏)
    • E80-009 method_unsupported(不支持的方法)

III. 通用数据结构(片段,供各接口复用)

type RefCond = {

T0: number, P0: number, RH0?: number, TEC0?: number,

met?: {ver: string, ts: string}, tec?: {ver: string, ts: string},

cable_spec?: string, ver: string

}

type Gamma = { hash: string, L_gamma: number, // unit(m)

anchors: any, frame: "ECEF"|"ENU", ts: string }

type NField = { model: string, // e.g., "VMF3+NeQuick+Sellmeier"

params: any, hash: string }

type TForm = { form1: number, form2: number, delta_form: number, tol_Tarr: number } // unit(s)

type UPayload = {

u_c: number, U: number, nu_eff?: number, method: "GUM"|"MC",

u_num?: {u_q?: number, u_interp?: number, u_geom?: number, u_form?: number},

q?: [number,number]

}

type ManifestPath = {

TraceID: string, gamma: {hash: string}, RefCond: RefCond,

T_parts: any, T_form: TForm, u: UPayload,

contracts: any, tags?: string[]

}


IV. 函数清单与原型

几何与坐标

I80-31 estimate_geometry(anchors, dem, constraints) -> Gamma


介质场构建

I80-41 construct_n_field(met, tec, cable_spec, options) -> NField


对流层/电离层/多径/光纤

I80-51 model_troposphere(met, elev, f, model) -> {T_tropo: number, meta}

I80-61 model_ionosphere(TEC, f, mapping) -> {T_iono: number, meta}

I80-71 estimate_multipath(obs, geom, method) -> {T_mpath: number, tags}

I80-81 model_fiber(temp, f, cable_spec) -> {T_env: number, n_g_model: string}


射线追迹与路径积分

I80-91 solve_ray(n_field, gamma0, bc) -> Gamma

I80-101 integrate_path(n_eff, gamma, c_ref) -> {T_form: TForm}


环境融合与修正合成

I80-111 apply_env_correction(ds, RefCond) -> ds'

I80-121 compose_path_correction(parts) -> {T_corr: number, T_parts, T_form}

I80-122 assert_path_contracts(ds, rules) -> {pass: boolean, report}

I80-123 calibrate_loopback(meas, fixture) -> {T_fixed: number, meta}

I80-124 regress_inst(obs, model) -> {T_inst: number, coeffs, u}


不确定度与 guardband

I80-131 build_uncertainty_budget(parts, cov_spec) -> {x, V_x, u_num, meta}
I80-132 compute_jacobian(f, x, mode) -> {J, method} // mode ∈ {analytic, autodiff, complex-step, finite-diff}
I80-133 propagate_gum(J, V_x, u_num) -> {u_c, nu_eff, k, U, eta}
I80-134 propagate_mc(f, Px, N_mc, seeds) -> {q_L, q_U, U_MC, y_hat}
I80-135 choose_guardband(U_or_q, risk) -> {g, rule}
I80-136 assert_uncertainty_contracts(payload, rules) -> report
I80-137 emit_path_manifest_uncertainty(payload, policy) -> {ok: boolean, path}


运行时与流式

I80-141 build_exec_graph(spec) -> G
I80-142 cache_getset(layer, key, compute_fn, TTL) -> {value, meta}
I80-143 decide_fallback(context) -> {level, alpha_r, tags}
I80-144 stream_align(inputs, wm, lateness) -> aligned_streams
I80-145 run_pipeline(G, streams, policy) -> {T_corr, T_parts, delta_form, u, tags}
I80-146 publish_panel(metrics) -> ack
I80-147 emit_path_manifest(results, policy) -> ManifestPath
I80-148 emit_runtime_manifest(rt_meta, policy) -> {ok: boolean, path}


用例封装(参考实现入口)

I80-151 run_case_gnss(obs, met, TEC, geom, policy) -> {T_parts, T_corr, u, manifest}
I80-152 run_case_wr(fiber, rtt, fixed, temp_profile, cable_spec, policy) -> {T_one, T_parts, u, manifest}
I80-153 run_case_nlos(obs, geom, dem, policy) -> {T_mpath, T_corr, tags, u, manifest}


V. 跨卷接口映射

  1. TimeBase / Sync
    需要 ts/tau_mono/offset/skew/J 的读写;run_pipeline 与 emit_* 按该卷定义的时间戳策略。
  2. Instrument
    calibrate_loopback/regress_inst 与仪器延迟标定接口互通;保存校准系数与溯源编号。
  3. Cleaning
    • assert_path_contracts/assert_uncertainty_contracts 复用清洗卷的两口径与数据质量契约库;
    • estimate_multipath 的标注/隔离策略对齐清洗卷标签体系。

VI. 使用示例(最小可执行片段)

# 1) 构建几何与介质

gamma = estimate_geometry(anchors, dem, constraints)

nf = construct_n_field(met, tec, cable_spec, options)

# 2) 射线与两口径积分

gamma_ray = solve_ray(nf, gamma, bc)

Tform = integrate_path(nf, gamma_ray, c_ref)

# 3) 分项合成与不确定度

parts = {"T_geom":..., "T_med":..., "T_inst":..., "T_proc":...}

corr = compose_path_correction(parts)

J = compute_jacobian(lambda x: ..., x0, "complex-step")["J"]

u = propagate_gum(J, V_x, u_num)

# 4) 契约与发布

assert_path_contracts({...}, rules)

manifest = emit_path_manifest({...}, policy)


VII. 兼容性与版本


小结


版权与许可(CC BY 4.0)

版权声明:除另有说明外,《能量丝理论》(含文本、图表、插图、符号与公式)的著作权由作者(“屠广林”先生)享有。
许可方式:本作品采用 Creative Commons 署名 4.0 国际许可协议(CC BY 4.0)进行许可;在注明作者与来源的前提下,允许为商业或非商业目的进行复制、转载、节选、改编与再分发。
署名格式(建议):作者:“屠广林”;作品:《能量丝理论》;来源:energyfilament.org;许可证:CC BY 4.0。

首次发布: 2025-11-11|当前版本:v5.1
协议链接:https://creativecommons.org/licenses/by/4.0/