整合求解器活动监控与步长回归证据
同步远端 PNL0003 诊断和大采样网格能力,语义合并活动感知的 60 秒真停滞判定与旧后端 15 分钟兼容兜底。 纳管热路径优化、15 单元运行证据、浏览器与 API 报告,并补充北京时间更新日志和遗留问题。
This commit is contained in:
1 parent
c19cf77aee
commit
e18399c022
46 files changed
+181589
-170
No files matched your search
@@ -110,6 +110,62 @@ class TestMql8StaticRegressionTests(unittest.TestCase):
|
||||
expected["hasMechanicalStateEvents"],
|
||||
)
|
||||
|
||||
def test_contact_aware_mechanical_tolerance_plan_is_proof_gated(self) -> None:
|
||||
assert self.validation.document is not None
|
||||
system = GenericFluidSystem(
|
||||
compile_system_xml_network(self.validation.document)
|
||||
)
|
||||
reducer = system.mechanical_state_reducer
|
||||
|
||||
plan = reducer.absolute_tolerance_plan(
|
||||
1.0e-8,
|
||||
mode="contact-aware-v1",
|
||||
)
|
||||
diagnostics = plan.as_dict()
|
||||
self.assertEqual(len(plan.values), len(system.initial_state_vector()))
|
||||
self.assertEqual(diagnostics["groupCount"], 10)
|
||||
self.assertEqual(diagnostics["eligibleGroupCount"], 8)
|
||||
self.assertEqual(diagnostics["relaxedVelocityStateCount"], 8)
|
||||
self.assertEqual(diagnostics["relaxedPositionStateCount"], 0)
|
||||
|
||||
by_component = {
|
||||
group.components[0]: group
|
||||
for group in plan.groups
|
||||
}
|
||||
for index in range(1, 9):
|
||||
group = by_component[f"amesim_mecmas21_{index}"]
|
||||
self.assertTrue(group.eligible)
|
||||
self.assertEqual(group.reason, "eligibleFlexibleContact")
|
||||
self.assertAlmostEqual(group.velocity_atol, 1.0e-10)
|
||||
self.assertEqual(group.position_atol, 1.0e-12)
|
||||
self.assertAlmostEqual(
|
||||
group.minimum_damping_strength_ratio,
|
||||
10.0,
|
||||
)
|
||||
self.assertAlmostEqual(
|
||||
group.minimum_force_limited_velocity_atol,
|
||||
1.0e-10,
|
||||
)
|
||||
self.assertEqual(
|
||||
group.contacts,
|
||||
(f"amesim_lstp00a_{index}",),
|
||||
)
|
||||
for index in (9, 10):
|
||||
group = by_component[f"amesim_mecmas21_{index}"]
|
||||
self.assertFalse(group.eligible)
|
||||
self.assertEqual(group.reason, "discreteEndstop")
|
||||
self.assertEqual(group.velocity_atol, 1.0e-12)
|
||||
self.assertEqual(group.position_atol, 1.0e-12)
|
||||
|
||||
legacy = reducer.absolute_tolerance_plan(1.0e-8, mode="legacy")
|
||||
self.assertTrue(
|
||||
all(
|
||||
group.velocity_atol == 1.0e-12
|
||||
and group.position_atol == 1.0e-12
|
||||
for group in legacy.groups
|
||||
)
|
||||
)
|
||||
|
||||
def test_signal_event_schedule_is_fixed_for_every_horizon(self) -> None:
|
||||
assert self.validation.document is not None
|
||||
system = GenericFluidSystem(
|
||||
|
||||
Reference in new issue
Block a user