content(app-G): 补全局部可辨识与时间退化解释
复用实切空间投影,说明有限距离模型中的幅相及未知 rate 消元。给出单有效采样和双采样单帧退化,保留 IP 块内斜率与不同帧时刻的恢复条件。 扩展现有 NumPy 确定性检查;SyncTeX 编译通过,无断引用。例子不替代实际配置验收,不增加 MC。
This commit is contained in:
@@ -224,7 +224,46 @@ def main():
|
||||
mixed_jac = np.linalg.lstsq(DESIGN, [
|
||||
mixed_motion(x, t, 1)[9]-mixed_motion(x, t, 0)[9] for t in TIMES], rcond=None)[0]
|
||||
check("mixed fixed-design OLS Jacobian", mixed_jac, finite_difference(mixed_coeff, x))
|
||||
print("PASS: synthetic local formula checks; code-side geometry and CP/IP acceptance still required.")
|
||||
# Appendix G: independent block phases remove constants, not intra-block slopes.
|
||||
for nodes, starts, expected_rank in [([0.], [0., 3.], 0),
|
||||
([0., 2.], [0.], 1),
|
||||
([0., 2.], [0., 3.], 2),
|
||||
([0., 2.], [0., 3e-4], 2)]:
|
||||
blocks, weights, centers = [], [], []
|
||||
n = np.array(nodes)
|
||||
for ell in range(2):
|
||||
f, rate = z[2:]+coefficients(x, ell)[0]
|
||||
for start in starts:
|
||||
w = geometry(x, start, ell)[0]
|
||||
a = np.exp(-2j*np.pi*ARRAY@w/WAVELENGTH)
|
||||
mu = np.kron(np.exp(2j*np.pi*((f+rate*start)*n+.5*rate*n*n)), a)
|
||||
J = np.column_stack((1j*np.repeat(n, len(a))*mu,
|
||||
1j*np.repeat(start*n+.5*n*n, len(a))*mu))
|
||||
projected = J-mu[:, None]*(mu.conj()@J/(mu.conj()@mu))[None, :]
|
||||
expected = np.column_stack((
|
||||
1j*np.repeat(n-n.mean(), len(a))*mu,
|
||||
1j*np.repeat(start*(n-n.mean())+.5*(n*n-(n*n).mean()), len(a))*mu))
|
||||
check("IP centered temporal scores", projected, expected)
|
||||
blocks.append(projected)
|
||||
weights.append(2*np.linalg.norm(projected[:, 0])**2)
|
||||
centers.append(start+(n[-1]/2))
|
||||
J = np.vstack(blocks)
|
||||
real_J = np.vstack((J.real, J.imag))*np.sqrt(2)
|
||||
assert np.linalg.matrix_rank(real_J, tol=1e-10) == expected_rank
|
||||
if len(n) == 2:
|
||||
weights, centers = np.array(weights), np.array(centers)
|
||||
I = real_J.T@real_J
|
||||
vectors = np.column_stack((np.ones(len(centers)), centers))
|
||||
check("two-sample temporal information", I, vectors.T@(weights[:, None]*vectors))
|
||||
residual = real_J[:, 0]-real_J[:, 1]*(I[1, 0]/I[1, 1])
|
||||
check("real rate Schur complement", residual@residual,
|
||||
I[0, 0]-I[0, 1]**2/I[1, 1])
|
||||
if expected_rank == 1:
|
||||
check("single-frame exact frequency/rate cancellation", J@np.array([1., -1.]),
|
||||
np.zeros(len(J)))
|
||||
elif starts[-1] < 1e-3:
|
||||
assert 0 < residual@residual/I[0, 0] < 1e-7
|
||||
print("PASS: synthetic local formula and temporal-rank checks; code-side geometry and CP/IP acceptance still required.")
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
|
||||
Reference in New Issue
Block a user