机械设计上机设计实验报告
- 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
- 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
- 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。
机械设计上机设计
班级:
姓名:
学号:
目录
1.数表和线图的程序化处理 (1)
1.1数表的程序化 (1)
1.1.1查表检索法 (1)
1.1.2数表解析法 (12)
1.2线图的程序化 (15)
1.3有关数据处理 (16)
2.典型零部件的程序设计 (18)
2.1 V带传动的程序设计 (18)
2.2 齿轮传动的程序设计 (19)
2.3 滚动轴承的程序设计 (21)
3.课后习题计算 (22)
一、表和线图的程序化处理
1.1数表程序化
数表程序化有两种方法:一是查表检索法;二是数表解析法1.1.1 查表检索法
1)一元数表的存取
表1-1 普通V带型号及有关参数
运行界面:
程序代码:
Private Sub Command1_Click()
Dim s As Integer
Dim q1 As Single, dm As Single, kb As Single
s = Val(Txt_s.Text)
Select Case s
Case 0
q1 = 0.02: dm = 20: kb = 0.00006
Case 1
q1 = 0.06: dm = 50: kb = 0.00039
Case 2
q1 = 0.1: dm = 75: kb = 0.00103
Case 4
q1 = 0.17: dm = 125: kb = 0.00265
Case 5
q1 = 0.3: dm = 200: kb = 0.0075
Case 6
q1 = 0.62: dm = 355: kb = 0.0266
Case 7
q1 = 0.9: dm = 500: kb = 0.0498
End Select
Txt_q1.Text = Str(q1)
Txt_dmin.Text = Str(dm)
Txt_kb.Text = Str(kb)
End Sub
Private Sub Command2_Click()
End
End Sub
2)二元数表的存取
表1-2齿轮传动工作状况系数K
运行界面:
程序代码:
Option Explicit
Dim ii As Integer
Dim jj As Integer
Public appdir As String Private Sub Check1_Click() If Check1.Value = 1 Then Check2.Value = 0
Check3.Value = 0
ii = 0
End If
End Sub
Private Sub Check2_Click() If Check2.Value = 1 Then Check1.Value = 0
Check3.Value = 0
ii = 1
End If
End Sub
Private Sub Check3_Click() If Check3.Value = 1 Then Check1.Value = 0
Check2.Value = 0
ii = 2
End If
End Sub
Private Sub Check4_Click()
If Check4.Value = 1 Then
Check5.Value = 0
Check6.Value = 0
jj = 0
End If
End Sub
Private Sub Check5_Click()
If Check5.Value = 1 Then
Check4.Value = 0
Check6.Value = 0
jj = 1
End If
End Sub
Private Sub Check6_Click()
If Check6.Value = 1 Then
Check4.Value = 0
Check5.Value = 0
jj = 2
End If
End Sub
Private Sub Command1_Click()
Dim i As Integer, j As Integer
Dim ka(0 To 2, 0 To 2) As Single
ka(0, 0) = 1
ka(0, 1) = 1.25
ka(0, 2) = 1.75
ka(1, 0) = 1.25
ka(1, 1) = 1.5
ka(1, 2) = 2
ka(2, 0) = 1.5
ka(2, 1) = 1.75
ka(2, 2) = 2.25
txt_ka.Text = Str(ka(ii, jj))
End Sub
Private Sub Command1_Click()
End
End Sub
表1-3V工作状况系数K
运行界面:
程序代码:
Private Sub Command1_Click()
If (Combo1.Text = Combo1.List(0) And Option1.Value) Then Text_ka.Text = 1 If (Combo1.Text = Combo1.List(0) And Option2.Value) Then Text_ka.Text = 1.1 If (Combo1.Text = Combo1.List(0) And Option3.Value) Then Text_ka.Text = 1.2 If (Combo1.Text = Combo1.List(1) And Option1.Value) Then Text_ka.Text = 1.1 If (Combo1.Text = Combo1.List(1) And Option2.Value) Then Text_ka.Text = 1.2 If (Combo1.Text = Combo1.List(1) And Option3.Value) Then Text_ka.Text = 1.3 If (Combo1.Text = Combo1.List(2) And Option1.Value) Then Text_ka.Text = 1.2 If (Combo1.Text = Combo1.List(2) And Option2.Value) Then Text_ka.Text = 1.3 If (Combo1.Text = Combo1.List(2) And Option3.Value) Then Text_ka.Text = 1.4 If (Combo1.Text = Combo1.List(3) And Option1.Value) Then Text_ka.Text = 1.3 If (Combo1.Text = Combo1.List(3) And Option2.Value) Then Text_ka.Text = 1.4 If (Combo1.Text = Combo1.List(3) And Option3.Value) Then Text_ka.Text = 1.5 Text_pc.Text = Str(Text_ka) * Str(Text_p)
End Sub
Private Sub Command2_Click()
End
End Sub