Complete V4.6 linear solver interface
FemLite CI / build-test (push) Has been cancelled

This commit is contained in:
shenw
2026-06-25 09:49:03 +08:00
parent 62f1293a9f
commit c2db5f59c6
16 changed files with 745 additions and 15 deletions
+5 -3
View File
@@ -76,7 +76,7 @@ src/interface C ABI 和 Fortran-C bridge
|---|---|
| `fem_precision` | 全局精度、维度、版本常量 |
| `fem_error` | 错误码和错误消息 |
| `fem_control` | 时间步、求解控制、输出控制和 V4.5 收敛/接触 gap 诊断快照 |
| `fem_control` | 时间步、求解控制、输出控制、V4.5 收敛诊断和 V4.6 线性求解器状态 |
| `fem_api` | Fortran95 公共 API |
| `fem_inp_reader` | 两遍 INP 读取主流程 |
| `fem_inp_defs` | INP 模式常量 |
@@ -214,9 +214,11 @@ fem_contact_output.f90 contact CSV 字段辅助
求解器核心文件:
- `fem_assembly_csr.f90`:DOF 获取、CSR 图案和装配。
- `fem_linear_solver_cg.f90`:Jacobi 预条件 CG。
- `fem_linear_solver_cg.f90`:线性求解器分发层、Jacobi/none 预条件、CG、BiCGSTAB 和外部求解器占位。
- `fem_solver_implicit.f90`:静力、隐式 Newmark、非线性 Newton。
V4.6 起,隐式求解器内部不再直调 CG,而是通过 `linear_solver_solve` 分发。新增线性求解器时应先在该分发层注册 method 常量、预条件支持、统计状态和模块测试,再接入 Fortran API / C ABI。
新增求解路径时应明确:
- 是否需要质量矩阵。
@@ -281,7 +283,7 @@ C ABI:
- 实现:`src/interface/fem_c_api.c`。
- Fortran-C bridge:`src/interface/fem_fortran_bridge.f90`。
C ABI 当前暴露初始化、读取、构建、显式推进、SPH 力、facet 查询、节点运动学、contact summary、contact diagnostics、contact friction summary、contact history stats 和 restart 子集。
C ABI 当前暴露初始化、读取、构建、显式推进、SPH 力、facet 查询、节点运动学、contact summary、contact diagnostics、contact friction summary、contact history stats、线性求解器设置/统计和 restart 子集。
Python 调试接口: