refactor: extract mitc4 material stiffness helpers

This commit is contained in:
NINI
2026-05-05 23:26:11 +09:00
parent 150653c3c7
commit 918e219c48
12 changed files with 715 additions and 498 deletions
+39 -2
View File
@@ -13,10 +13,47 @@ Every new agent session must read this file together with `PLAN.md` before plann
- Do not remove history unless the user explicitly asks for archival cleanup.
## Current Status
Phase 1 has a completed rebaseline execution path in `phases/1-linear-static-mitc4-rebaseline`. Steps 0 through 15 are complete, and P1R-15 recorded a pass-with-documented-gaps evaluator closeout. The follow-up architecture refactor phase in `phases/1-structure-alignment-refactor` is underway because the current production implementation is concentrated in `include/fesa/fesa.hpp` instead of the module directories documented in `docs/ARCHITECTURE.md`; P1A-00 through P1A-06 are complete, so the next step is P1A-07 MITC4 material/stiffness extraction. `quad_02_phase1.inp` is the normalized Phase 1-compatible input path for the stored `quad_02` S4 reference pair, while the original `quad_02.inp` remains preserved unsupported provenance. Core numeric aliases, DOF mapping, validation harness, model diagnostic context, the Phase 1 parser/domain subset, validation/singular diagnostics, DofManager/reaction foundation, minimum result model metadata, displacement CSV comparator foundation, MITC4 geometry/director scaffolding, MITC4 displacement/strain/tying row scaffolding, MITC4 material/transform/integration scaffolding, MITC4 stiffness/drilling/internal-force scaffolding, MITC4 patch/locking-sensitivity tests, full-space assembly, reduced projection, sparse-pattern scaffold, solver adapter injection, full-vector internal/reaction force state, active AnalysisModel construction, input-to-AnalysisState-to-U/RF result workflow, and the first stored Abaqus displacement regression have been revalidated. Full PRD Phase 1 completion still depends on the open architecture/reference gaps R-014, R-010, and R-013. The old `phases/1-linear-static-mitc4` path is historical and superseded after the MITC4 formulation reset.
Phase 1 has a completed rebaseline execution path in `phases/1-linear-static-mitc4-rebaseline`. Steps 0 through 15 are complete, and P1R-15 recorded a pass-with-documented-gaps evaluator closeout. The follow-up architecture refactor phase in `phases/1-structure-alignment-refactor` is underway because remaining Assembly and Analysis workflow code still lives in `include/fesa/fesa.hpp` instead of the module directories documented in `docs/ARCHITECTURE.md`; P1A-00 through P1A-07 are complete, so the next step is P1A-08 Assembly and Analysis workflow extraction. `quad_02_phase1.inp` is the normalized Phase 1-compatible input path for the stored `quad_02` S4 reference pair, while the original `quad_02.inp` remains preserved unsupported provenance. Core numeric aliases, DOF mapping, validation harness, model diagnostic context, the Phase 1 parser/domain subset, validation/singular diagnostics, DofManager/reaction foundation, minimum result model metadata, displacement CSV comparator foundation, MITC4 geometry/director scaffolding, MITC4 displacement/strain/tying row scaffolding, MITC4 material/transform/integration scaffolding, MITC4 stiffness/drilling/internal-force scaffolding, MITC4 patch/locking-sensitivity tests, full-space assembly, reduced projection, sparse-pattern scaffold, solver adapter injection, full-vector internal/reaction force state, active AnalysisModel construction, input-to-AnalysisState-to-U/RF result workflow, and the first stored Abaqus displacement regression have been revalidated. Full PRD Phase 1 completion still depends on the open architecture/reference gaps R-014, R-010, and R-013. The old `phases/1-linear-static-mitc4` path is historical and superseded after the MITC4 formulation reset.
## Completed Work
### 2026-05-05 - P1A-07 MITC4 material stiffness extraction completed
Author: Codex
Changed files:
- `CMakeLists.txt`
- `include/fesa/Element/Element.hpp`
- `include/fesa/Element/MITC4Kinematics.hpp`
- `include/fesa/Element/MITC4MaterialIntegration.hpp`
- `include/fesa/Element/MITC4Stiffness.hpp`
- `include/fesa/Material/MITC4PlaneStressMaterial.hpp`
- `include/fesa/Material/Material.hpp`
- `include/fesa/fesa.hpp`
- `tests/test_mitc4_stiffness_module_includes.cpp`
- `phases/1-structure-alignment-refactor/index.json`
- `PLAN.md`
- `PROGRESS.md`
Summary:
- Extracted MITC4 strain component ordering, strain vector alias, material matrix alias, plane-stress material matrix diagnostics, material-vector multiply, material-vector dot product, and material matrix transform into `include/fesa/Material/MITC4PlaneStressMaterial.hpp`.
- Extracted `2 x 2 x 2` Gauss integration points, covariant-to-local strain transform, tensor/vector conversion helpers, and MITC4 material integration sample/data construction into `include/fesa/Element/MITC4MaterialIntegration.hpp`.
- Extracted MITC4 stiffness options, local/global DOF transform, strain-row local transform, `B^T D B` accumulation, drilling stabilization, local-to-global stiffness transform, element stiffness, internal force, and `MITC4ElementKernel` into `include/fesa/Element/MITC4Stiffness.hpp`.
- Updated Element and Material facade headers so direct module includes expose the relocated MITC4 material/stiffness surface without including `fesa/fesa.hpp`.
- Reduced `include/fesa/fesa.hpp` to keep only the remaining Assembly/Analysis workflow and umbrella includes; MITC4 material/stiffness implementation bodies no longer live there.
- Preserved `drilling_stiffness_scale = 1.0e-3`, the minimum-positive-physical-local-diagonal drilling policy, `2 x 2 x 2` integration, stiffness symmetry, internal-force `K_e u_e`, and all existing MITC4 patch/locking characterization behavior.
- No parser, result schema, reference tolerance, S4R, reduced integration, hourglass, nonlinear, pressure-load, HDF5, MKL, or TBB behavior was added.
- Remaining large groups in `fesa.hpp` are Assembly helpers (`buildReducedSparsePattern`, `recoverFullReaction`, assembly/project functions) and Analysis workflow.
Verification:
- First ran `python scripts\validate_workspace.py` after adding `fesa_mitc4_stiffness_module_tests`; it failed as expected because `fesa/Element/MITC4Stiffness.hpp` did not exist yet.
- After extraction, `python scripts\validate_workspace.py` configured CMake, built `fesa_core`, `fesa_tests`, `fesa_core_module_tests`, `fesa_math_module_tests`, `fesa_io_module_tests`, `fesa_results_module_tests`, `fesa_element_module_tests`, and `fesa_mitc4_stiffness_module_tests`, and ran CTest successfully.
- CTest result: 7 test executables passed.
Follow-up:
- Continue with P1A-08 Assembly and Analysis workflow extraction.
- Keep R-014 open until P1A-09 independently accepts the final architecture alignment.
- Keep R-010 and R-013 open; this refactor does not add Abaqus RF artifacts or additional stored reference cases.
### 2026-05-05 - P1A-06 MITC4 geometry strain extraction completed
Author: Codex
@@ -1132,7 +1169,7 @@ Verification:
- `python scripts/validate_workspace.py` ran, but reported no configured validation commands.
## Known Blockers
- Phase 1 architecture is not yet accepted: production code is concentrated in `include/fesa/fesa.hpp` instead of the `src/` module layout documented in `docs/ARCHITECTURE.md`.
- Phase 1 architecture is not yet accepted: remaining Assembly and Analysis workflow code still lives in `include/fesa/fesa.hpp` instead of the module layout documented in `docs/ARCHITECTURE.md`.
- No reaction-force reference artifact exists yet under `references/`.
- The PRD target of three stored Phase 1 reference cases is not yet satisfied; only `quad_02_phase1` is an active stored displacement regression.
- The current initial `quad_01.inp` reference contains `S4R`, `Part/Assembly/Instance`, `*Density`, and `NLGEOM=YES`, so it is not a Phase 1 parser acceptance case as-is.