feat(core): parse P1 workbook and build T-type pier shape

- parse Excel input by header strings (pier, IP, bearing tables)
- DMS azimuth parser (E03), input validation (E01, E02)
- pure geometry: axis, bearings, stepped coping, column, footing, piles, blinding
- warnings W01, W02, W05, W07, I01
- regression tests against spec.md section 12 (P1)

Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
This commit is contained in:
ypshimandClaude Haiku 5.5 committed 2026-10-21 17:26:16 +09:00
commit d963d8ed3c
15 files changed
+2527

No files matched your search

+12
View File
@@ -0,0 +1,12 @@
const DMS = /(\d+(?:\.\d+)?)°\s*(\d+)'\s*(\d+(?:\.\d+)?)"/;
/** Parses a degree-minute-second string such as ` 75°56'55.9"` into decimal degrees. Returns null when invalid. */
export function parseDms(text: string): number | null {
const m = DMS.exec(String(text));
if (!m) return null;
const deg = Number(m[1]);
const min = Number(m[2]);
const sec = Number(m[3]);
if (min >= 60 || sec >= 60) return null;
return deg + min / 60 + sec / 3600;
}