osis-python 0.9.3__tar.gz → 0.9.4__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (124) hide show
  1. {osis_python-0.9.3/src/osis_python.egg-info → osis_python-0.9.4}/PKG-INFO +1 -1
  2. {osis_python-0.9.3 → osis_python-0.9.4/src/osis_python.egg-info}/PKG-INFO +1 -1
  3. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/__init__.py +1 -1
  4. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/material/interface.py +74 -11
  5. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/material/manager.py +95 -14
  6. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/transfer/routes.py +1 -0
  7. {osis_python-0.9.3 → osis_python-0.9.4}/tests/test_manager_field_layout.py +20 -0
  8. {osis_python-0.9.3 → osis_python-0.9.4}/tests/test_transfer.py +19 -1
  9. {osis_python-0.9.3 → osis_python-0.9.4}/LICENSE +0 -0
  10. {osis_python-0.9.3 → osis_python-0.9.4}/README.md +0 -0
  11. {osis_python-0.9.3 → osis_python-0.9.4}/pyproject.toml +0 -0
  12. {osis_python-0.9.3 → osis_python-0.9.4}/setup.cfg +0 -0
  13. {osis_python-0.9.3 → osis_python-0.9.4}/src/osis_python.egg-info/SOURCES.txt +0 -0
  14. {osis_python-0.9.3 → osis_python-0.9.4}/src/osis_python.egg-info/dependency_links.txt +0 -0
  15. {osis_python-0.9.3 → osis_python-0.9.4}/src/osis_python.egg-info/requires.txt +0 -0
  16. {osis_python-0.9.3 → osis_python-0.9.4}/src/osis_python.egg-info/top_level.txt +0 -0
  17. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/boundary/__init__.py +0 -0
  18. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/boundary/interface.py +0 -0
  19. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/boundary/manager.py +0 -0
  20. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/control/__init__.py +0 -0
  21. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/control/control.py +0 -0
  22. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/control/io.py +0 -0
  23. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/control/manager.py +0 -0
  24. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/control/nonlinear.py +0 -0
  25. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/core/__init__.py +0 -0
  26. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/core/all_func.py +0 -0
  27. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/core/apdl_sync.py +0 -0
  28. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/core/basic_manager.py +0 -0
  29. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/core/batch.py +0 -0
  30. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/core/client.py +0 -0
  31. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/core/command.py +0 -0
  32. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/core/engine.py +0 -0
  33. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/core/enums.py +0 -0
  34. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/core/exceptions.py +0 -0
  35. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/core/normalize.py +0 -0
  36. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/core/references.py +0 -0
  37. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/core/sdk.py +0 -0
  38. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/core/solver.py +0 -0
  39. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/core/sync_apdl_cli.py +0 -0
  40. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/display/__init__.py +0 -0
  41. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/display/interface.py +0 -0
  42. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/display/manager.py +0 -0
  43. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/dynamic/__init__.py +0 -0
  44. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/dynamic/load_to_mass.py +0 -0
  45. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/dynamic/manager.py +0 -0
  46. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/dynamic/modal.py +0 -0
  47. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/dynamic/seismic.py +0 -0
  48. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/element/__init__.py +0 -0
  49. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/element/interface.py +0 -0
  50. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/element/manager.py +0 -0
  51. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/general/__init__.py +0 -0
  52. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/general/interface.py +0 -0
  53. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/geometry/__init__.py +0 -0
  54. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/geometry/interface.py +0 -0
  55. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/geometry/manager.py +0 -0
  56. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/live/__init__.py +0 -0
  57. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/live/analysis.py +0 -0
  58. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/live/grade.py +0 -0
  59. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/live/lane.py +0 -0
  60. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/live/manager.py +0 -0
  61. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/load/__init__.py +0 -0
  62. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/load/environmental.py +0 -0
  63. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/load/loadcase.py +0 -0
  64. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/load/manager.py +0 -0
  65. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/load/static.py +0 -0
  66. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/load/tendon.py +0 -0
  67. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/material/__init__.py +0 -0
  68. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/node/__init__.py +0 -0
  69. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/node/interface.py +0 -0
  70. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/node/manager.py +0 -0
  71. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/post/__init__.py +0 -0
  72. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/post/combine.py +0 -0
  73. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/post/design_check.py +0 -0
  74. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/post/display.py +0 -0
  75. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/post/manager.py +0 -0
  76. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/project/__init__.py +0 -0
  77. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/project/interface.py +0 -0
  78. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/project/manager.py +0 -0
  79. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/property/__init__.py +0 -0
  80. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/property/component_thickness.py +0 -0
  81. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/property/coordinate.py +0 -0
  82. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/property/creep_shrink.py +0 -0
  83. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/property/damping.py +0 -0
  84. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/property/manager.py +0 -0
  85. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/property/pu_curve.py +0 -0
  86. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/property/strength_prog.py +0 -0
  87. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/quick_building/__init__.py +0 -0
  88. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/quick_building/interface.py +0 -0
  89. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/result/__init__.py +0 -0
  90. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/result/check.py +0 -0
  91. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/result/manager.py +0 -0
  92. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/result/routes.py +0 -0
  93. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/section/__init__.py +0 -0
  94. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/section/common.py +0 -0
  95. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/section/composite.py +0 -0
  96. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/section/manager.py +0 -0
  97. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/section/numeric.py +0 -0
  98. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/section/param.py +0 -0
  99. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/section/rebar.py +0 -0
  100. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/section/rib.py +0 -0
  101. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/section/shaped_steel.py +0 -0
  102. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/section/steel.py +0 -0
  103. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/settlement/__init__.py +0 -0
  104. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/settlement/interface.py +0 -0
  105. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/settlement/manager.py +0 -0
  106. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/stability/__init__.py +0 -0
  107. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/stability/buckling.py +0 -0
  108. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/stability/manager.py +0 -0
  109. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/stage/__init__.py +0 -0
  110. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/stage/define.py +0 -0
  111. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/stage/manager.py +0 -0
  112. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/stage/overall.py +0 -0
  113. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/thickness/__init__.py +0 -0
  114. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/thickness/interface.py +0 -0
  115. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/thickness/manager.py +0 -0
  116. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/transfer/__init__.py +0 -0
  117. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/transfer/generator.py +0 -0
  118. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/transfer/matrix.py +0 -0
  119. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/transfer/out_to_python.py +0 -0
  120. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/transfer/parser.py +0 -0
  121. {osis_python-0.9.3 → osis_python-0.9.4}/src/pyosis/transfer/split.py +0 -0
  122. {osis_python-0.9.3 → osis_python-0.9.4}/tests/test_batch.py +0 -0
  123. {osis_python-0.9.3 → osis_python-0.9.4}/tests/test_delete_occupied.py +0 -0
  124. {osis_python-0.9.3 → osis_python-0.9.4}/tests/test_project_manager.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: osis-python
3
- Version: 0.9.3
3
+ Version: 0.9.4
4
4
  Summary: A Python client library for Osis APDL
5
5
  Author-email: "CCCC Highway Consultant Co. Ltd." <support@osisbim.com>
6
6
  License-Expression: MIT
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: osis-python
3
- Version: 0.9.3
3
+ Version: 0.9.4
4
4
  Summary: A Python client library for Osis APDL
5
5
  Author-email: "CCCC Highway Consultant Co. Ltd." <support@osisbim.com>
6
6
  License-Expression: MIT
@@ -7,7 +7,7 @@ A library for extending OSIS functionality.
7
7
  A library that allows users to use CAE with great flexibility.
8
8
  """
9
9
 
10
- __version__ = "0.9.3"
10
+ __version__ = "0.9.4"
11
11
 
12
12
  from .core.engine import OSISEngine
13
13
  from .core.batch import batch, flush, batch_state, BatchError
@@ -10,8 +10,8 @@ from ..core import REGISTRY
10
10
 
11
11
  @REGISTRY.register('Material')
12
12
  def osis_material_conc(nMat: int, strName: str, eMaterialType: Literal["CONC"],
13
- eCode: Literal["JTG3362_2018", "JTGD62_2004"],
14
- eGrade: Literal["C15", "C20", "C25", "C30", "C35", "C40", "C45", "C50", "C55", "C60", "C65", "C70", "C75", "C80"],
13
+ eCode: Literal["JTG3362_2018", "JTGD62_2004", "GB50010_2002", "GB50010_2010", "Unassigned"],
14
+ eGrade: Literal["C15", "C20", "C25", "C30", "C35", "C40", "C45", "C50", "C55", "C60", "C65", "C70", "C75", "C80"] | str = "",
15
15
  nCrepShrk: int | str = "", dDmp: float = 0.05, strStrengthPrg: str = None):
16
16
  """创建或修改混凝土材料
17
17
 
@@ -22,8 +22,12 @@ def osis_material_conc(nMat: int, strName: str, eMaterialType: Literal["CONC"],
22
22
  eCode (str): 材料标准代码,不区分大小写。可选值:
23
23
  * JTG3362_2018
24
24
  * JTGD62_2004
25
+ * GB50010_2002
26
+ * GB50010_2010
27
+ * Unassigned(无规范)
25
28
  eGrade (str): 材料等级牌号,不区分大小写。根据材料类型可选:
26
29
  * C15, C20, C25, C30, C35, C40, C45, C50, C55, C60, C65, C70, C75, C80
30
+ * 选择 Unassigned(无规范)时缺省
27
31
  nCrepShrk (int): 收缩徐变特性编号,可以缺省,缺省时设为 "", 不缺省时设置为1
28
32
  dDmp (float): 材料阻尼比
29
33
  strStrengthPrg (str): 强度进展特性名称(StrengthPrg 定义),可缺省,缺省时不带该列
@@ -36,7 +40,14 @@ def osis_material_conc(nMat: int, strName: str, eMaterialType: Literal["CONC"],
36
40
  pass
37
41
 
38
42
  @REGISTRY.register('Material')
39
- def osis_material_steel(nMat: int, strName: str, eMaterialType: Literal["STEEL"], eCode: Literal["JTGD64_2015"], eGrade: Literal["Q235", "Q345", "Q390", "Q420"], dDmp: float):
43
+ def osis_material_steel(nMat: int, strName: str, eMaterialType: Literal["STEEL"],
44
+ eCode: Literal["JTGD64_2015", "GB50017_2017", "GB50018_2002", "GBT50018_2025",
45
+ "GB50017_2003", "GBJ17_1988", "JGJ99_2015", "JGJ99_1998",
46
+ "JTJ025_86", "Unassigned"],
47
+ eGrade: Literal["Q235", "Q345", "Q345GJ", "Q355", "Q390", "Q420", "Q460", "Q550",
48
+ "S280", "S350", "S550", "Grade3", "16Mn", "16Mnq", "15MnV",
49
+ "15MnVq", "A3"] | str = "",
50
+ dDmp: float = 0.0):
40
51
  """创建或修改钢材
41
52
 
42
53
  Args:
@@ -45,11 +56,19 @@ def osis_material_steel(nMat: int, strName: str, eMaterialType: Literal["STEEL"]
45
56
  eMaterialType (str): 材料类型,不区分大小写。固定为 STEEL
46
57
  eCode (str): 材料标准代码,可选值:
47
58
  * JTGD64_2015
59
+ * GB50017_2017
60
+ * GB50018_2002
61
+ * GBT50018_2025
62
+ * GB50017_2003
63
+ * GBJ17_1988
64
+ * JGJ99_2015
65
+ * JGJ99_1998
66
+ * JTJ025_86
67
+ * Unassigned(无规范)
48
68
  eGrade (str): 材料等级牌号,根据材料类型可选:
49
- * Q235
50
- * Q345
51
- * Q390
52
- * Q420
69
+ * Q235, Q345, Q345GJ, Q355, Q390, Q420, Q460, Q550
70
+ * S280, S350, S550, Grade3, 16Mn, 16Mnq, 15MnV, 15MnVq, A3
71
+ * 选择 Unassigned(无规范)时缺省
53
72
  dDmp (float): 材料阻尼比
54
73
 
55
74
  Returns:
@@ -60,7 +79,9 @@ def osis_material_steel(nMat: int, strName: str, eMaterialType: Literal["STEEL"]
60
79
  pass
61
80
 
62
81
  @REGISTRY.register('Material')
63
- def osis_material_prestressed(nMat: int, strName: str, eMaterialType: Literal["PRESTRESSED"], eCode: Literal["JTG3362_2018", "JTGD62_2004"], eGrade: str, dDmp: float):
82
+ def osis_material_prestressed(nMat: int, strName: str, eMaterialType: Literal["PRESTRESSED"],
83
+ eCode: Literal["JTG3362_2018", "JTGD62_2004", "Unassigned"],
84
+ eGrade: str = "", dDmp: float = 0.0):
64
85
  """创建或修改预应力材料。
65
86
 
66
87
  Args:
@@ -70,10 +91,12 @@ def osis_material_prestressed(nMat: int, strName: str, eMaterialType: Literal["P
70
91
  eCode (str): 材料标准代码,可选值:
71
92
  * JTG3362_2018
72
93
  * JTGD62_2004
94
+ * Unassigned(无规范)
73
95
  eGrade (str): 材料等级牌号,根据材料类型可选:
74
- * JTG3362_2018: Strand1720, Strand1860, Strand1960, Wire1470, Wire1570,
96
+ * JTG3362_2018: Strand1720, Strand1860, Strand1960, Wire1470, Wire1570,
75
97
  Wire1770, Wire1860, Rebar785, Rebar930, Rebar1080
76
98
  * JTGD62_2004: Strand1860, Wire1670, Wire1770, Rebar785, Rebar930
99
+ * 选择 Unassigned(无规范)时缺省
77
100
  dDmp (float): 材料阻尼比
78
101
 
79
102
  Returns:
@@ -84,8 +107,11 @@ def osis_material_prestressed(nMat: int, strName: str, eMaterialType: Literal["P
84
107
  pass
85
108
 
86
109
  @REGISTRY.register('Material')
87
- def osis_material_rebar(nMat: int, strName: str, eMaterialType: Literal["REBAR"], eCode: Literal["JTG3362_2018", "JTGD62_2004"],
88
- eGrade: Literal["HPB300", "HRB400", "HRBF400", "RRB400", "HRB500"] | Literal["R235", "HRB335", "HRB400", "KL400"], dDmp: float):
110
+ def osis_material_rebar(nMat: int, strName: str, eMaterialType: Literal["REBAR"],
111
+ eCode: Literal["JTG3362_2018", "JTGD62_2004", "Unassigned"],
112
+ eGrade: Literal["HPB300", "HRB400", "HRBF400", "RRB400", "HRB500"]
113
+ | Literal["R235", "HRB335", "HRB400", "KL400"] | str = "",
114
+ dDmp: float = 0.0):
89
115
  """创建或修改普通钢筋材料
90
116
 
91
117
  Args:
@@ -95,9 +121,11 @@ def osis_material_rebar(nMat: int, strName: str, eMaterialType: Literal["REBAR"]
95
121
  eCode (str): 材料标准代码,可选值:
96
122
  * JTG3362_2018
97
123
  * JTGD62_2004
124
+ * Unassigned(无规范)
98
125
  eGrade (str): 材料等级牌号,根据材料类型可选(不按照规定填写可能会有错误):
99
126
  * JTG3362_2018: HPB300, HRB400, HRBF400, RRB400, HRB500
100
127
  * JTGD62_2004: R235, HRB335, HRB400, KL400
128
+ * 选择 Unassigned(无规范)时缺省
101
129
  dDmp (float): 材料阻尼比
102
130
 
103
131
  Returns:
@@ -130,6 +158,41 @@ def osis_material_custom(nMat: int, strName: str, eMaterialType: Literal["CUSTOM
130
158
  """
131
159
  pass
132
160
 
161
+ @REGISTRY.register('MaterialMP')
162
+ def osis_material_modify_para(nMat: int, strOP: str,
163
+ eMaterialType: Literal["CONC", "STEEL", "PRESTRESSED", "REBAR"],
164
+ dE: float, dG: float, dMu: float, dExpCoeff: float,
165
+ dUnitWeight: float, dDensity: float,
166
+ fType1: float = 0.0, fType2: float = 0.0,
167
+ fType3: float = 0.0, fType4: float = 0.0):
168
+ """修改已有材料数据。
169
+
170
+ 用于在选定 Unassigned(无规范)后修改上一规范材料的弹性和设计数据。
171
+
172
+ Args:
173
+ nMat (int): 已有材料编号
174
+ strOP (str): 操作,m = 修改
175
+ eMaterialType (str): 材料类型,不区分大小写。CONC/STEEL/PRESTRESSED/REBAR
176
+ dE (float): 弹性模量(Pa)
177
+ dG (float): 剪切模量(Pa)
178
+ dMu (float): 泊松比
179
+ dExpCoeff (float): 线膨胀系数(1/摄氏度)
180
+ dUnitWeight (float): 容重(N/m3)
181
+ dDensity (float): 质量密度(kg/m3)
182
+ fType1 (float): 第一个强度值
183
+ fType2 (float): 第二个强度值
184
+ fType3 (float): 第三个强度值
185
+ fType4 (float): 第四个强度值
186
+
187
+ 混凝土 fck,fcd,ftk,ftd;钢材暂无(填0);预应力 fpk,fpd,fppd;钢筋 fsk,fsd,fssd
188
+
189
+ Returns:
190
+ tuple (bool, str):
191
+ - bool: 操作是否成功
192
+ - str: 失败原因(如果操作失败)
193
+ """
194
+ pass
195
+
133
196
  @REGISTRY.register('MaterialDel')
134
197
  def osis_material_del(nMat: int):
135
198
  """删除一个材料
@@ -21,6 +21,7 @@ from .interface import (
21
21
  osis_material_prestressed,
22
22
  osis_material_rebar,
23
23
  osis_material_custom,
24
+ osis_material_modify_para,
24
25
  osis_material_del,
25
26
  osis_material_mod,
26
27
  )
@@ -219,8 +220,8 @@ class MaterialManager(BasicManager):
219
220
  self,
220
221
  no: int | None,
221
222
  name: str,
222
- code: Literal["JTG3362_2018", "JTGD62_2004"],
223
- grade: Literal["C15", "C20", "C25", "C30", "C35", "C40", "C45", "C50", "C55", "C60", "C65", "C70", "C75", "C80"],
223
+ code: Literal["JTG3362_2018", "JTGD62_2004", "GB50010_2002", "GB50010_2010", "Unassigned"],
224
+ grade: Literal["C15", "C20", "C25", "C30", "C35", "C40", "C45", "C50", "C55", "C60", "C65", "C70", "C75", "C80"] | str = "",
224
225
  crep_shrk: int | str = "",
225
226
  dmp: float = 0.05,
226
227
  strength_prog: str = None,
@@ -233,9 +234,12 @@ class MaterialManager(BasicManager):
233
234
  code: 材料标准代码,可选值:
234
235
  - JTG3362_2018
235
236
  - JTGD62_2004
237
+ - GB50010_2002
238
+ - GB50010_2010
239
+ - Unassigned(无规范)
236
240
  grade: 材料等级牌号,可选值:
237
- C15, C20, C25, C30, C35, C40, C45, C50, C55, C60, C65, C70, C75, C80
238
- no: 材料编号,不指定时自动生成(取最大编号+1)
241
+ C15, C20, C25, C30, C35, C40, C45, C50, C55, C60, C65, C70, C75, C80;
242
+ 选择 Unassigned(无规范)时缺省
239
243
  crep_shrk: 收缩徐变特性编号,可缺省
240
244
  dmp: 材料阻尼比
241
245
  strength_prog: 强度进展特性名称(StrengthPrg 定义),None 时不带该列
@@ -257,8 +261,12 @@ class MaterialManager(BasicManager):
257
261
  self,
258
262
  no: int | None,
259
263
  name: str,
260
- code: Literal["JTGD64_2015"],
261
- grade: Literal["Q235", "Q345", "Q390", "Q420"],
264
+ code: Literal["JTGD64_2015", "GB50017_2017", "GB50018_2002", "GBT50018_2025",
265
+ "GB50017_2003", "GBJ17_1988", "JGJ99_2015", "JGJ99_1998",
266
+ "JTJ025_86", "Unassigned"],
267
+ grade: Literal["Q235", "Q345", "Q345GJ", "Q355", "Q390", "Q420", "Q460", "Q550",
268
+ "S280", "S350", "S550", "Grade3", "16Mn", "16Mnq", "15MnV",
269
+ "15MnVq", "A3"] | str = "",
262
270
  dmp: float = 0.0,
263
271
 
264
272
  ) -> Material:
@@ -269,11 +277,19 @@ class MaterialManager(BasicManager):
269
277
  name: 材料名称
270
278
  code: 材料标准代码,可选值:
271
279
  - JTGD64_2015
280
+ - GB50017_2017
281
+ - GB50018_2002
282
+ - GBT50018_2025
283
+ - GB50017_2003
284
+ - GBJ17_1988
285
+ - JGJ99_2015
286
+ - JGJ99_1998
287
+ - JTJ025_86
288
+ - Unassigned(无规范)
272
289
  grade: 材料等级牌号,根据材料类型可选:
273
- - Q235
274
- - Q345
275
- - Q390
276
- - Q420
290
+ - Q235, Q345, Q345GJ, Q355, Q390, Q420, Q460, Q550
291
+ - S280, S350, S550, Grade3, 16Mn, 16Mnq, 15MnV, 15MnVq, A3
292
+ - 选择 Unassigned(无规范)时缺省
277
293
  dmp: 材料阻尼比
278
294
 
279
295
  Returns:
@@ -296,8 +312,8 @@ class MaterialManager(BasicManager):
296
312
  self,
297
313
  no: int | None,
298
314
  name: str,
299
- code: Literal["JTG3362_2018", "JTGD62_2004"],
300
- grade: str,
315
+ code: Literal["JTG3362_2018", "JTGD62_2004", "Unassigned"],
316
+ grade: str = "",
301
317
  dmp: float = 0.0,
302
318
 
303
319
  ) -> Material:
@@ -309,10 +325,12 @@ class MaterialManager(BasicManager):
309
325
  code: 材料标准代码,可选值:
310
326
  - JTG3362_2018
311
327
  - JTGD62_2004
328
+ - Unassigned(无规范)
312
329
  grade: 材料等级牌号,根据材料标准可选:
313
330
  - JTG3362_2018: Strand1720, Strand1860, Strand1960, Wire1470, Wire1570,
314
331
  Wire1770, Wire1860, Rebar785, Rebar930, Rebar1080
315
332
  - JTGD62_2004: Strand1860, Wire1670, Wire1770, Rebar785, Rebar930
333
+ - 选择 Unassigned(无规范)时缺省
316
334
  dmp: 材料阻尼比
317
335
 
318
336
  Returns:
@@ -335,8 +353,9 @@ class MaterialManager(BasicManager):
335
353
  self,
336
354
  no: int | None,
337
355
  name: str,
338
- code: Literal["JTG3362_2018", "JTGD62_2004"],
339
- grade: Literal["HPB300", "HRB400", "HRBF400", "RRB400", "HRB500"] | Literal["R235", "HRB335", "HRB400", "KL400"],
356
+ code: Literal["JTG3362_2018", "JTGD62_2004", "Unassigned"],
357
+ grade: Literal["HPB300", "HRB400", "HRBF400", "RRB400", "HRB500"]
358
+ | Literal["R235", "HRB335", "HRB400", "KL400"] | str = "",
340
359
  dmp: float = 0.0,
341
360
  ) -> Material:
342
361
  """创建钢筋材料。
@@ -347,9 +366,11 @@ class MaterialManager(BasicManager):
347
366
  code: 材料标准代码,可选值:
348
367
  - JTG3362_2018
349
368
  - JTGD62_2004
369
+ - Unassigned(无规范)
350
370
  grade: 材料等级牌号,根据材料类型可选(不按照规定填写可能会有错误):
351
371
  - JTG3362_2018: HPB300, HRB400, HRBF400, RRB400, HRB500
352
372
  - JTGD62_2004: R235, HRB335, HRB400, KL400
373
+ - 选择 Unassigned(无规范)时缺省
353
374
  dmp: 材料阻尼比
354
375
 
355
376
  Returns:
@@ -416,6 +437,66 @@ class MaterialManager(BasicManager):
416
437
  raise RuntimeError(f"创建自定义材料 {no} 失败: {err}")
417
438
  return self.get(no)
418
439
 
440
+ def modify_para(
441
+ self,
442
+ no: int | None,
443
+ op: str,
444
+ type: Literal["CONC", "STEEL", "PRESTRESSED", "REBAR"],
445
+ e: float,
446
+ g: float,
447
+ mu: float,
448
+ exp_coeff: float,
449
+ unit_weight: float,
450
+ density: float,
451
+ f_type1: float = 0.0,
452
+ f_type2: float = 0.0,
453
+ f_type3: float = 0.0,
454
+ f_type4: float = 0.0,
455
+ ) -> Material:
456
+ """修改已有材料数据(对应命令流 MaterialMP)。
457
+
458
+ 用于在选定 Unassigned(无规范)后修改上一规范材料的弹性和设计数据。
459
+ 形参顺序与命令流一致:
460
+ MaterialMP, Index, OP, Type, E, G, Mu, ExpCoeff, UnitWeight, Density,
461
+ fType1, fType2, fType3, fType4
462
+
463
+ Args:
464
+ no: 已有材料编号
465
+ op: 操作,m = 修改
466
+ type: 材料类型
467
+ - CONC = 混凝土
468
+ - STEEL = 钢材
469
+ - PRESTRESSED = 预应力材料
470
+ - REBAR = 普通钢筋
471
+ e: 弹性模量(Pa)
472
+ g: 剪切模量(Pa)
473
+ mu: 泊松比
474
+ exp_coeff: 线膨胀系数(1/摄氏度)
475
+ unit_weight: 容重(N/m3)
476
+ density: 质量密度(kg/m3)
477
+ f_type1: 第一个强度值
478
+ f_type2: 第二个强度值
479
+ f_type3: 第三个强度值
480
+ f_type4: 第四个强度值
481
+
482
+ 混凝土 fck,fcd,ftk,ftd;钢材暂无(填0);
483
+ 预应力 fpk,fpd,fppd;钢筋 fsk,fsd,fssd
484
+
485
+ Returns:
486
+ 修改后的材料对象
487
+
488
+ Raises:
489
+ RuntimeError: 修改失败时抛出异常
490
+ """
491
+ ok, err = osis_material_modify_para(
492
+ no, op, str(type).upper(),
493
+ e, g, mu, exp_coeff, unit_weight, density,
494
+ f_type1, f_type2, f_type3, f_type4,
495
+ )
496
+ if not ok:
497
+ raise RuntimeError(f"修改材料 {no} 参数失败: {err}")
498
+ return self.get(no)
499
+
419
500
  def delete(self, no: int) -> None:
420
501
  """删除材料
421
502
 
@@ -70,6 +70,7 @@ ROUTES = {
70
70
 
71
71
  # ─── MATERIAL ───
72
72
  "Material": "engine.material.create",
73
+ "MaterialMP": "engine.material.modify_para",
73
74
  "MaterialDel": "engine.material.delete",
74
75
  "MaterialMod": "engine.material.renumber",
75
76
 
@@ -18,6 +18,7 @@ import pyosis.boundary.manager as bm
18
18
  import pyosis.dynamic.manager as dm
19
19
  import pyosis.live.manager as lvm
20
20
  import pyosis.load.manager as lm
21
+ import pyosis.material.manager as mm
21
22
  import pyosis.property.strength_prog as sp
22
23
  import pyosis.section.manager as sm
23
24
  import pyosis.stability.manager as stm
@@ -56,6 +57,25 @@ def _manager(cls, **stub):
56
57
  return obj
57
58
 
58
59
 
60
+ # ── 材料 ──────────────────────────────────────────────────────
61
+
62
+ def test_material_unassigned_and_modify_para():
63
+ """无规范材料 Grade 缺省;MaterialMP 字段序与命令流一致"""
64
+ m = _manager(mm.MaterialManager, get=lambda n: n)
65
+ with capture(mm, "osis_material_conc", "osis_material_modify_para"):
66
+ m.create_conc(1, "自定义混凝土", "Unassigned", "", "", 0.05)
67
+ m.modify_para(
68
+ 1, "m", "CONC", 3.45e10, 1.5e10, 0.2, 1e-5, 25000.0, 2550.0,
69
+ 20.0, 18.0, 1.8, 1.5,
70
+ )
71
+ assert CAPTURED == [
72
+ "Material,1,自定义混凝土,CONC,Unassigned,,,0.05;",
73
+ "MaterialMP,1,m,CONC,34500000000.0,15000000000.0,0.2,1e-05,"
74
+ "25000.0,2550.0,20.0,18.0,1.8,1.5;",
75
+ ], CAPTURED
76
+ CAPTURED.clear()
77
+
78
+
59
79
  # ── 截面 ──────────────────────────────────────────────────────
60
80
 
61
81
  def _section(no: int = 1):
@@ -138,8 +138,26 @@ def test_pre_tendon_has_no_pipe_placeholder():
138
138
  ], lines
139
139
 
140
140
 
141
- # ── 自定义钢梁截面(参数板)────────────────────────────────────
141
+ # ── 材料 ──────────────────────────────────────────────────────
142
+
143
+ def test_material_unassigned_grade_empty():
144
+ """无规范材料: Grade 缺省(空列),其余字段原序"""
145
+ lines = _gen("Mat,1,自定义混凝土,CONC,Unassigned,,,0.05;\n")
146
+ assert lines == [
147
+ 'engine.material.create(1, "自定义混凝土", "CONC", "Unassigned", "", "", 0.05)'
148
+ ], lines
149
+
142
150
 
151
+ def test_material_modify_para():
152
+ """MaterialMP 字段序与命令流一致"""
153
+ lines = _gen("MaterialMP,1,m,CONC,3.45e10,1.5e10,0.2,1e-5,25000,2550,20,18,1.8,1.5;\n")
154
+ assert lines == [
155
+ 'engine.material.modify_para(1, "m", "CONC", 34500000000.0, '
156
+ '15000000000.0, 0.2, 1e-05, 25000, 2550, 20, 18, 1.8, 1.5)'
157
+ ], lines
158
+
159
+
160
+ # ── 自定义钢梁截面(参数板)────────────────────────────────────
143
161
  def test_steel_plate_mother_form():
144
162
  """SteelPlate 母板形式: PlateID, Type, 几何, 厚度"""
145
163
  lines = _gen("SteelPlate,2,1,Top,0,0,1,0,0.02;\n")
File without changes
File without changes
File without changes
File without changes