qtmodel 0.6.3__tar.gz → 0.6.5__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.
Potentially problematic release.
This version of qtmodel might be problematic. Click here for more details.
- {qtmodel-0.6.3 → qtmodel-0.6.5}/PKG-INFO +154 -10
- {qtmodel-0.6.3 → qtmodel-0.6.5}/README.md +152 -8
- {qtmodel-0.6.3 → qtmodel-0.6.5}/qtmodel/qt_mdb.py +76 -2
- {qtmodel-0.6.3 → qtmodel-0.6.5}/qtmodel/qt_odb.py +152 -9
- {qtmodel-0.6.3 → qtmodel-0.6.5}/qtmodel.egg-info/PKG-INFO +154 -10
- {qtmodel-0.6.3 → qtmodel-0.6.5}/setup.py +1 -1
- {qtmodel-0.6.3 → qtmodel-0.6.5}/qtmodel/__init__.py +0 -0
- {qtmodel-0.6.3 → qtmodel-0.6.5}/qtmodel/qt_db.py +0 -0
- {qtmodel-0.6.3 → qtmodel-0.6.5}/qtmodel.egg-info/SOURCES.txt +0 -0
- {qtmodel-0.6.3 → qtmodel-0.6.5}/qtmodel.egg-info/dependency_links.txt +0 -0
- {qtmodel-0.6.3 → qtmodel-0.6.5}/qtmodel.egg-info/top_level.txt +0 -0
- {qtmodel-0.6.3 → qtmodel-0.6.5}/setup.cfg +0 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: qtmodel
|
|
3
|
-
Version: 0.6.
|
|
4
|
-
Summary: python modeling for qt 2025-01-
|
|
3
|
+
Version: 0.6.5
|
|
4
|
+
Summary: python modeling for qt 2025-01-23
|
|
5
5
|
Home-page: https://github.com/Inface0443/pyqt
|
|
6
6
|
Author: dqy-zhj
|
|
7
7
|
Author-email: 1105417715@qq.com
|
|
@@ -12,9 +12,9 @@ Classifier: Programming Language :: Python :: 3
|
|
|
12
12
|
Classifier: Operating System :: OS Independent
|
|
13
13
|
Description-Content-Type: text/markdown
|
|
14
14
|
|
|
15
|
-
> 最新版本 V0.6.
|
|
15
|
+
> 最新版本 V0.6.5 - 2025-01-23
|
|
16
16
|
> pip install --upgrade qtmodel -i https://pypi.org/simple
|
|
17
|
-
-
|
|
17
|
+
- 新增部分接口
|
|
18
18
|
# 建模操作
|
|
19
19
|
## 项目管理
|
|
20
20
|
### undo_model
|
|
@@ -2125,7 +2125,6 @@ from qtmodel import *
|
|
|
2125
2125
|
mdb.add_custom_temperature(case_name="荷载工况1",element_id=1,orientation=1,temperature_data=[(1,1,20),(1,2,10)])
|
|
2126
2126
|
```
|
|
2127
2127
|
Returns: 无
|
|
2128
|
-
## 静力荷载操作
|
|
2129
2128
|
### remove_custom_temperature
|
|
2130
2129
|
删除梁单元自定义温度
|
|
2131
2130
|
> 参数:
|
|
@@ -2659,6 +2658,58 @@ from qtmodel import *
|
|
|
2659
2658
|
mdb.remove_construction_stage(name="施工阶段1")
|
|
2660
2659
|
```
|
|
2661
2660
|
Returns: 无
|
|
2661
|
+
### add_section_connection_stage
|
|
2662
|
+
添加施工阶段联合截面
|
|
2663
|
+
> 参数:
|
|
2664
|
+
> name:名称
|
|
2665
|
+
> sec_id:截面号
|
|
2666
|
+
> ele_id:单元号,支持整型和整型列表
|
|
2667
|
+
> stage_name:结合阶段名
|
|
2668
|
+
> age:材龄
|
|
2669
|
+
> weight_type:辅材计自重方式 0-由主材承担 1-由整体承担 2-不计辅材自重
|
|
2670
|
+
```Python
|
|
2671
|
+
# 示例代码
|
|
2672
|
+
from qtmodel import *
|
|
2673
|
+
mdb.add_section_connection_stage(name="联合阶段",sec_id=1,ele_id=[2,3,4,5],stage_name="施工阶段1")
|
|
2674
|
+
```
|
|
2675
|
+
Returns:无
|
|
2676
|
+
### update_section_connection_stage
|
|
2677
|
+
更新施工阶段联合截面
|
|
2678
|
+
> 参数:
|
|
2679
|
+
> name:名称
|
|
2680
|
+
> new_name:新名称
|
|
2681
|
+
> sec_id:截面号
|
|
2682
|
+
> ele_id:单元号,支持整型和整型列表
|
|
2683
|
+
> stage_name:结合阶段名
|
|
2684
|
+
> age:材龄
|
|
2685
|
+
> weight_type:辅材计自重方式 0-由主材承担 1-由整体承担 2-不计辅材自重
|
|
2686
|
+
```Python
|
|
2687
|
+
# 示例代码
|
|
2688
|
+
from qtmodel import *
|
|
2689
|
+
mdb.update_section_connection_stage(name="联合阶段",sec_id=1,ele_id=[2,3,4,5],stage_name="施工阶段1")
|
|
2690
|
+
```
|
|
2691
|
+
Returns:无
|
|
2692
|
+
### remove_section_connection_stage
|
|
2693
|
+
删除施工阶段联合截面
|
|
2694
|
+
> 参数:
|
|
2695
|
+
> name:名称
|
|
2696
|
+
```Python
|
|
2697
|
+
# 示例代码
|
|
2698
|
+
from qtmodel import *
|
|
2699
|
+
mdb.remove_section_connection_stage(name="联合阶段")
|
|
2700
|
+
```
|
|
2701
|
+
Returns:无
|
|
2702
|
+
### add_element_to_connection_stage
|
|
2703
|
+
添加单元到施工阶段联合截面
|
|
2704
|
+
> 参数:
|
|
2705
|
+
> ele_id:单元号
|
|
2706
|
+
> name:联合阶段名
|
|
2707
|
+
```Python
|
|
2708
|
+
# 示例代码
|
|
2709
|
+
from qtmodel import *
|
|
2710
|
+
mdb.add_element_to_connection_stage([1,2,3,4],"联合阶段")
|
|
2711
|
+
```
|
|
2712
|
+
Returns:无
|
|
2662
2713
|
## 荷载组合操作
|
|
2663
2714
|
### add_load_combine
|
|
2664
2715
|
添加荷载组合
|
|
@@ -2878,6 +2929,51 @@ odb.get_node_displacement(node_id=[1,2,3],stage_id=1)
|
|
|
2878
2929
|
odb.get_node_displacement(node_id=1,stage_id=-1,case_name="工况名")
|
|
2879
2930
|
```
|
|
2880
2931
|
Returns: json字符串,包含信息为list[dict] or dict
|
|
2932
|
+
### get_self_concurrent_reaction
|
|
2933
|
+
获取自并发反力
|
|
2934
|
+
> 参数:
|
|
2935
|
+
> node_id:节点号
|
|
2936
|
+
> case_name:工况号
|
|
2937
|
+
```Python
|
|
2938
|
+
# 示例代码
|
|
2939
|
+
from qtmodel import *
|
|
2940
|
+
odb.get_self_concurrent_reaction(node_id=1,case_name="工况1_Fx最大")
|
|
2941
|
+
```
|
|
2942
|
+
Returns: json字符串,包含信息为dict
|
|
2943
|
+
### get_all_concurrent_reaction
|
|
2944
|
+
获取完全并发反力
|
|
2945
|
+
> 参数:
|
|
2946
|
+
> node_id:节点号
|
|
2947
|
+
> case_name:工况号
|
|
2948
|
+
```Python
|
|
2949
|
+
# 示例代码
|
|
2950
|
+
from qtmodel import *
|
|
2951
|
+
odb.get_all_concurrent_reaction(node_id=1,case_name="工况1_Fx最大")
|
|
2952
|
+
```
|
|
2953
|
+
Returns: json字符串,包含信息为dict
|
|
2954
|
+
### get_beam_concurrent_force
|
|
2955
|
+
获取梁单元并发内力
|
|
2956
|
+
> 参数:
|
|
2957
|
+
> ele_id:单元号
|
|
2958
|
+
> case_name:工况号
|
|
2959
|
+
```Python
|
|
2960
|
+
# 示例代码
|
|
2961
|
+
from qtmodel import *
|
|
2962
|
+
odb.get_beam_concurrent_force(ele_id=1,case_name="工况1_Fx最大")
|
|
2963
|
+
```
|
|
2964
|
+
Returns: json字符串,包含信息为dict
|
|
2965
|
+
### get_composite_beam_concurrent_force
|
|
2966
|
+
获取组合梁单元并发内力
|
|
2967
|
+
> 参数:
|
|
2968
|
+
> ele_id:单元号
|
|
2969
|
+
> case_name:工况号
|
|
2970
|
+
```Python
|
|
2971
|
+
# 示例代码
|
|
2972
|
+
from qtmodel import *
|
|
2973
|
+
odb.get_composite_beam_concurrent_force(ele_id=1,case_name="工况1_Fx最大")
|
|
2974
|
+
```
|
|
2975
|
+
Returns: json字符串,包含信息为dict
|
|
2976
|
+
## 动力结果查看
|
|
2881
2977
|
### get_vibration_node_displacement
|
|
2882
2978
|
获取指定节点指定模态的振型向量
|
|
2883
2979
|
> 参数:
|
|
@@ -2889,6 +2985,36 @@ from qtmodel import *
|
|
|
2889
2985
|
odb.get_vibration_node_displacement(node_id=1,mode=1)
|
|
2890
2986
|
```
|
|
2891
2987
|
Returns: json字符串,包含信息为list[dict] or dict
|
|
2988
|
+
### get_period_and_frequency
|
|
2989
|
+
获取周期和频率
|
|
2990
|
+
> 参数:
|
|
2991
|
+
> mode:模态号
|
|
2992
|
+
```Python
|
|
2993
|
+
# 示例代码
|
|
2994
|
+
from qtmodel import *
|
|
2995
|
+
odb.get_period_and_frequency(mode=1)
|
|
2996
|
+
```
|
|
2997
|
+
Returns: json字符串,包含信息为dict
|
|
2998
|
+
### get_participation_mass
|
|
2999
|
+
获取振型参与质量百分比
|
|
3000
|
+
> 参数:
|
|
3001
|
+
> mode:模态号
|
|
3002
|
+
```Python
|
|
3003
|
+
# 示例代码
|
|
3004
|
+
from qtmodel import *
|
|
3005
|
+
odb.get_participation_mass(mode=1)
|
|
3006
|
+
```
|
|
3007
|
+
Returns: json字符串,包含信息为dict
|
|
3008
|
+
### get_participation_factor
|
|
3009
|
+
获取振型参与质量系数
|
|
3010
|
+
> 参数:
|
|
3011
|
+
> mode:模态号
|
|
3012
|
+
```Python
|
|
3013
|
+
# 示例代码
|
|
3014
|
+
from qtmodel import *
|
|
3015
|
+
odb.get_participation_factor(mode=1)
|
|
3016
|
+
```
|
|
3017
|
+
Returns: json字符串,包含信息为dict
|
|
2892
3018
|
## 绘制模型结果
|
|
2893
3019
|
### plot_reaction_result
|
|
2894
3020
|
保存结果图片到指定文件甲
|
|
@@ -3012,7 +3138,7 @@ Returns: 无
|
|
|
3012
3138
|
> show_legend: 是否显示图例
|
|
3013
3139
|
> text_rotation_angle: 数值选项卡内文字旋转角度
|
|
3014
3140
|
> digital_count: 小数点位数
|
|
3015
|
-
>
|
|
3141
|
+
> show_exponential: 是否以指数形式显示
|
|
3016
3142
|
> max_min_kind: 最大最小值显示类型
|
|
3017
3143
|
> show_increment: 是否显示增量结果
|
|
3018
3144
|
```Python
|
|
@@ -3155,7 +3281,7 @@ Returns: 无
|
|
|
3155
3281
|
> show_legend: 是否显示图例
|
|
3156
3282
|
> text_rotation_angle: 数值选项卡内文字旋转角度
|
|
3157
3283
|
> digital_count: 小数点位数
|
|
3158
|
-
>
|
|
3284
|
+
> show_exponential: 是否以指数形式显示
|
|
3159
3285
|
> max_min_kind: 最大最小值显示类型
|
|
3160
3286
|
> show_increment: 是否显示增量结果
|
|
3161
3287
|
> position: 位置 0-板顶 1-板底 2-绝对值最大
|
|
@@ -3165,6 +3291,24 @@ from qtmodel import *
|
|
|
3165
3291
|
odb.plot_plate_element_stress(file_path=r"D:\\图片\\板应力.png",component=0,load_case_name="CQ:成桥(合计)",stage_id=-1)
|
|
3166
3292
|
```
|
|
3167
3293
|
Returns: 无
|
|
3294
|
+
### plot_vibration_mode
|
|
3295
|
+
绘制板单元结果图并保存到指定文件
|
|
3296
|
+
> 参数:
|
|
3297
|
+
> file_path: 保存路径名
|
|
3298
|
+
> mode: 模态号
|
|
3299
|
+
> show_number: 是否显示数值
|
|
3300
|
+
> show_pre_deformed: 是否显示未变形形状
|
|
3301
|
+
> show_legend: 是否显示图例
|
|
3302
|
+
> text_rotation_angle: 数值选项卡内文字旋转角度
|
|
3303
|
+
> digital_count: 小数点位数
|
|
3304
|
+
> show_exponential: 是否以指数形式显示
|
|
3305
|
+
> max_min_kind: 最大最小值显示类型
|
|
3306
|
+
```Python
|
|
3307
|
+
# 示例代码
|
|
3308
|
+
from qtmodel import *
|
|
3309
|
+
odb.plot_vibration_mode(file_path=r"D:\\图片\\自振模态.png",mode=1)
|
|
3310
|
+
```
|
|
3311
|
+
Returns: 无
|
|
3168
3312
|
## 获取模型信息
|
|
3169
3313
|
### get_element_by_point
|
|
3170
3314
|
获取某一点指定范围内单元集合,单元中心点为节点平均值
|
|
@@ -3207,7 +3351,7 @@ Returns: json字符串,包含信息为list[list[int]]
|
|
|
3207
3351
|
from qtmodel import *
|
|
3208
3352
|
odb.get_overlap_elements()
|
|
3209
3353
|
```
|
|
3210
|
-
Returns:
|
|
3354
|
+
Returns: json字符串,包含信息为list[list[int]]
|
|
3211
3355
|
### get_structure_group_names
|
|
3212
3356
|
获取结构组名称
|
|
3213
3357
|
> 参数:
|
|
@@ -3225,7 +3369,7 @@ Returns: json字符串,包含信息为list[str]
|
|
|
3225
3369
|
from qtmodel import *
|
|
3226
3370
|
odb.get_thickness_data(1)
|
|
3227
3371
|
```
|
|
3228
|
-
Returns:
|
|
3372
|
+
Returns:
|
|
3229
3373
|
### get_all_thickness_data
|
|
3230
3374
|
获取所有板厚信息
|
|
3231
3375
|
> 参数:
|
|
@@ -3253,7 +3397,7 @@ Returns: json字符串,包含信息为list[dict]
|
|
|
3253
3397
|
from qtmodel import *
|
|
3254
3398
|
odb.get_section_shape(1)
|
|
3255
3399
|
```
|
|
3256
|
-
Returns:
|
|
3400
|
+
Returns:
|
|
3257
3401
|
### get_all_section_data
|
|
3258
3402
|
获取所有截面详细信息,截面特性详见UI自定义特性截面
|
|
3259
3403
|
> 参数:
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
> 最新版本 V0.6.
|
|
1
|
+
> 最新版本 V0.6.5 - 2025-01-23
|
|
2
2
|
> pip install --upgrade qtmodel -i https://pypi.org/simple
|
|
3
|
-
-
|
|
3
|
+
- 新增部分接口
|
|
4
4
|
# 建模操作
|
|
5
5
|
## 项目管理
|
|
6
6
|
### undo_model
|
|
@@ -2111,7 +2111,6 @@ from qtmodel import *
|
|
|
2111
2111
|
mdb.add_custom_temperature(case_name="荷载工况1",element_id=1,orientation=1,temperature_data=[(1,1,20),(1,2,10)])
|
|
2112
2112
|
```
|
|
2113
2113
|
Returns: 无
|
|
2114
|
-
## 静力荷载操作
|
|
2115
2114
|
### remove_custom_temperature
|
|
2116
2115
|
删除梁单元自定义温度
|
|
2117
2116
|
> 参数:
|
|
@@ -2645,6 +2644,58 @@ from qtmodel import *
|
|
|
2645
2644
|
mdb.remove_construction_stage(name="施工阶段1")
|
|
2646
2645
|
```
|
|
2647
2646
|
Returns: 无
|
|
2647
|
+
### add_section_connection_stage
|
|
2648
|
+
添加施工阶段联合截面
|
|
2649
|
+
> 参数:
|
|
2650
|
+
> name:名称
|
|
2651
|
+
> sec_id:截面号
|
|
2652
|
+
> ele_id:单元号,支持整型和整型列表
|
|
2653
|
+
> stage_name:结合阶段名
|
|
2654
|
+
> age:材龄
|
|
2655
|
+
> weight_type:辅材计自重方式 0-由主材承担 1-由整体承担 2-不计辅材自重
|
|
2656
|
+
```Python
|
|
2657
|
+
# 示例代码
|
|
2658
|
+
from qtmodel import *
|
|
2659
|
+
mdb.add_section_connection_stage(name="联合阶段",sec_id=1,ele_id=[2,3,4,5],stage_name="施工阶段1")
|
|
2660
|
+
```
|
|
2661
|
+
Returns:无
|
|
2662
|
+
### update_section_connection_stage
|
|
2663
|
+
更新施工阶段联合截面
|
|
2664
|
+
> 参数:
|
|
2665
|
+
> name:名称
|
|
2666
|
+
> new_name:新名称
|
|
2667
|
+
> sec_id:截面号
|
|
2668
|
+
> ele_id:单元号,支持整型和整型列表
|
|
2669
|
+
> stage_name:结合阶段名
|
|
2670
|
+
> age:材龄
|
|
2671
|
+
> weight_type:辅材计自重方式 0-由主材承担 1-由整体承担 2-不计辅材自重
|
|
2672
|
+
```Python
|
|
2673
|
+
# 示例代码
|
|
2674
|
+
from qtmodel import *
|
|
2675
|
+
mdb.update_section_connection_stage(name="联合阶段",sec_id=1,ele_id=[2,3,4,5],stage_name="施工阶段1")
|
|
2676
|
+
```
|
|
2677
|
+
Returns:无
|
|
2678
|
+
### remove_section_connection_stage
|
|
2679
|
+
删除施工阶段联合截面
|
|
2680
|
+
> 参数:
|
|
2681
|
+
> name:名称
|
|
2682
|
+
```Python
|
|
2683
|
+
# 示例代码
|
|
2684
|
+
from qtmodel import *
|
|
2685
|
+
mdb.remove_section_connection_stage(name="联合阶段")
|
|
2686
|
+
```
|
|
2687
|
+
Returns:无
|
|
2688
|
+
### add_element_to_connection_stage
|
|
2689
|
+
添加单元到施工阶段联合截面
|
|
2690
|
+
> 参数:
|
|
2691
|
+
> ele_id:单元号
|
|
2692
|
+
> name:联合阶段名
|
|
2693
|
+
```Python
|
|
2694
|
+
# 示例代码
|
|
2695
|
+
from qtmodel import *
|
|
2696
|
+
mdb.add_element_to_connection_stage([1,2,3,4],"联合阶段")
|
|
2697
|
+
```
|
|
2698
|
+
Returns:无
|
|
2648
2699
|
## 荷载组合操作
|
|
2649
2700
|
### add_load_combine
|
|
2650
2701
|
添加荷载组合
|
|
@@ -2864,6 +2915,51 @@ odb.get_node_displacement(node_id=[1,2,3],stage_id=1)
|
|
|
2864
2915
|
odb.get_node_displacement(node_id=1,stage_id=-1,case_name="工况名")
|
|
2865
2916
|
```
|
|
2866
2917
|
Returns: json字符串,包含信息为list[dict] or dict
|
|
2918
|
+
### get_self_concurrent_reaction
|
|
2919
|
+
获取自并发反力
|
|
2920
|
+
> 参数:
|
|
2921
|
+
> node_id:节点号
|
|
2922
|
+
> case_name:工况号
|
|
2923
|
+
```Python
|
|
2924
|
+
# 示例代码
|
|
2925
|
+
from qtmodel import *
|
|
2926
|
+
odb.get_self_concurrent_reaction(node_id=1,case_name="工况1_Fx最大")
|
|
2927
|
+
```
|
|
2928
|
+
Returns: json字符串,包含信息为dict
|
|
2929
|
+
### get_all_concurrent_reaction
|
|
2930
|
+
获取完全并发反力
|
|
2931
|
+
> 参数:
|
|
2932
|
+
> node_id:节点号
|
|
2933
|
+
> case_name:工况号
|
|
2934
|
+
```Python
|
|
2935
|
+
# 示例代码
|
|
2936
|
+
from qtmodel import *
|
|
2937
|
+
odb.get_all_concurrent_reaction(node_id=1,case_name="工况1_Fx最大")
|
|
2938
|
+
```
|
|
2939
|
+
Returns: json字符串,包含信息为dict
|
|
2940
|
+
### get_beam_concurrent_force
|
|
2941
|
+
获取梁单元并发内力
|
|
2942
|
+
> 参数:
|
|
2943
|
+
> ele_id:单元号
|
|
2944
|
+
> case_name:工况号
|
|
2945
|
+
```Python
|
|
2946
|
+
# 示例代码
|
|
2947
|
+
from qtmodel import *
|
|
2948
|
+
odb.get_beam_concurrent_force(ele_id=1,case_name="工况1_Fx最大")
|
|
2949
|
+
```
|
|
2950
|
+
Returns: json字符串,包含信息为dict
|
|
2951
|
+
### get_composite_beam_concurrent_force
|
|
2952
|
+
获取组合梁单元并发内力
|
|
2953
|
+
> 参数:
|
|
2954
|
+
> ele_id:单元号
|
|
2955
|
+
> case_name:工况号
|
|
2956
|
+
```Python
|
|
2957
|
+
# 示例代码
|
|
2958
|
+
from qtmodel import *
|
|
2959
|
+
odb.get_composite_beam_concurrent_force(ele_id=1,case_name="工况1_Fx最大")
|
|
2960
|
+
```
|
|
2961
|
+
Returns: json字符串,包含信息为dict
|
|
2962
|
+
## 动力结果查看
|
|
2867
2963
|
### get_vibration_node_displacement
|
|
2868
2964
|
获取指定节点指定模态的振型向量
|
|
2869
2965
|
> 参数:
|
|
@@ -2875,6 +2971,36 @@ from qtmodel import *
|
|
|
2875
2971
|
odb.get_vibration_node_displacement(node_id=1,mode=1)
|
|
2876
2972
|
```
|
|
2877
2973
|
Returns: json字符串,包含信息为list[dict] or dict
|
|
2974
|
+
### get_period_and_frequency
|
|
2975
|
+
获取周期和频率
|
|
2976
|
+
> 参数:
|
|
2977
|
+
> mode:模态号
|
|
2978
|
+
```Python
|
|
2979
|
+
# 示例代码
|
|
2980
|
+
from qtmodel import *
|
|
2981
|
+
odb.get_period_and_frequency(mode=1)
|
|
2982
|
+
```
|
|
2983
|
+
Returns: json字符串,包含信息为dict
|
|
2984
|
+
### get_participation_mass
|
|
2985
|
+
获取振型参与质量百分比
|
|
2986
|
+
> 参数:
|
|
2987
|
+
> mode:模态号
|
|
2988
|
+
```Python
|
|
2989
|
+
# 示例代码
|
|
2990
|
+
from qtmodel import *
|
|
2991
|
+
odb.get_participation_mass(mode=1)
|
|
2992
|
+
```
|
|
2993
|
+
Returns: json字符串,包含信息为dict
|
|
2994
|
+
### get_participation_factor
|
|
2995
|
+
获取振型参与质量系数
|
|
2996
|
+
> 参数:
|
|
2997
|
+
> mode:模态号
|
|
2998
|
+
```Python
|
|
2999
|
+
# 示例代码
|
|
3000
|
+
from qtmodel import *
|
|
3001
|
+
odb.get_participation_factor(mode=1)
|
|
3002
|
+
```
|
|
3003
|
+
Returns: json字符串,包含信息为dict
|
|
2878
3004
|
## 绘制模型结果
|
|
2879
3005
|
### plot_reaction_result
|
|
2880
3006
|
保存结果图片到指定文件甲
|
|
@@ -2998,7 +3124,7 @@ Returns: 无
|
|
|
2998
3124
|
> show_legend: 是否显示图例
|
|
2999
3125
|
> text_rotation_angle: 数值选项卡内文字旋转角度
|
|
3000
3126
|
> digital_count: 小数点位数
|
|
3001
|
-
>
|
|
3127
|
+
> show_exponential: 是否以指数形式显示
|
|
3002
3128
|
> max_min_kind: 最大最小值显示类型
|
|
3003
3129
|
> show_increment: 是否显示增量结果
|
|
3004
3130
|
```Python
|
|
@@ -3141,7 +3267,7 @@ Returns: 无
|
|
|
3141
3267
|
> show_legend: 是否显示图例
|
|
3142
3268
|
> text_rotation_angle: 数值选项卡内文字旋转角度
|
|
3143
3269
|
> digital_count: 小数点位数
|
|
3144
|
-
>
|
|
3270
|
+
> show_exponential: 是否以指数形式显示
|
|
3145
3271
|
> max_min_kind: 最大最小值显示类型
|
|
3146
3272
|
> show_increment: 是否显示增量结果
|
|
3147
3273
|
> position: 位置 0-板顶 1-板底 2-绝对值最大
|
|
@@ -3151,6 +3277,24 @@ from qtmodel import *
|
|
|
3151
3277
|
odb.plot_plate_element_stress(file_path=r"D:\\图片\\板应力.png",component=0,load_case_name="CQ:成桥(合计)",stage_id=-1)
|
|
3152
3278
|
```
|
|
3153
3279
|
Returns: 无
|
|
3280
|
+
### plot_vibration_mode
|
|
3281
|
+
绘制板单元结果图并保存到指定文件
|
|
3282
|
+
> 参数:
|
|
3283
|
+
> file_path: 保存路径名
|
|
3284
|
+
> mode: 模态号
|
|
3285
|
+
> show_number: 是否显示数值
|
|
3286
|
+
> show_pre_deformed: 是否显示未变形形状
|
|
3287
|
+
> show_legend: 是否显示图例
|
|
3288
|
+
> text_rotation_angle: 数值选项卡内文字旋转角度
|
|
3289
|
+
> digital_count: 小数点位数
|
|
3290
|
+
> show_exponential: 是否以指数形式显示
|
|
3291
|
+
> max_min_kind: 最大最小值显示类型
|
|
3292
|
+
```Python
|
|
3293
|
+
# 示例代码
|
|
3294
|
+
from qtmodel import *
|
|
3295
|
+
odb.plot_vibration_mode(file_path=r"D:\\图片\\自振模态.png",mode=1)
|
|
3296
|
+
```
|
|
3297
|
+
Returns: 无
|
|
3154
3298
|
## 获取模型信息
|
|
3155
3299
|
### get_element_by_point
|
|
3156
3300
|
获取某一点指定范围内单元集合,单元中心点为节点平均值
|
|
@@ -3193,7 +3337,7 @@ Returns: json字符串,包含信息为list[list[int]]
|
|
|
3193
3337
|
from qtmodel import *
|
|
3194
3338
|
odb.get_overlap_elements()
|
|
3195
3339
|
```
|
|
3196
|
-
Returns:
|
|
3340
|
+
Returns: json字符串,包含信息为list[list[int]]
|
|
3197
3341
|
### get_structure_group_names
|
|
3198
3342
|
获取结构组名称
|
|
3199
3343
|
> 参数:
|
|
@@ -3211,7 +3355,7 @@ Returns: json字符串,包含信息为list[str]
|
|
|
3211
3355
|
from qtmodel import *
|
|
3212
3356
|
odb.get_thickness_data(1)
|
|
3213
3357
|
```
|
|
3214
|
-
Returns:
|
|
3358
|
+
Returns:
|
|
3215
3359
|
### get_all_thickness_data
|
|
3216
3360
|
获取所有板厚信息
|
|
3217
3361
|
> 参数:
|
|
@@ -3239,7 +3383,7 @@ Returns: json字符串,包含信息为list[dict]
|
|
|
3239
3383
|
from qtmodel import *
|
|
3240
3384
|
odb.get_section_shape(1)
|
|
3241
3385
|
```
|
|
3242
|
-
Returns:
|
|
3386
|
+
Returns:
|
|
3243
3387
|
### get_all_section_data
|
|
3244
3388
|
获取所有截面详细信息,截面特性详见UI自定义特性截面
|
|
3245
3389
|
> 参数:
|
|
@@ -214,7 +214,7 @@ class Mdb:
|
|
|
214
214
|
raise Exception(ex)
|
|
215
215
|
|
|
216
216
|
@staticmethod
|
|
217
|
-
def update_construction_stage_setting(do_analysis: bool, to_end_stage: bool, other_stage_id: int = 1, analysis_type: int = 0,
|
|
217
|
+
def update_construction_stage_setting(do_analysis: bool = True, to_end_stage: bool = True, other_stage_id: int = 1, analysis_type: int = 0,
|
|
218
218
|
do_creep_analysis: bool = True, cable_tension_position: int = 0, consider_completion_stage: bool = True,
|
|
219
219
|
shrink_creep_type: int = 2, creep_load_type: int = 1,
|
|
220
220
|
sub_step_info: tuple[bool, float, float, float, float, float] = None):
|
|
@@ -3390,7 +3390,6 @@ class Mdb:
|
|
|
3390
3390
|
# endregion
|
|
3391
3391
|
|
|
3392
3392
|
# region 静力荷载操作
|
|
3393
|
-
|
|
3394
3393
|
@staticmethod
|
|
3395
3394
|
def add_nodal_force(node_id: (Union[int, List[int]]) = 1, case_name: str = "", load_info: list[float] = None,
|
|
3396
3395
|
group_name: str = "默认荷载组"):
|
|
@@ -4195,6 +4194,81 @@ class Mdb:
|
|
|
4195
4194
|
except Exception as ex:
|
|
4196
4195
|
raise Exception(f"删除施工阶段自重:{name}错误,{ex}")
|
|
4197
4196
|
|
|
4197
|
+
@staticmethod
|
|
4198
|
+
def add_section_connection_stage(name: str, sec_id: int, ele_id: (Union[int, List[int]]) = None, stage_name="", age: float = 0,
|
|
4199
|
+
weight_type: int = 0):
|
|
4200
|
+
"""
|
|
4201
|
+
添加施工阶段联合截面
|
|
4202
|
+
Args:
|
|
4203
|
+
name:名称
|
|
4204
|
+
sec_id:截面号
|
|
4205
|
+
ele_id:单元号,支持整型和整型列表
|
|
4206
|
+
stage_name:结合阶段名
|
|
4207
|
+
age:材龄
|
|
4208
|
+
weight_type:辅材计自重方式 0-由主材承担 1-由整体承担 2-不计辅材自重
|
|
4209
|
+
Example:
|
|
4210
|
+
mdb.add_section_connection_stage(name="联合阶段",sec_id=1,ele_id=[2,3,4,5],stage_name="施工阶段1")
|
|
4211
|
+
Returns:无
|
|
4212
|
+
"""
|
|
4213
|
+
try:
|
|
4214
|
+
qt_model.AddSectionConnectionStage(name=name, secId=sec_id, elementIds=ele_id, stageName=stage_name, age=age, weightType=weight_type)
|
|
4215
|
+
except Exception as ex:
|
|
4216
|
+
raise Exception(f"添加施工阶段联合截面失败:{name}错误,{ex}")
|
|
4217
|
+
|
|
4218
|
+
@staticmethod
|
|
4219
|
+
def update_section_connection_stage(name: str, new_name="", sec_id: int = 1, ele_id: (Union[int, List[int]]) = None,
|
|
4220
|
+
stage_name="", age: float = 0, weight_type: int = 0):
|
|
4221
|
+
"""
|
|
4222
|
+
更新施工阶段联合截面
|
|
4223
|
+
Args:
|
|
4224
|
+
name:名称
|
|
4225
|
+
new_name:新名称
|
|
4226
|
+
sec_id:截面号
|
|
4227
|
+
ele_id:单元号,支持整型和整型列表
|
|
4228
|
+
stage_name:结合阶段名
|
|
4229
|
+
age:材龄
|
|
4230
|
+
weight_type:辅材计自重方式 0-由主材承担 1-由整体承担 2-不计辅材自重
|
|
4231
|
+
Example:
|
|
4232
|
+
mdb.update_section_connection_stage(name="联合阶段",sec_id=1,ele_id=[2,3,4,5],stage_name="施工阶段1")
|
|
4233
|
+
Returns:无
|
|
4234
|
+
"""
|
|
4235
|
+
try:
|
|
4236
|
+
qt_model.UpdateSectionConnectionStage(name=name, newName=new_name, secId=sec_id, elementIds=ele_id,
|
|
4237
|
+
stageName=stage_name, age=age, weightType=weight_type)
|
|
4238
|
+
except Exception as ex:
|
|
4239
|
+
raise Exception(f"更新施工阶段联合截面失败:{name}错误,{ex}")
|
|
4240
|
+
|
|
4241
|
+
@staticmethod
|
|
4242
|
+
def remove_section_connection_stage(name: str):
|
|
4243
|
+
"""
|
|
4244
|
+
删除施工阶段联合截面
|
|
4245
|
+
Args:
|
|
4246
|
+
name:名称
|
|
4247
|
+
Example:
|
|
4248
|
+
mdb.remove_section_connection_stage(name="联合阶段")
|
|
4249
|
+
Returns:无
|
|
4250
|
+
"""
|
|
4251
|
+
try:
|
|
4252
|
+
qt_model.RemoveSectionConnectionStage(name=name)
|
|
4253
|
+
except Exception as ex:
|
|
4254
|
+
raise Exception(f"删除施工阶段联合截面失败:{name}错误,{ex}")
|
|
4255
|
+
|
|
4256
|
+
@staticmethod
|
|
4257
|
+
def add_element_to_connection_stage(ele_id: (Union[int, List[int]]), name: str):
|
|
4258
|
+
"""
|
|
4259
|
+
添加单元到施工阶段联合截面
|
|
4260
|
+
Args:
|
|
4261
|
+
ele_id:单元号
|
|
4262
|
+
name:联合阶段名
|
|
4263
|
+
Example:
|
|
4264
|
+
mdb.add_element_to_connection_stage([1,2,3,4],"联合阶段")
|
|
4265
|
+
Returns:无
|
|
4266
|
+
"""
|
|
4267
|
+
try:
|
|
4268
|
+
qt_model.AddElementToConnectionStage(elementIds=ele_id, name=name)
|
|
4269
|
+
except Exception as ex:
|
|
4270
|
+
raise Exception(f"添加单元到施工阶段联合截面失败:{name}错误,{ex}")
|
|
4271
|
+
|
|
4198
4272
|
# endregion
|
|
4199
4273
|
|
|
4200
4274
|
# region 荷载组合操作
|
|
@@ -343,6 +343,73 @@ class Odb:
|
|
|
343
343
|
except Exception as ex:
|
|
344
344
|
raise Exception(ex)
|
|
345
345
|
|
|
346
|
+
@staticmethod
|
|
347
|
+
def get_self_concurrent_reaction(node_id: int, case_name: str):
|
|
348
|
+
"""
|
|
349
|
+
获取自并发反力
|
|
350
|
+
Args:
|
|
351
|
+
node_id:节点号
|
|
352
|
+
case_name:工况号
|
|
353
|
+
Example:
|
|
354
|
+
odb.get_self_concurrent_reaction(node_id=1,case_name="工况1_Fx最大")
|
|
355
|
+
Returns: json字符串,包含信息为dict
|
|
356
|
+
"""
|
|
357
|
+
try:
|
|
358
|
+
qt_model.GetSelfConcurrentReaction(nodeId=node_id, loadCaseName=case_name)
|
|
359
|
+
except Exception as ex:
|
|
360
|
+
raise Exception(ex)
|
|
361
|
+
|
|
362
|
+
@staticmethod
|
|
363
|
+
def get_all_concurrent_reaction(node_id: int, case_name: str):
|
|
364
|
+
"""
|
|
365
|
+
获取完全并发反力
|
|
366
|
+
Args:
|
|
367
|
+
node_id:节点号
|
|
368
|
+
case_name:工况号
|
|
369
|
+
Example:
|
|
370
|
+
odb.get_all_concurrent_reaction(node_id=1,case_name="工况1_Fx最大")
|
|
371
|
+
Returns: json字符串,包含信息为dict
|
|
372
|
+
"""
|
|
373
|
+
try:
|
|
374
|
+
qt_model.GetAllConcurrentReaction(nodeId=node_id, loadCaseName=case_name)
|
|
375
|
+
except Exception as ex:
|
|
376
|
+
raise Exception(ex)
|
|
377
|
+
|
|
378
|
+
@staticmethod
|
|
379
|
+
def get_beam_concurrent_force(ele_id: (Union[int, List[int]]) = None, case_name: str = ""):
|
|
380
|
+
"""
|
|
381
|
+
获取梁单元并发内力
|
|
382
|
+
Args:
|
|
383
|
+
ele_id:单元号
|
|
384
|
+
case_name:工况号
|
|
385
|
+
Example:
|
|
386
|
+
odb.get_beam_concurrent_force(ele_id=1,case_name="工况1_Fx最大")
|
|
387
|
+
Returns: json字符串,包含信息为dict
|
|
388
|
+
"""
|
|
389
|
+
try:
|
|
390
|
+
qt_model.GetBeamConcurrentForce(eleId=ele_id, loadCaseName=case_name)
|
|
391
|
+
except Exception as ex:
|
|
392
|
+
raise Exception(ex)
|
|
393
|
+
|
|
394
|
+
@staticmethod
|
|
395
|
+
def get_composite_beam_concurrent_force(ele_id: (Union[int, List[int]]) = None, case_name: str = ""):
|
|
396
|
+
"""
|
|
397
|
+
获取组合梁单元并发内力
|
|
398
|
+
Args:
|
|
399
|
+
ele_id:单元号
|
|
400
|
+
case_name:工况号
|
|
401
|
+
Example:
|
|
402
|
+
odb.get_composite_beam_concurrent_force(ele_id=1,case_name="工况1_Fx最大")
|
|
403
|
+
Returns: json字符串,包含信息为dict
|
|
404
|
+
"""
|
|
405
|
+
try:
|
|
406
|
+
qt_model.GetCompositeBeamConcurrentForce(eleId=ele_id, loadCaseName=case_name)
|
|
407
|
+
except Exception as ex:
|
|
408
|
+
raise Exception(ex)
|
|
409
|
+
|
|
410
|
+
# endregion
|
|
411
|
+
|
|
412
|
+
# region 动力结果查看
|
|
346
413
|
@staticmethod
|
|
347
414
|
def get_vibration_node_displacement(node_id: (Union[int, List[int]]) = None, mode: int = 1):
|
|
348
415
|
"""
|
|
@@ -365,6 +432,51 @@ class Odb:
|
|
|
365
432
|
except Exception as ex:
|
|
366
433
|
raise Exception(ex)
|
|
367
434
|
|
|
435
|
+
@staticmethod
|
|
436
|
+
def get_period_and_frequency(mode: int = 1):
|
|
437
|
+
"""
|
|
438
|
+
获取周期和频率
|
|
439
|
+
Args:
|
|
440
|
+
mode:模态号
|
|
441
|
+
Example:
|
|
442
|
+
odb.get_period_and_frequency(mode=1)
|
|
443
|
+
Returns: json字符串,包含信息为dict
|
|
444
|
+
"""
|
|
445
|
+
try:
|
|
446
|
+
qt_model.GetPeriodAndFrequency(mode=mode)
|
|
447
|
+
except Exception as ex:
|
|
448
|
+
raise Exception(ex)
|
|
449
|
+
|
|
450
|
+
@staticmethod
|
|
451
|
+
def get_participation_mass(mode: int = 1):
|
|
452
|
+
"""
|
|
453
|
+
获取振型参与质量百分比
|
|
454
|
+
Args:
|
|
455
|
+
mode:模态号
|
|
456
|
+
Example:
|
|
457
|
+
odb.get_participation_mass(mode=1)
|
|
458
|
+
Returns: json字符串,包含信息为dict
|
|
459
|
+
"""
|
|
460
|
+
try:
|
|
461
|
+
qt_model.GetParticipationMass(mode=mode)
|
|
462
|
+
except Exception as ex:
|
|
463
|
+
raise Exception(ex)
|
|
464
|
+
|
|
465
|
+
@staticmethod
|
|
466
|
+
def get_participation_factor(mode: int = 1):
|
|
467
|
+
"""
|
|
468
|
+
获取振型参与质量系数
|
|
469
|
+
Args:
|
|
470
|
+
mode:模态号
|
|
471
|
+
Example:
|
|
472
|
+
odb.get_participation_factor(mode=1)
|
|
473
|
+
Returns: json字符串,包含信息为dict
|
|
474
|
+
"""
|
|
475
|
+
try:
|
|
476
|
+
qt_model.GetParticipationFactor(mode=mode)
|
|
477
|
+
except Exception as ex:
|
|
478
|
+
raise Exception(ex)
|
|
479
|
+
|
|
368
480
|
# endregion
|
|
369
481
|
|
|
370
482
|
# region 绘制模型结果
|
|
@@ -540,7 +652,7 @@ class Odb:
|
|
|
540
652
|
envelope_type: int = 1, force_kind: int = 0, component: int = 0,
|
|
541
653
|
show_number: bool = False, text_rotation_angle: int = 0, max_min_kind: int = 0,
|
|
542
654
|
show_deformed: bool = True, deformed_scale: float = 1.0, deformed_actual: bool = False,
|
|
543
|
-
show_legend: bool = True, digital_count: int = 3,
|
|
655
|
+
show_legend: bool = True, digital_count: int = 3, show_exponential: bool = True,
|
|
544
656
|
show_pre_deformed: bool = False, ):
|
|
545
657
|
"""
|
|
546
658
|
绘制板单元结果图并保存到指定文件
|
|
@@ -559,7 +671,7 @@ class Odb:
|
|
|
559
671
|
show_legend: 是否显示图例
|
|
560
672
|
text_rotation_angle: 数值选项卡内文字旋转角度
|
|
561
673
|
digital_count: 小数点位数
|
|
562
|
-
|
|
674
|
+
show_exponential: 是否以指数形式显示
|
|
563
675
|
max_min_kind: 最大最小值显示类型
|
|
564
676
|
show_increment: 是否显示增量结果
|
|
565
677
|
Example:
|
|
@@ -572,7 +684,7 @@ class Odb:
|
|
|
572
684
|
envelopeType=envelope_type, forceKind=force_kind, component=component,
|
|
573
685
|
showAsDeformedShape=show_deformed, deformedScale=deformed_scale, deformedActual=deformed_actual,
|
|
574
686
|
showNumber=show_number, textRotationAngle=text_rotation_angle, maxMinValueKind=max_min_kind,
|
|
575
|
-
showLegend=show_legend, digitalCount=digital_count, showAsExponential=
|
|
687
|
+
showLegend=show_legend, digitalCount=digital_count, showAsExponential=show_exponential,
|
|
576
688
|
showUndeformedShape=show_pre_deformed)
|
|
577
689
|
except Exception as ex:
|
|
578
690
|
raise Exception(ex)
|
|
@@ -769,7 +881,7 @@ class Odb:
|
|
|
769
881
|
envelope_type: int = 1, stress_kind: int = 0, component: int = 0,
|
|
770
882
|
show_number: bool = False, text_rotation_angle: int = 0, max_min_kind: int = 0,
|
|
771
883
|
show_deformed: bool = True, deformed_scale: float = 1.0, deformed_actual: bool = False,
|
|
772
|
-
show_legend: bool = True, digital_count: int = 3,
|
|
884
|
+
show_legend: bool = True, digital_count: int = 3, show_exponential: bool = True,
|
|
773
885
|
show_pre_deformed: bool = False, position: int = 0):
|
|
774
886
|
"""
|
|
775
887
|
绘制板单元结果图并保存到指定文件
|
|
@@ -788,7 +900,7 @@ class Odb:
|
|
|
788
900
|
show_legend: 是否显示图例
|
|
789
901
|
text_rotation_angle: 数值选项卡内文字旋转角度
|
|
790
902
|
digital_count: 小数点位数
|
|
791
|
-
|
|
903
|
+
show_exponential: 是否以指数形式显示
|
|
792
904
|
max_min_kind: 最大最小值显示类型
|
|
793
905
|
show_increment: 是否显示增量结果
|
|
794
906
|
position: 位置 0-板顶 1-板底 2-绝对值最大
|
|
@@ -802,11 +914,40 @@ class Odb:
|
|
|
802
914
|
envelopeType=envelope_type, stressKind=stress_kind, component=component,
|
|
803
915
|
showAsDeformedShape=show_deformed, deformedScale=deformed_scale, deformedActual=deformed_actual,
|
|
804
916
|
showNumber=show_number, textRotationAngle=text_rotation_angle, maxMinValueKind=max_min_kind,
|
|
805
|
-
showLegend=show_legend, digitalCount=digital_count, showAsExponential=
|
|
917
|
+
showLegend=show_legend, digitalCount=digital_count, showAsExponential=show_exponential,
|
|
806
918
|
showUndeformedShape=show_pre_deformed, position=position)
|
|
807
919
|
except Exception as ex:
|
|
808
920
|
raise Exception(ex)
|
|
809
921
|
|
|
922
|
+
@staticmethod
|
|
923
|
+
def plot_vibration_mode(file_path: str = "", mode: int = 1, show_number: bool = True, text_rotation_angle: float = 0, max_min_kind: int = 0,
|
|
924
|
+
show_legend: bool = True, digital_count: int = 3, show_exponential: bool = True,
|
|
925
|
+
show_pre_deformed: bool = False):
|
|
926
|
+
"""
|
|
927
|
+
绘制板单元结果图并保存到指定文件
|
|
928
|
+
Args:
|
|
929
|
+
file_path: 保存路径名
|
|
930
|
+
mode: 模态号
|
|
931
|
+
show_number: 是否显示数值
|
|
932
|
+
show_pre_deformed: 是否显示未变形形状
|
|
933
|
+
show_legend: 是否显示图例
|
|
934
|
+
text_rotation_angle: 数值选项卡内文字旋转角度
|
|
935
|
+
digital_count: 小数点位数
|
|
936
|
+
show_exponential: 是否以指数形式显示
|
|
937
|
+
max_min_kind: 最大最小值显示类型
|
|
938
|
+
Example:
|
|
939
|
+
odb.plot_vibration_mode(file_path=r"D:\\图片\\自振模态.png",mode=1)
|
|
940
|
+
Returns: 无
|
|
941
|
+
"""
|
|
942
|
+
try:
|
|
943
|
+
qt_model.PlotVibrationMode(
|
|
944
|
+
filePath=file_path, mode=mode,
|
|
945
|
+
showNumber=show_number, textRotationAngle=text_rotation_angle, maxMinValueKind=max_min_kind,
|
|
946
|
+
showLegend=show_legend, digitalCount=digital_count, showAsExponential=show_exponential,
|
|
947
|
+
showUndeformedShape=show_pre_deformed)
|
|
948
|
+
except Exception as ex:
|
|
949
|
+
raise Exception(ex)
|
|
950
|
+
|
|
810
951
|
# endregion
|
|
811
952
|
|
|
812
953
|
# region 获取模型信息
|
|
@@ -873,7 +1014,7 @@ class Odb:
|
|
|
873
1014
|
Args:无
|
|
874
1015
|
Example:
|
|
875
1016
|
odb.get_overlap_elements()
|
|
876
|
-
Returns:
|
|
1017
|
+
Returns: json字符串,包含信息为list[list[int]]
|
|
877
1018
|
"""
|
|
878
1019
|
try:
|
|
879
1020
|
result = []
|
|
@@ -906,7 +1047,8 @@ class Odb:
|
|
|
906
1047
|
Args:
|
|
907
1048
|
Example:
|
|
908
1049
|
odb.get_thickness_data(1)
|
|
909
|
-
Returns:
|
|
1050
|
+
Returns:
|
|
1051
|
+
json字符串,包含信息为dict
|
|
910
1052
|
"""
|
|
911
1053
|
try:
|
|
912
1054
|
return qt_model.GetThicknessData(thick_id)
|
|
@@ -957,7 +1099,8 @@ class Odb:
|
|
|
957
1099
|
sec_id: 目标截面编号
|
|
958
1100
|
Example:
|
|
959
1101
|
odb.get_section_shape(1)
|
|
960
|
-
Returns:
|
|
1102
|
+
Returns:
|
|
1103
|
+
json字符串,包含信息为dict
|
|
961
1104
|
"""
|
|
962
1105
|
try:
|
|
963
1106
|
return qt_model.GetSectionShape(sec_id)
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: qtmodel
|
|
3
|
-
Version: 0.6.
|
|
4
|
-
Summary: python modeling for qt 2025-01-
|
|
3
|
+
Version: 0.6.5
|
|
4
|
+
Summary: python modeling for qt 2025-01-23
|
|
5
5
|
Home-page: https://github.com/Inface0443/pyqt
|
|
6
6
|
Author: dqy-zhj
|
|
7
7
|
Author-email: 1105417715@qq.com
|
|
@@ -12,9 +12,9 @@ Classifier: Programming Language :: Python :: 3
|
|
|
12
12
|
Classifier: Operating System :: OS Independent
|
|
13
13
|
Description-Content-Type: text/markdown
|
|
14
14
|
|
|
15
|
-
> 最新版本 V0.6.
|
|
15
|
+
> 最新版本 V0.6.5 - 2025-01-23
|
|
16
16
|
> pip install --upgrade qtmodel -i https://pypi.org/simple
|
|
17
|
-
-
|
|
17
|
+
- 新增部分接口
|
|
18
18
|
# 建模操作
|
|
19
19
|
## 项目管理
|
|
20
20
|
### undo_model
|
|
@@ -2125,7 +2125,6 @@ from qtmodel import *
|
|
|
2125
2125
|
mdb.add_custom_temperature(case_name="荷载工况1",element_id=1,orientation=1,temperature_data=[(1,1,20),(1,2,10)])
|
|
2126
2126
|
```
|
|
2127
2127
|
Returns: 无
|
|
2128
|
-
## 静力荷载操作
|
|
2129
2128
|
### remove_custom_temperature
|
|
2130
2129
|
删除梁单元自定义温度
|
|
2131
2130
|
> 参数:
|
|
@@ -2659,6 +2658,58 @@ from qtmodel import *
|
|
|
2659
2658
|
mdb.remove_construction_stage(name="施工阶段1")
|
|
2660
2659
|
```
|
|
2661
2660
|
Returns: 无
|
|
2661
|
+
### add_section_connection_stage
|
|
2662
|
+
添加施工阶段联合截面
|
|
2663
|
+
> 参数:
|
|
2664
|
+
> name:名称
|
|
2665
|
+
> sec_id:截面号
|
|
2666
|
+
> ele_id:单元号,支持整型和整型列表
|
|
2667
|
+
> stage_name:结合阶段名
|
|
2668
|
+
> age:材龄
|
|
2669
|
+
> weight_type:辅材计自重方式 0-由主材承担 1-由整体承担 2-不计辅材自重
|
|
2670
|
+
```Python
|
|
2671
|
+
# 示例代码
|
|
2672
|
+
from qtmodel import *
|
|
2673
|
+
mdb.add_section_connection_stage(name="联合阶段",sec_id=1,ele_id=[2,3,4,5],stage_name="施工阶段1")
|
|
2674
|
+
```
|
|
2675
|
+
Returns:无
|
|
2676
|
+
### update_section_connection_stage
|
|
2677
|
+
更新施工阶段联合截面
|
|
2678
|
+
> 参数:
|
|
2679
|
+
> name:名称
|
|
2680
|
+
> new_name:新名称
|
|
2681
|
+
> sec_id:截面号
|
|
2682
|
+
> ele_id:单元号,支持整型和整型列表
|
|
2683
|
+
> stage_name:结合阶段名
|
|
2684
|
+
> age:材龄
|
|
2685
|
+
> weight_type:辅材计自重方式 0-由主材承担 1-由整体承担 2-不计辅材自重
|
|
2686
|
+
```Python
|
|
2687
|
+
# 示例代码
|
|
2688
|
+
from qtmodel import *
|
|
2689
|
+
mdb.update_section_connection_stage(name="联合阶段",sec_id=1,ele_id=[2,3,4,5],stage_name="施工阶段1")
|
|
2690
|
+
```
|
|
2691
|
+
Returns:无
|
|
2692
|
+
### remove_section_connection_stage
|
|
2693
|
+
删除施工阶段联合截面
|
|
2694
|
+
> 参数:
|
|
2695
|
+
> name:名称
|
|
2696
|
+
```Python
|
|
2697
|
+
# 示例代码
|
|
2698
|
+
from qtmodel import *
|
|
2699
|
+
mdb.remove_section_connection_stage(name="联合阶段")
|
|
2700
|
+
```
|
|
2701
|
+
Returns:无
|
|
2702
|
+
### add_element_to_connection_stage
|
|
2703
|
+
添加单元到施工阶段联合截面
|
|
2704
|
+
> 参数:
|
|
2705
|
+
> ele_id:单元号
|
|
2706
|
+
> name:联合阶段名
|
|
2707
|
+
```Python
|
|
2708
|
+
# 示例代码
|
|
2709
|
+
from qtmodel import *
|
|
2710
|
+
mdb.add_element_to_connection_stage([1,2,3,4],"联合阶段")
|
|
2711
|
+
```
|
|
2712
|
+
Returns:无
|
|
2662
2713
|
## 荷载组合操作
|
|
2663
2714
|
### add_load_combine
|
|
2664
2715
|
添加荷载组合
|
|
@@ -2878,6 +2929,51 @@ odb.get_node_displacement(node_id=[1,2,3],stage_id=1)
|
|
|
2878
2929
|
odb.get_node_displacement(node_id=1,stage_id=-1,case_name="工况名")
|
|
2879
2930
|
```
|
|
2880
2931
|
Returns: json字符串,包含信息为list[dict] or dict
|
|
2932
|
+
### get_self_concurrent_reaction
|
|
2933
|
+
获取自并发反力
|
|
2934
|
+
> 参数:
|
|
2935
|
+
> node_id:节点号
|
|
2936
|
+
> case_name:工况号
|
|
2937
|
+
```Python
|
|
2938
|
+
# 示例代码
|
|
2939
|
+
from qtmodel import *
|
|
2940
|
+
odb.get_self_concurrent_reaction(node_id=1,case_name="工况1_Fx最大")
|
|
2941
|
+
```
|
|
2942
|
+
Returns: json字符串,包含信息为dict
|
|
2943
|
+
### get_all_concurrent_reaction
|
|
2944
|
+
获取完全并发反力
|
|
2945
|
+
> 参数:
|
|
2946
|
+
> node_id:节点号
|
|
2947
|
+
> case_name:工况号
|
|
2948
|
+
```Python
|
|
2949
|
+
# 示例代码
|
|
2950
|
+
from qtmodel import *
|
|
2951
|
+
odb.get_all_concurrent_reaction(node_id=1,case_name="工况1_Fx最大")
|
|
2952
|
+
```
|
|
2953
|
+
Returns: json字符串,包含信息为dict
|
|
2954
|
+
### get_beam_concurrent_force
|
|
2955
|
+
获取梁单元并发内力
|
|
2956
|
+
> 参数:
|
|
2957
|
+
> ele_id:单元号
|
|
2958
|
+
> case_name:工况号
|
|
2959
|
+
```Python
|
|
2960
|
+
# 示例代码
|
|
2961
|
+
from qtmodel import *
|
|
2962
|
+
odb.get_beam_concurrent_force(ele_id=1,case_name="工况1_Fx最大")
|
|
2963
|
+
```
|
|
2964
|
+
Returns: json字符串,包含信息为dict
|
|
2965
|
+
### get_composite_beam_concurrent_force
|
|
2966
|
+
获取组合梁单元并发内力
|
|
2967
|
+
> 参数:
|
|
2968
|
+
> ele_id:单元号
|
|
2969
|
+
> case_name:工况号
|
|
2970
|
+
```Python
|
|
2971
|
+
# 示例代码
|
|
2972
|
+
from qtmodel import *
|
|
2973
|
+
odb.get_composite_beam_concurrent_force(ele_id=1,case_name="工况1_Fx最大")
|
|
2974
|
+
```
|
|
2975
|
+
Returns: json字符串,包含信息为dict
|
|
2976
|
+
## 动力结果查看
|
|
2881
2977
|
### get_vibration_node_displacement
|
|
2882
2978
|
获取指定节点指定模态的振型向量
|
|
2883
2979
|
> 参数:
|
|
@@ -2889,6 +2985,36 @@ from qtmodel import *
|
|
|
2889
2985
|
odb.get_vibration_node_displacement(node_id=1,mode=1)
|
|
2890
2986
|
```
|
|
2891
2987
|
Returns: json字符串,包含信息为list[dict] or dict
|
|
2988
|
+
### get_period_and_frequency
|
|
2989
|
+
获取周期和频率
|
|
2990
|
+
> 参数:
|
|
2991
|
+
> mode:模态号
|
|
2992
|
+
```Python
|
|
2993
|
+
# 示例代码
|
|
2994
|
+
from qtmodel import *
|
|
2995
|
+
odb.get_period_and_frequency(mode=1)
|
|
2996
|
+
```
|
|
2997
|
+
Returns: json字符串,包含信息为dict
|
|
2998
|
+
### get_participation_mass
|
|
2999
|
+
获取振型参与质量百分比
|
|
3000
|
+
> 参数:
|
|
3001
|
+
> mode:模态号
|
|
3002
|
+
```Python
|
|
3003
|
+
# 示例代码
|
|
3004
|
+
from qtmodel import *
|
|
3005
|
+
odb.get_participation_mass(mode=1)
|
|
3006
|
+
```
|
|
3007
|
+
Returns: json字符串,包含信息为dict
|
|
3008
|
+
### get_participation_factor
|
|
3009
|
+
获取振型参与质量系数
|
|
3010
|
+
> 参数:
|
|
3011
|
+
> mode:模态号
|
|
3012
|
+
```Python
|
|
3013
|
+
# 示例代码
|
|
3014
|
+
from qtmodel import *
|
|
3015
|
+
odb.get_participation_factor(mode=1)
|
|
3016
|
+
```
|
|
3017
|
+
Returns: json字符串,包含信息为dict
|
|
2892
3018
|
## 绘制模型结果
|
|
2893
3019
|
### plot_reaction_result
|
|
2894
3020
|
保存结果图片到指定文件甲
|
|
@@ -3012,7 +3138,7 @@ Returns: 无
|
|
|
3012
3138
|
> show_legend: 是否显示图例
|
|
3013
3139
|
> text_rotation_angle: 数值选项卡内文字旋转角度
|
|
3014
3140
|
> digital_count: 小数点位数
|
|
3015
|
-
>
|
|
3141
|
+
> show_exponential: 是否以指数形式显示
|
|
3016
3142
|
> max_min_kind: 最大最小值显示类型
|
|
3017
3143
|
> show_increment: 是否显示增量结果
|
|
3018
3144
|
```Python
|
|
@@ -3155,7 +3281,7 @@ Returns: 无
|
|
|
3155
3281
|
> show_legend: 是否显示图例
|
|
3156
3282
|
> text_rotation_angle: 数值选项卡内文字旋转角度
|
|
3157
3283
|
> digital_count: 小数点位数
|
|
3158
|
-
>
|
|
3284
|
+
> show_exponential: 是否以指数形式显示
|
|
3159
3285
|
> max_min_kind: 最大最小值显示类型
|
|
3160
3286
|
> show_increment: 是否显示增量结果
|
|
3161
3287
|
> position: 位置 0-板顶 1-板底 2-绝对值最大
|
|
@@ -3165,6 +3291,24 @@ from qtmodel import *
|
|
|
3165
3291
|
odb.plot_plate_element_stress(file_path=r"D:\\图片\\板应力.png",component=0,load_case_name="CQ:成桥(合计)",stage_id=-1)
|
|
3166
3292
|
```
|
|
3167
3293
|
Returns: 无
|
|
3294
|
+
### plot_vibration_mode
|
|
3295
|
+
绘制板单元结果图并保存到指定文件
|
|
3296
|
+
> 参数:
|
|
3297
|
+
> file_path: 保存路径名
|
|
3298
|
+
> mode: 模态号
|
|
3299
|
+
> show_number: 是否显示数值
|
|
3300
|
+
> show_pre_deformed: 是否显示未变形形状
|
|
3301
|
+
> show_legend: 是否显示图例
|
|
3302
|
+
> text_rotation_angle: 数值选项卡内文字旋转角度
|
|
3303
|
+
> digital_count: 小数点位数
|
|
3304
|
+
> show_exponential: 是否以指数形式显示
|
|
3305
|
+
> max_min_kind: 最大最小值显示类型
|
|
3306
|
+
```Python
|
|
3307
|
+
# 示例代码
|
|
3308
|
+
from qtmodel import *
|
|
3309
|
+
odb.plot_vibration_mode(file_path=r"D:\\图片\\自振模态.png",mode=1)
|
|
3310
|
+
```
|
|
3311
|
+
Returns: 无
|
|
3168
3312
|
## 获取模型信息
|
|
3169
3313
|
### get_element_by_point
|
|
3170
3314
|
获取某一点指定范围内单元集合,单元中心点为节点平均值
|
|
@@ -3207,7 +3351,7 @@ Returns: json字符串,包含信息为list[list[int]]
|
|
|
3207
3351
|
from qtmodel import *
|
|
3208
3352
|
odb.get_overlap_elements()
|
|
3209
3353
|
```
|
|
3210
|
-
Returns:
|
|
3354
|
+
Returns: json字符串,包含信息为list[list[int]]
|
|
3211
3355
|
### get_structure_group_names
|
|
3212
3356
|
获取结构组名称
|
|
3213
3357
|
> 参数:
|
|
@@ -3225,7 +3369,7 @@ Returns: json字符串,包含信息为list[str]
|
|
|
3225
3369
|
from qtmodel import *
|
|
3226
3370
|
odb.get_thickness_data(1)
|
|
3227
3371
|
```
|
|
3228
|
-
Returns:
|
|
3372
|
+
Returns:
|
|
3229
3373
|
### get_all_thickness_data
|
|
3230
3374
|
获取所有板厚信息
|
|
3231
3375
|
> 参数:
|
|
@@ -3253,7 +3397,7 @@ Returns: json字符串,包含信息为list[dict]
|
|
|
3253
3397
|
from qtmodel import *
|
|
3254
3398
|
odb.get_section_shape(1)
|
|
3255
3399
|
```
|
|
3256
|
-
Returns:
|
|
3400
|
+
Returns:
|
|
3257
3401
|
### get_all_section_data
|
|
3258
3402
|
获取所有截面详细信息,截面特性详见UI自定义特性截面
|
|
3259
3403
|
> 参数:
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|