The P1 상세도 ELEVATION TABLE and 솔플레이트 TABLE are shown on the bearing card. The model does not use them (Q16). The ELEVATION table compares the drawing's coping top (EL.X − E) with the model's coping top; the difference is a constant 0.211 m on all ten bearings. The solplate table checks T1 and T2 against T ± L·|S|/2 with the 공통 규칙 T = 30 mm; all rows match. Tests check E = h1+h2+h3+h4, L and W, the T1/T2 rule, and the constant offset. Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
36 lines
1.5 KiB
TypeScript
36 lines
1.5 KiB
TypeScript
import { describe, expect, it } from 'vitest';
|
||
import { buildPier } from '../src/core/geometry';
|
||
import { BEARING_ELEVATION_REF, SOLPLATE_REF, SOLPLATE_T_RULE, solplateTs } from '../src/core/bearing-ref';
|
||
import { loadP1 } from './helpers';
|
||
|
||
describe('교량받침 reference (도면값, 읽기 전용, 1단계)', () => {
|
||
it('E = h1 + h2 + h3 + h4 on every row', () => {
|
||
for (const r of BEARING_ELEVATION_REF) expect(r.h1 + r.h2 + r.h3 + r.h4, `No ${r.no}`).toBe(r.E);
|
||
});
|
||
|
||
it('solplate L = A + 100 and W = B + 100 against the elevation row', () => {
|
||
BEARING_ELEVATION_REF.forEach((e, i) => {
|
||
expect(SOLPLATE_REF[i].L, `No ${e.no}`).toBe(e.A + 100);
|
||
expect(SOLPLATE_REF[i].W, `No ${e.no}`).toBe(e.B + 100);
|
||
});
|
||
});
|
||
|
||
it('T1 and T2 follow T ± L·|S|/2 on every row (the 검산 column)', () => {
|
||
for (const r of SOLPLATE_REF) {
|
||
const c = solplateTs(SOLPLATE_T_RULE, r.L, r.s);
|
||
expect(c.T1, `No ${r.no}`).toBe(r.T1);
|
||
expect(c.T2, `No ${r.no}`).toBe(r.T2);
|
||
}
|
||
});
|
||
|
||
it('the drawing EL.X − E sits a constant 0.211 m below the model coping top on all ten bearings (Q16 diagnostic)', () => {
|
||
const m = buildPier(loadP1());
|
||
const back = m.blocks.filter((b) => b.row === '후열');
|
||
const diffs = BEARING_ELEVATION_REF.map((r) => {
|
||
const modelTop = r.row === '전열' ? m.segments[r.no - 1].top : back[r.no - 6].bottom;
|
||
return modelTop - (r.elx - r.E / 1000);
|
||
});
|
||
for (const d of diffs) expect(d).toBeCloseTo(0.211, 2);
|
||
});
|
||
});
|