哈工大材料力学上机实验题 序号7应力状态分析.docx
- 文档编号:23720133
- 上传时间:2023-05-20
- 格式:DOCX
- 页数:30
- 大小:54.47KB
哈工大材料力学上机实验题 序号7应力状态分析.docx
《哈工大材料力学上机实验题 序号7应力状态分析.docx》由会员分享,可在线阅读,更多相关《哈工大材料力学上机实验题 序号7应力状态分析.docx(30页珍藏版)》请在冰豆网上搜索。
哈工大材料力学上机实验题序号7应力状态分析
材料力学上机实验题
序号7应力状态分析
1.源代码
VERSION5.00
BeginVB.FormForm1
Caption="应力状态分析"
ClientHeight=9675
ClientLeft=480
ClientTop=630
ClientWidth=16140
LinkTopic="Form1"
ScaleHeight=9675
ScaleWidth=16140
BeginVB.FrameFrame4
Caption="输出结果"
Height=5295
Left=7560
TabIndex=41
Top=3960
Width=8175
BeginVB.CommandButtonCommand3
Caption="计算"
Height=495
Left=2640
TabIndex=48
Top=4440
Width=1215
End
BeginVB.CommandButtonCommand4
Caption="清除"
Height=495
Left=4440
TabIndex=47
Top=4440
Width=1215
End
BeginVB.PictureBoxPicture2
Height=2655
Left=960
ScaleHeight=2595
ScaleWidth=6435
TabIndex=46
Top=1560
Width=6495
End
BeginVB.TextBoxText19
Height=495
Left=2640
TabIndex=45
Top=600
Width=1215
End
BeginVB.TextBoxText20
Height=495
Left=4440
TabIndex=44
Top=600
Width=1215
End
BeginVB.TextBoxText21
Height=495
Left=6240
TabIndex=43
Top=600
Width=1215
End
BeginVB.TextBoxText22
Height=495
Left=960
TabIndex=42
Top=600
Width=1215
End
BeginVB.LabelLabel21
Caption="τmax"
Height=375
Left=6600
TabIndex=55
Top=360
Width=615
End
BeginVB.LabelLabel20
Caption="δ3"
Height=375
Left=4920
TabIndex=54
Top=360
Width=495
End
BeginVB.LabelLabel19
Caption="δ2"
Height=375
Left=3120
TabIndex=53
Top=360
Width=495
End
BeginVB.LabelLabel18
Caption="δ1"
Height=255
Left=1440
TabIndex=52
Top=360
Width=615
End
End
BeginVB.FrameFrame3
Caption="空间应力状态分析"
Height=2295
Left=7560
TabIndex=28
Top=1440
Width=8175
BeginVB.TextBoxText13
Height=495
Left=1440
TabIndex=34
Top=600
Width=1215
End
BeginVB.TextBoxText14
Height=495
Left=3960
TabIndex=33
Top=600
Width=1215
End
BeginVB.TextBoxText15
Height=495
Left=6480
TabIndex=32
Top=600
Width=1215
End
BeginVB.TextBoxText16
Height=495
Left=1440
TabIndex=31
Top=1320
Width=1215
End
BeginVB.TextBoxText17
Height=495
Left=3960
TabIndex=30
Top=1320
Width=1215
End
BeginVB.TextBoxText18
Height=495
Left=6480
TabIndex=29
Top=1320
Width=1215
End
BeginVB.LabelLabel14
Caption="请输入τzx"
Height=495
Left=5400
TabIndex=40
Top=1440
Width=1215
End
BeginVB.LabelLabel13
Caption="请输入τyz"
Height=495
Left=2880
TabIndex=39
Top=1440
Width=1215
End
BeginVB.LabelLabel12
Caption="请输入τxy"
Height=495
Left=360
TabIndex=38
Top=1440
Width=1215
End
BeginVB.LabelLabel11
Caption="请输入δz"
Height=495
Left=5400
TabIndex=37
Top=720
Width=1215
End
BeginVB.LabelLabel10
Caption="请输入δy"
Height=495
Left=2880
TabIndex=36
Top=720
Width=1215
End
BeginVB.LabelLabel9
Caption="请输入δx"
Height=495
Left=360
TabIndex=35
Top=720
Width=1215
End
End
BeginVB.CommandButtonCommand2
Caption="清除"
Height=495
Left=3960
TabIndex=17
Top=8400
Width=1215
End
BeginVB.PictureBoxPicture1
Height=2655
Left=2160
ScaleHeight=2595
ScaleWidth=3915
TabIndex=16
Top=5520
Width=3975
End
BeginVB.CommandButtonCommand1
Caption="计算"
Height=495
Left=2160
TabIndex=15
Top=8400
Width=1335
End
BeginVB.TextBoxText11
Height=495
Left=840
TabIndex=14
Top=7680
Width=1215
End
BeginVB.TextBoxText10
Height=495
Left=840
TabIndex=13
Top=6840
Width=1215
End
BeginVB.TextBoxText9
Height=495
Left=840
TabIndex=12
Top=5880
Width=1215
End
BeginVB.TextBoxText8
Height=495
Left=4920
TabIndex=11
Top=4560
Width=1215
End
BeginVB.TextBoxText7
Height=495
Left=3600
TabIndex=10
Top=4560
Width=1215
End
BeginVB.TextBoxText6
Height=495
Left=2160
TabIndex=9
Top=4560
Width=1215
End
BeginVB.TextBoxText5
Height=495
Left=840
TabIndex=8
Top=4560
Width=1215
End
BeginVB.TextBoxText4
Height=495
Left=5040
TabIndex=7
Top=2760
Width=1215
End
BeginVB.TextBoxText3
Height=495
Left=2160
TabIndex=6
Top=2760
Width=1215
End
BeginVB.TextBoxText2
Height=495
Left=5040
TabIndex=5
Top=2040
Width=1215
End
BeginVB.TextBoxText1
Height=495
Left=2160
TabIndex=4
Top=2040
Width=1215
End
BeginVB.CommandButtonCommand6
Caption="退出"
Height=855
Left=14160
TabIndex=3
Top=360
Width=1575
End
BeginVB.CommandButtonCommand8
Caption="空间应力状态分析"
Height=855
Left=7560
TabIndex=2
Top=360
Width=3255
End
BeginVB.CommandButtonCommand7
Caption="平面应力状态分析"
Height=855
Left=360
TabIndex=1
Top=360
Width=3255
End
BeginVB.CommandButtonCommand5
Caption="帮助"
Height=855
Left=12480
TabIndex=0
Top=360
Width=1575
End
BeginVB.FrameFrame1
Caption="平面应力状态分析"
Height=2295
Left=360
TabIndex=18
Top=1440
Width=6375
BeginVB.LabelLabel4
Caption="请输入а(rad)"
Height=495
Left=3360
TabIndex=22
Top=1440
Width=1215
End
BeginVB.LabelLabel3
Caption="请输入τxy"
Height=495
Left=480
TabIndex=21
Top=1440
Width=1215
End
BeginVB.LabelLabel2
Caption="请输入δy"
Height=495
Left=3360
TabIndex=20
Top=720
Width=1215
End
BeginVB.LabelLabel1
Caption="请输入δx"
Height=495
Left=480
TabIndex=19
Top=720
Width=1215
End
End
BeginVB.FrameFrame2
Caption="输出结果"
Height=5295
Left=360
TabIndex=23
Top=3960
Width=6375
BeginVB.LabelLabel17
Caption="τmax"
Height=255
Left=4920
TabIndex=51
Top=360
Width=495
End
BeginVB.LabelLabel15
Caption="δ3"
Height=375
Left=3720
TabIndex=50
Top=360
Width=375
End
BeginVB.LabelLabel16
Caption="δ2"
Height=255
Left=2280
TabIndex=49
Top=360
Width=495
End
BeginVB.LabelLabel8
Caption="аδ"
Height=255
Left=840
TabIndex=27
Top=3480
Width=495
End
BeginVB.LabelLabel7
Caption="τа"
Height=255
Left=840
TabIndex=26
Top=2520
Width=495
End
BeginVB.LabelLabel6
Caption="δа"
Height=375
Left=840
TabIndex=25
Top=1680
Width=495
End
BeginVB.LabelLabel5
Caption="δ1"
Height=255
Left=840
TabIndex=24
Top=360
Width=375
End
End
End
AttributeVB_Name="Form1"
AttributeVB_GlobalNameSpace=False
AttributeVB_Creatable=False
AttributeVB_PredeclaredId=True
AttributeVB_Exposed=False
PrivateSubCommand5_Click()
'开始运行程序,选择"平面"还是"空间"
MsgBox"а按弧度制输入,单位是rad;应力单位均是Mpa.若为平面应力状态请按“平面应力状态分析”,否则,按“空间应力状态分析”Designby潘万竞o(∩_∩)o",vbOKOnly,"温馨提示"
Command7.Enabled=True
Command8.Enabled=True
EndSub
'若选择"平面"
PrivateSubCommand7_Click()
Command1.Enabled=True
Command2.Enabled=True
Text1.SetFocus
EndSub
PrivateSubCommand1_Click()
DimδxAsDouble,δyAsDouble,τxyAsDouble,аAsDouble,XAsDouble,YAsDouble,zAsDouble
'输入数据(δx,δy,τxy);某截面方位角а"
δx=Val(Text1.Text)
δy=Val(Text2.Text)
τxy=Val(Text3.Text)
а=Val(Text4.Text)
'计算主应力
X=0
Y=(δx+δy)/2+((δx-δy)^2/4+τxy^2)^0.5
z=(δx+δy)/2-((δx-δy)^2/4+τxy^2)^0.5
'比较大小,输出主应力(δ1,δ2,δ3)和最大剪应力τmax=τ13=(δ1-δ3)/2
IfX>=YAndX>=zThen
Text5.Text=Str(X)
Text6.Text=Str(Y)
Text7.Text=Str(z)
Text8.Text=Str((X-z)/2)
Else
IfX<=YAndX<=zThen
Text5.Text=Str(Y)
Text6.Text=Str(z)
Text7.Text=Str(X)
Text8.Text=Str((Y-X)/2)
Else
Text5.Text=Str(Y)
Text6.Text=Str(X)
Text7.Text=Str(z)
Text8.Text=Str((Y-z)/2)
EndIf
EndIf
'计算并输出δа,τа,аδ
Text9.Text=Str((δx+δy)/2+(δx-δy)/2*Cos(2*а)+τxy*Sin(2*а))
Text10.Text=Str(-(δx-δy)/2*Sin(2*а)+τxy*Cos(2*а))
Ifδx=δyThen
Text11.Text=Str(45)
Else
Text11.Text=Str(Atn(τxy^2/(δx-δy))/2)
EndIf
'输出应力圆
If((δx-δy)^2/4+τxy^2)^0.5<=50And((δx-δy)^2/4+τxy^2)^0.5>=20Then
'半径在20-50间的输出
Picture1.ScaleMode=3
Picture1.Scale(0,0)-(200,80)
Picture1.Scale(-100,40)-(100,-40)
Picture1.Line(-100,0)-(100,0)
Picture1.Line(0,-40)-(0,40)
Picture1.Circle((δx+δy)/2,0),((δx-δy)^2/4+τxy^2)^0.5,QBColor(12)
Else
If((δx-δy)^2/4+τxy^2)^0.5<20And((δx-δy)^2/4+τxy^2)^0.5>0Then
'半径在0-20间的输出
Picture1.ScaleMode=3
Picture1.Scale(0,0)-(80,40)
Picture1.Scale(-40,20)-(40,-20)
Picture1.Line(-40,0)-(40,0)
Picture1.Line(0,-20)-(0,20)
Picture1.Circle((δx+δy)/2,0),((δx-δy)^2/4+τxy^2)^0.5,QBColor(12)
Else
'半径在大于50间的输出
Picture1.ScaleMode=3
Picture1.Scale(0,0)-(400,200)
Picture1.Scale(-200,100)-(200,-100)
Picture1.Line(-200,0)-(200,0)
Picture1.Line(0,-100)-(0,100)
Picture1.Circle((δx+δy)/2,0),((δx-δy)^2/4+τxy^2)^0.5,QBColor(12)
EndIf
EndIf
EndSub
PrivateSubCommand2_Click()
'清空文本框
Text1.Text=""
Text2.Text=""
Text3.Text=""
Text4.Text=""
Text5.Text=""
Text6.Text=""
Text7.Text=""
Text8.Text=""
Text9.Text=""
Text10.Text=""
Text11.Text=""
'清除图片框
Picture1.Cls
'返回光标
Text1.SetFocus
EndSub
'若选择"空间"
PrivateSubCommand8_Click()
Command3.Enabled=True
Command4.Enabled=True
Text13.SetFocus
EndSub
PrivateSubCommand3_Click()
DimδxAsDouble,δyAsDouble,δzAsDouble,τxyAsDouble,τyzAsDouble,τzxAsDoubl
- 配套讲稿:
如PPT文件的首页显示word图标,表示该PPT已包含配套word讲稿。双击word图标可打开word文档。
- 特殊限制:
部分文档作品中含有的国旗、国徽等图片,仅作为作品整体效果示例展示,禁止商用。设计者仅对作品中独创性部分享有著作权。
- 关 键 词:
- 哈工大材料力学上机实验题 序号7应力状态分析 哈工大 材料力学 上机 实验 序号 应力 状态 分析
![提示](https://static.bdocx.com/images/bang_tan.gif)