fix(bearing): show only the outer block margins as C4 and C5

- A 일체 pair's inner sides face the other bearing, so they are not C4 or C5:
  they are null and shown as "—" in the 배치 규칙 table.
- The table headings now describe the 교축 margins (bearing to the outer block edge).

Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
This commit is contained in:
ypshimandClaude Haiku 5.5 committed 2026-10-26 12:30:21 +09:00
1 parent 9b79083d50
commit 0708aa1354
4 files changed
+24 -12

No files matched your search

+16 -8
View File
@@ -12,10 +12,10 @@ export const PAIR_ECCENTRICITY_LIMIT_MM = 100;
export interface EdgeDistance {
no: number;
row: BlockModel['row'];
/** 교축 방향: 받침 중심에서 블록의 낮은 쪽(−n) 연단까지 (mm) = C4. */
leftMm: number;
/** 교축 방향: 받침 중심에서 블록의 높은 쪽(+n) 연단까지 (mm) = C5. */
rightMm: number;
/** 교축 방향: 받침 중심에서 블록의 낮은 쪽(−n) 연단까지 (mm) = C4. null = 쌍 안쪽 (C4·C5 아님). */
leftMm: number | null;
/** 교축 방향: 받침 중심에서 블록의 높은 쪽(+n) 연단까지 (mm) = C5. null = 쌍 안쪽 (C4·C5 아님). */
rightMm: number | null;
}
export interface PairEccentricity {
@@ -37,10 +37,18 @@ export function bearingEdgeDistances(m: PierModel): EdgeDistance[] {
const HALF_INTEGRATED = 1.25; // 2500 / 2, m
return m.blocks.map((b) => {
const host = m.integratedBlocks.find((x) => (b.row === '전열' ? x.frontNo : x.backNo) === b.no);
const half = host ? HALF_INTEGRATED : HALF_SEPARATE;
const low = host ? host.n - half : b.n - half;
const high = host ? host.n + half : b.n + half;
return { no: b.no, row: b.row, leftMm: (b.n - low) * 1000, rightMm: (high - b.n) * 1000 };
if (!host) {
return { no: b.no, row: b.row, leftMm: (HALF_SEPARATE) * 1000, rightMm: HALF_SEPARATE * 1000 };
}
// 일체: only the outer edges are C4 (front, low side) and C5 (back, high side); the inner side faces the other bearing.
const low = host.n - HALF_INTEGRATED;
const high = host.n + HALF_INTEGRATED;
return {
no: b.no,
row: b.row,
leftMm: b.row === '전열' ? (b.n - low) * 1000 : null,
rightMm: b.row === '후열' ? (high - b.n) * 1000 : null,
};
});
}