From 684d28752ac2fd011458befcb216b47aae692e3e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=8D=A2=E4=BA=AC=E6=B3=BD?= Date: Tue, 18 Aug 2026 06:44:24 +0000 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=E5=85=AB=E8=B7=AF=E4=BB=BF?= =?UTF-8?q?=E7=9C=9F=E6=9C=80=E6=96=B0=E7=89=88=E6=9C=AC=E6=96=87=E4=BB=B6?= =?UTF-8?q?test-mql-8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- tests/data/test-mql-8.json | 434 ++++++++++++++++++++++++++++++++----- tests/data/test-mql-8.xml | 98 +++++++-- 2 files changed, 458 insertions(+), 74 deletions(-) diff --git a/tests/data/test-mql-8.json b/tests/data/test-mql-8.json index c8354ed..9570e6c 100644 --- a/tests/data/test-mql-8.json +++ b/tests/data/test-mql-8.json @@ -3391,7 +3391,7 @@ "type": "simulationComponent", "position": { "x": 144, - "y": 1458 + "y": 1422 }, "data": { "label": "pneumatic_83_副本_副本_7", @@ -3446,7 +3446,7 @@ "type": "simulationComponent", "position": { "x": 198, - "y": 108 + "y": 126 }, "data": { "label": "pneumatic_69_副本", @@ -8080,6 +8080,226 @@ "rotation": 90, "mirrored": false } + }, + { + "id": "amesim_pnl0001_21", + "type": "simulationComponent", + "position": { + "x": -126, + "y": 936 + }, + "data": { + "label": "amesim_pnl0001_21", + "componentType": "amesim_pnl0001", + "modelType": "amesim_pnl0001", + "modelVersion": "0.4.0", + "ports": [ + { + "name": "port_1", + "kind": "physical", + "domain": "pneumatic", + "nominalRole": "bidirectional", + "positiveFlowDirection": "intoComponent", + "side": "left" + }, + { + "name": "port_2", + "kind": "physical", + "domain": "pneumatic", + "nominalRole": "bidirectional", + "positiveFlowDirection": "intoComponent", + "side": "right" + } + ], + "parameters": { + "gi": 1, + "diam": 0.014, + "le": 0.3, + "rr": "0.045/14", + "k": 1.35, + "kth": 0, + "extemp": 293.15, + "mode": 2, + "p0": 100000, + "T0": 293.15 + }, + "parameterUnits": { + "diam": "mm", + "le": "m", + "kth": "W/(m2*K)", + "extemp": "K", + "p0": "bar", + "T0": "K" + }, + "parameterScientificNotation": {}, + "rotation": 180, + "mirrored": false + } + }, + { + "id": "amesim_pnl0001_25", + "type": "simulationComponent", + "position": { + "x": -126, + "y": 1044 + }, + "data": { + "label": "amesim_pnl0001_21_副本", + "componentType": "amesim_pnl0001", + "modelType": "amesim_pnl0001", + "modelVersion": "0.4.0", + "ports": [ + { + "name": "port_1", + "kind": "physical", + "domain": "pneumatic", + "nominalRole": "bidirectional", + "positiveFlowDirection": "intoComponent", + "side": "left" + }, + { + "name": "port_2", + "kind": "physical", + "domain": "pneumatic", + "nominalRole": "bidirectional", + "positiveFlowDirection": "intoComponent", + "side": "right" + } + ], + "parameters": { + "gi": 1, + "diam": 0.014, + "le": 0.3, + "rr": "0.045/14", + "k": 1.35, + "kth": 0, + "extemp": 293.15, + "mode": 2, + "p0": 100000, + "T0": 293.15 + }, + "parameterUnits": { + "diam": "mm", + "le": "m", + "kth": "W/(m2*K)", + "extemp": "K", + "p0": "bar", + "T0": "K" + }, + "parameterScientificNotation": {}, + "rotation": 180, + "mirrored": false + } + }, + { + "id": "amesim_pnl0001_26", + "type": "simulationComponent", + "position": { + "x": -126, + "y": 1350 + }, + "data": { + "label": "amesim_pnl0001_21_副本_2", + "componentType": "amesim_pnl0001", + "modelType": "amesim_pnl0001", + "modelVersion": "0.4.0", + "ports": [ + { + "name": "port_1", + "kind": "physical", + "domain": "pneumatic", + "nominalRole": "bidirectional", + "positiveFlowDirection": "intoComponent", + "side": "left" + }, + { + "name": "port_2", + "kind": "physical", + "domain": "pneumatic", + "nominalRole": "bidirectional", + "positiveFlowDirection": "intoComponent", + "side": "right" + } + ], + "parameters": { + "gi": 1, + "diam": 0.014, + "le": 0.3, + "rr": "0.045/14", + "k": 1.35, + "kth": 0, + "extemp": 293.15, + "mode": 2, + "p0": 100000, + "T0": 293.15 + }, + "parameterUnits": { + "diam": "mm", + "le": "m", + "kth": "W/(m2*K)", + "extemp": "K", + "p0": "bar", + "T0": "K" + }, + "parameterScientificNotation": {}, + "rotation": 180, + "mirrored": false + } + }, + { + "id": "amesim_pnl0001_27", + "type": "simulationComponent", + "position": { + "x": -120, + "y": 1456 + }, + "data": { + "label": "amesim_pnl0001_21_副本_3", + "componentType": "amesim_pnl0001", + "modelType": "amesim_pnl0001", + "modelVersion": "0.4.0", + "ports": [ + { + "name": "port_1", + "kind": "physical", + "domain": "pneumatic", + "nominalRole": "bidirectional", + "positiveFlowDirection": "intoComponent", + "side": "left" + }, + { + "name": "port_2", + "kind": "physical", + "domain": "pneumatic", + "nominalRole": "bidirectional", + "positiveFlowDirection": "intoComponent", + "side": "right" + } + ], + "parameters": { + "gi": 1, + "diam": 0.014, + "le": 0.3, + "rr": "0.045/14", + "k": 1.35, + "kth": 0, + "extemp": 293.15, + "mode": 2, + "p0": 100000, + "T0": 293.15 + }, + "parameterUnits": { + "diam": "mm", + "le": "m", + "kth": "W/(m2*K)", + "extemp": "K", + "p0": "bar", + "T0": "K" + }, + "parameterScientificNotation": {}, + "rotation": 180, + "mirrored": false + } } ], "edges": [ @@ -8583,26 +8803,6 @@ "isContactEdge": false } }, - { - "id": "edge-amesim_pnvo001_5-port_2-amesim_p4node2_5-port_2-1786949135459", - "source": "amesim_pnvo001_5", - "target": "amesim_p4node2_5", - "sourceHandle": "port_2", - "targetHandle": "port_2", - "data": { - "isContactEdge": false - } - }, - { - "id": "edge-amesim_pnvo001_6-port_2-amesim_p4node2_6-port_2-1786949136705", - "source": "amesim_pnvo001_6", - "target": "amesim_p4node2_6", - "sourceHandle": "port_2", - "targetHandle": "port_2", - "data": { - "isContactEdge": false - } - }, { "id": "edge-amesim_p4node2_2-port_4-amesim_pnl0002_2-port_1-1786949195556", "source": "amesim_p4node2_2", @@ -8703,26 +8903,6 @@ "isContactEdge": false } }, - { - "id": "edge-amesim_pnvo001_7-port_2-amesim_p4node2_7-port_2-1786949254328", - "source": "amesim_pnvo001_7", - "target": "amesim_p4node2_7", - "sourceHandle": "port_2", - "targetHandle": "port_2", - "data": { - "isContactEdge": false - } - }, - { - "id": "edge-amesim_pnvo001_8-port_2-amesim_p4node2_8-port_2-1786949255414", - "source": "amesim_pnvo001_8", - "target": "amesim_p4node2_8", - "sourceHandle": "port_2", - "targetHandle": "port_2", - "data": { - "isContactEdge": false - } - }, { "id": "edge-contact-amesim_pnl0002_7-port_1-amesim_p4node2_7-port_4-1786949265270-0", "source": "amesim_pnl0002_7", @@ -9823,12 +10003,12 @@ "isContactEdge": false, "routePoints": [ { - "x": 19.41591581157941, - "y": 40.44776588276101 + "x": 19.87945415380198, + "y": 52.17994257325029 }, { - "x": 199.4117030876737, - "y": 40.44776588276101 + "x": 199.87521088533356, + "y": 52.17994257325029 } ] } @@ -9843,12 +10023,12 @@ "isContactEdge": false, "routePoints": [ { - "x": 134.79999999999998, - "y": 139.20000000000002 + "x": 80.32926682952949, + "y": 139.08364630171945 }, { - "x": 134.79999999999998, - "y": 164 + "x": 80.32926682952949, + "y": 181.8752425865067 } ] } @@ -9863,12 +10043,152 @@ "isContactEdge": false, "routePoints": [ { - "x": 21.41606147186677, - "y": 1600.085032474227 + "x": 21.87942245262885, + "y": 1602.5991575147043 }, { - "x": 199.4117030876737, - "y": 1600.085032474227 + "x": 199.87521088533356, + "y": 1602.5991575147043 + } + ] + } + }, + { + "id": "edge-amesim_pnl0001_21-port_1-amesim_p4node2_5-port_2-1787035169994", + "source": "amesim_pnl0001_21", + "target": "amesim_p4node2_5", + "sourceHandle": "port_1", + "targetHandle": "port_2", + "data": { + "isContactEdge": false + } + }, + { + "id": "edge-amesim_pnvo001_5-port_2-amesim_pnl0001_21-port_2-1787035172093", + "source": "amesim_pnvo001_5", + "target": "amesim_pnl0001_21", + "sourceHandle": "port_2", + "targetHandle": "port_2", + "data": { + "isContactEdge": false + } + }, + { + "id": "edge-amesim_pnvo001_8-port_2-amesim_pnl0001_27-port_2-1787035308044", + "source": "amesim_pnvo001_8", + "target": "amesim_pnl0001_27", + "sourceHandle": "port_2", + "targetHandle": "port_2", + "data": { + "isContactEdge": false, + "routePoints": [ + { + "x": -99.4, + "y": 1578 + }, + { + "x": -99.4, + "y": 1512 + } + ] + } + }, + { + "id": "edge-amesim_pnl0001_27-port_1-amesim_p4node2_8-port_2-1787035309121", + "source": "amesim_pnl0001_27", + "target": "amesim_p4node2_8", + "sourceHandle": "port_1", + "targetHandle": "port_2", + "data": { + "isContactEdge": false, + "routePoints": [ + { + "x": -8.800000000000004, + "y": 1512 + }, + { + "x": -8.800000000000004, + "y": 1449.5999999999997 + } + ] + } + }, + { + "id": "edge-amesim_pnvo001_7-port_2-amesim_pnl0001_26-port_2-1787035310228", + "source": "amesim_pnvo001_7", + "target": "amesim_pnl0001_26", + "sourceHandle": "port_2", + "targetHandle": "port_2", + "data": { + "isContactEdge": false, + "routePoints": [ + { + "x": -99.4, + "y": 1380 + }, + { + "x": -99.4, + "y": 1350 + } + ] + } + }, + { + "id": "edge-amesim_pnl0001_26-port_1-amesim_p4node2_7-port_2-1787035311875", + "source": "amesim_pnl0001_26", + "target": "amesim_p4node2_7", + "sourceHandle": "port_1", + "targetHandle": "port_2", + "data": { + "isContactEdge": false, + "routePoints": [ + { + "x": -8.800000000000004, + "y": 1350 + }, + { + "x": -8.800000000000004, + "y": 1344 + } + ] + } + }, + { + "id": "edge-amesim_pnvo001_6-port_2-amesim_pnl0001_25-port_2-1787035319037", + "source": "amesim_pnvo001_6", + "target": "amesim_pnl0001_25", + "sourceHandle": "port_2", + "targetHandle": "port_2", + "data": { + "isContactEdge": false, + "routePoints": [ + { + "x": -99.4, + "y": 1146 + }, + { + "x": -99.4, + "y": 1116 + } + ] + } + }, + { + "id": "edge-amesim_pnl0001_25-port_1-amesim_p4node2_6-port_2-1787035320205", + "source": "amesim_pnl0001_25", + "target": "amesim_p4node2_6", + "sourceHandle": "port_1", + "targetHandle": "port_2", + "data": { + "isContactEdge": false, + "routePoints": [ + { + "x": -9.800000000000004, + "y": 1116 + }, + { + "x": -9.800000000000004, + "y": 1054.8 } ] } @@ -9876,9 +10196,9 @@ ], "simulation": { "t_start": 0, - "t_stop": 0.2, - "step": 0.01, - "max_step": 0.01, + "t_stop": 5, + "step": 0.005, + "max_step": 0.005, "method": "BDF" } } \ No newline at end of file diff --git a/tests/data/test-mql-8.xml b/tests/data/test-mql-8.xml index 16e3a19..0a761be 100644 --- a/tests/data/test-mql-8.xml +++ b/tests/data/test-mql-8.xml @@ -1,6 +1,6 @@ - + @@ -1312,6 +1312,54 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -1514,14 +1562,6 @@ - - - - - - - - @@ -1562,14 +1602,6 @@ - - - - - - - - @@ -2010,5 +2042,37 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file