基于VB编写的电力电缆载流量计算

众所周知,电力电缆的载流量计算是一个复杂且耗时的工程,以前纯靠手工计算,现在随着计算机以及编程的发展,计算速度也越来越快,界面也越来越美观。本文是基于VB编写的电力电缆载流量计算,是我十年前的作品,界面清晰简单,输入方便,直观高效的展示计算结果。

程序已经被封装为exe文件,并且已经被应用在行业中,拿来即用,效果杠杠的。

 VB是面向用户的程序,虽然界面设计简单,但对于初学者而言是一个很好的工具,尤其对于从事非IT的科研、技术及研发人员,可以用它来实现很多相对简单的计算。

由于篇幅有限,我把一部分代码分享给大家。

Function MyRound(number As Currency, count As Integer) '四舍五入函数
If Right(CStr(number * 10 ^ (count + 1)), 1) = 5 Then
  number = number + 1 / 10 ^ (count + 1)
End If
MyRound = Round(number, count)
End Function

Private Sub Combo2_Click()
If Combo1.Text = "YJLW02" Or Combo1.Text = "YJLW03" Then
If Combo2.Text = "25mm2" Then
Text24.Text = 0.727
ElseIf Combo2.Text = "35mm2" Then
Text24.Text = 0.524
ElseIf Combo2.Text = "50mm2" Then
Text24.Text = 0.387
ElseIf Combo2.Text = "70mm2" Then
Text24.Text = 0.268
ElseIf Combo2.Text = "95mm2" Then
Text24.Text = 0.193
ElseIf Combo2.Text = "120mm2" Then
Text24.Text = 0.153
ElseIf Combo2.Text = "150mm2" Then
Text24.Text = 0.124
ElseIf Combo2.Text = "185mm2" Then
Text24.Text = 0.0991
ElseIf Combo2.Text = "240mm2" Then
Text24.Text = 0.0754
ElseIf Combo2.Text = "300mm2" Then
Text24.Text = 0.0601
ElseIf Combo2.Text = "400mm2" Then
Text24.Text = 0.047
ElseIf Combo2.Text = "500mm2" Then
Text24.Text = 0.0366
ElseIf Combo2.Text = "630mm2" Then
Text24.Text = 0.0283
ElseIf Combo2.Text = "800mm2" Then
Text24.Text = 0.0221
ElseIf Combo2.Text = "1000mm2" Then
Text24.Text = 0.0176
ElseIf Combo2.Text = "1200mm2" Then
Text24.Text = 0.0129
ElseIf Combo2.Text = "1400mm2" Then
Text24.Text = 0.0221
ElseIf Combo2.Text = "1600mm2" Then
Text24.Text = 0.0113
ElseIf Combo2.Text = "1800mm2" Then
Text24.Text = 0.0101
ElseIf Combo2.Text = "2000mm2" Then
Text24.Text = 0.009
ElseIf Combo2.Text = "2500mm2" Then
Text24.Text = 0.0072
End If
ElseIf Combo1.Text = "YJLLW02" Or Combo1.Text = "YJLLW03" Then
If Combo2.Text = "25mm2" Then
Text24.Text = 1.2
ElseIf Combo2.Text = "35mm2" Then
Text24.Text = 0.868
ElseIf Combo2.Text = "50mm2" Then
Text24.Text = 0.641
ElseIf Combo2.Text = "70mm2" Then
Text24.Text = 0.443
ElseIf Combo2.Text = "95mm2" Then
Text24.Text = 0.32
ElseIf Combo2.Text = "120mm2" Then
Text24.Text = 0.253
ElseIf Combo2.Text = "150mm2" Then
Text24.Text = 0.206
ElseIf Combo2.Text = "185mm2" Then
Text24.Text = 0.164
ElseIf Combo2.Text = "240mm2" Then
Text24.Text = 0.125
ElseIf Combo2.Text = "300mm2" Then
Text24.Text = 0.1
ElseIf Combo2.Text = "400mm2" Then
Text24.Text = 0.0778
ElseIf Combo2.Text = "500mm2" Then
Text24.Text = 0.0605
ElseIf Combo2.Text = "630mm2" Then
Text24.Text = 0.0469
ElseIf Combo2.Text = "800mm2" Then
Text24.Text = 0.0367
ElseIf Combo2.Text = "1000mm2" Then
Text24.Text = 0.0291
ElseIf Combo2.Text = "1200mm2" Then
Text24.Text = 0.0247
ElseIf Combo2.Text = "1400mm2" Then
Text24.Text = 0.0212
ElseIf Combo2.Text = "1600mm2" Then
Text24.Text = 0.0186
ElseIf Combo2.Text = "1800mm2" Then
Text24.Text = 0.0165
ElseIf Combo2.Text = "2000mm2" Then
Text24.Text = 0.0149
ElseIf Combo2.Text = "2500mm2" Then
Text24.Text = 0.0127
End If
End If
Text24.Text = Format(Text24.Text, "0.0000")
End Sub


Private Sub Command1_Click()
Dim a1 As Single
Dim a2 As Single
Dim a3 As Single
Dim a4 As Single
Dim a5 As Single
Dim a6 As Single
Dim a7 As Single
Dim a8 As Single
Dim a9 As Single
Dim a10 As Single
Dim a11 As Single
Dim a12 As Single
Dim a13 As Single
Dim a14 As Single


Dim b1 As Single
Dim b2 As Single
Dim b3 As Single
Dim b4 As Single


a1 = Val(Text1.Text) '工作相电压
a2 = Val(Text2.Text) '线芯外径
a3 = Val(Text3.Text) '内屏蔽厚度
a4 = Val(Text4.Text) '绝缘厚度
a5 = Val(Text5.Text) '外屏蔽厚度
a6 = Val(Text6.Text) '金属套波谷
a7 = Val(Text7.Text) '金属套波峰
a8 = Val(Text8.Text) '金属套厚度
a9 = Val(Text9.Text) '外护套厚度
a10 = Val(Text10.Text) '电缆外径
a11 = Val(Text11.Text) '线芯温度

a12 = Val(Text12.Text) '环境温度
a13 = Val(Text13.Text) '埋地深度

a14 = Val(Text24.Text) '导体的直流电阻


b1 = Val(Combo1.Text) '电缆型号
b2 = Val(Combo2.Text) '电缆截面
b3 = Val(Combo3.Text) '高强度半导电带层数
b4 = Val(Combo4.Text) '半导电阻水带层数
b5 = Val(Combo5.Text) '排列方式


Dim d1 As Single '轴心距
If Combo5.Text = "平面不接触排列" Then
d1 = 2 * a10
ElseIf Combo5.Text = "三角形排列" Then
d1 = a10
End If

Dim d2 As Single '集肤效应因数
If Len(Combo2.Text) <= 6 Then
d2 = 1
Else
d2 = 0.45
End If
Dim d3 As Single '邻近效应因数
If Len(Combo2.Text) <= 6 Then
d3 = 1
Else
d3 = 0.37
End If

Dim d4 As Single '电阻的温度系数
d4 = Val(Combo6.Text)

Dim d5 As Single 'ε
d5 = 2.5
Dim d6 As Single 'tanδ
d6 = 0.001
Dim d7 As Single 'ω
d7 = 2 * 3.1416 * 50


Rem 计算载流量用到的所有参数
Rem 计算交流电阻
Dim h1 As Single '20摄氏度导体的直流电阻
h1 = a14 * (1 + d4 * (a11 - 20))
Dim h2 As Single 'Xs2
h2 = (8 * 3.1416 * 50 * d2 * 0.0000001) / (h1 * 0.001)
Dim h3 As Single 'Ys
h3 = h2 ^ 2 / (192 + 0.8 * h2 ^ 2)
Dim h4 As Single 'Xp2
h4 = (8 * 3.1416 * 50 * d3 * 0.0000001) / (h1 * 0.001)
Dim h5 As Single
h5 = h4 ^ 2 / (192 + 0.8 * h4 ^ 2)
Dim h6 As Single
h6 = h5 * (a2 / d1) ^ 2 * (0.312 * (a2 / d1) ^ 2 + 1.18 / (h5 + 0.27)) 'Yp
Dim h7 As Single '最高工作温度下的交流电阻
h7 = h1 * (1 + h3 + h6)

Rem 计算绝缘损耗
Dim i1 As Single 'c
Dim i2 As Single 'Wd
Dim i3 As Single '导体直径(包括屏蔽层)
Dim i4 As Single '绝缘直径(屏蔽层除外)
If b3 = 1 Then
i3 = a2 + 0.6 + 2 * a3
ElseIf b3 = 2 Then
i3 = a2 + 1.2 + 2 * a3
ElseIf b3 = 0 Then
i3 = a2 + 2 * a3
End If
i4 = i3 + 2 * a4
i1 = (d5 * 0.000000001) / (18 * Log(i4 / i3))
i2 = d7 * i1 * (a1 * 1000) ^ 2 * d6


Rem 金属屏蔽损耗 两端互联
 Rem 金属套的电阻
Dim j1 As Single '金属屏蔽的截面积
Dim j2 As Single '金属屏蔽的电阻
j1 = 3.14 * ((a6 + a7) / 2) * a8
j2 = 0.028264 * (1 + 0.00403 * (a11 * 0.8 - 20)) / j1
Dim j3 As Single '金属屏蔽的电抗 X
j3 = 2 * d7 * 0.0000001 * Log(2 * d1 / ((a6 + a7) / 2))

 Rem 三角形排列 金属屏蔽两端互连
If Combo5.Text = "三角形排列" And Option3.Value = True Then
Dim j4 As Single '环流损耗因数
j4 = (j2 * 1000 / h7) * (1 / (1 + (j2 / j3) ^ 2))
End If

Rem 平面排列不换位 两端互连
Dim j5 As Single 'Xm
j5 = 2 * d7 * 0.0000001 * Log(2)
Dim j6 As Single 'P
Dim j7 As Single 'Q
j6 = j3 + j5
j7 = j3 - j5 / 3
Dim j8 As Single
Dim j9 As Single
Dim j10 As Single
If Option3.Value = True And Combo5.Text = "平面不接触排列" Then
  Rem 金属屏蔽两端互连时最大损耗的那根电缆的损耗因数λ11'
j8 = (j2 * 1000 / h7) * (0.75 * j6 ^ 2 / (j2 ^ 2 + j6 ^ 2) + 0.25 * j7 ^ 2 / (j2 ^ 2 + j7 ^ 2) + 2 * j2 * j6 * j7 * j5 / (3 ^ 0.5 * (j2 ^ 2 + j6 ^ 2) * (j2 ^ 2 + j7 ^ 2)))
  Rem 另一外侧电缆的损耗因数λ12'
j9 = (j2 * 1000 / h7) * (0.75 * j6 ^ 2 / (j2 ^ 2 + j6 ^ 2) + 0.25 * j7 ^ 2 / (j2 ^ 2 + j7 ^ 2) - 2 * j2 * j6 * j7 * j5 / (3 ^ 0.5 * (j2 ^ 2 + j6 ^ 2) * (j2 ^ 2 + j7 ^ 2)))
  Rem 中间一根电缆的损耗因数λ1m'
j10 = (j2 * 1000 / h7) * (j7 ^ 2 / (j2 ^ 2 + j7 ^ 2))
End If


Rem 金属屏蔽单端互连
Dim j11 As Single
Dim j12 As Single
Dim j13 As Single
Dim j14 As Single
Dim j15 As Single
Dim j16 As Single

j11 = (4 * 3.14 * d7 / (10 * 0.028264)) ^ (1 / 2) 'β
j12 = 1 + (a8 / (0.5 * (a6 + a7) + a8)) ^ (1.74) * (j11 * (0.5 * (a6 + a7) + a8) * 0.001 - 1.6) 'gs
j13 = (j11 * a8 * 0.001) ^ 4 / 12
j14 = (d7 * 0.0000001 / j2)      'm
j15 = j14 ^ 2 / (1 + j14 ^ 2) 'm^2/(1+m^2)
j16 = (0.5 * (a6 + a7)) / (2 * d1) 'd/2s

If Combo5.Text = "三角形排列" And Option2.Value = True Then
Dim j17 As Single
Dim j18 As Single
Dim j19 As Single
Dim j20 As Single
Dim j21 As Single
Dim j22 As Single
Dim j23 As Single

j17 = 3 * j15 * (j16 ^ 2)      'λ0
j18 = 1.14 * (j14 ^ 2.45) + 0.33
j19 = 0.92 * j14 + 1.66
j20 = j18 * (j16 ^ j19)      'Δ1
j21 = 0                         'Δ2
j22 = j12 * j17 * (1 + j20 + j21) + j13
j23 = (j2 * 1000 / h7) * j22 '涡流损耗因数
End If
If Combo5.Text = "平面不接触排列" And Option2.Value = True Then
Dim j24 As Single
Dim j25 As Single
Dim j26 As Single
Dim j27 As Single
Dim j28 As Single
Dim j29 As Single
Dim j30 As Single
Dim j31 As Single
Dim j32 As Single
Dim j33 As Single
Dim j34 As Single
Dim j35 As Single

Rem 三根单芯电缆平面排列 中间电缆的涡流损耗因数
j24 = 6 * j15 * (j16 ^ 2) 'λ0
j25 = 0.86 * (j14 ^ 3.08) * j16 ^ (1.4 * j14 + 0.7) 'Δ1
j26 = 0 'Δ2
j27 = (j2 * 1000 / h7) * (j12 * j24 * (1 + j25 + j26) + j13) '因数
Rem  越前相的外侧电缆涡流损耗因数
j28 = 1.5 * j15 * (j16 ^ 2) 'λ0
j29 = 4.7 * j14 ^ 0.7 * j16 * (0.16 * j14 + 0.7) 'Δ1
j30 = 21 * j14 ^ 3.3 * j16 ^ (1.47 * j14 + 5.06) 'Δ2
j31 = (j2 * 1000 / h7) * (j12 * j28 * (1 + j29 + j30) + j13) '因数
Rem  滞后相的外侧电缆涡流损耗因数
j32 = 1.5 * j15 * (j16 ^ 2) 'λ0
j33 = ((0.74 * (j14 + 2) * j14 ^ 0.5) / (2 + (j14 - 0.3) ^ 2)) * j16 ^ (j14 + 1) 'Δ1
j34 = 0.92 * j14 ^ 3.7 * j16 ^ (j14 + 2) 'Δ2
j35 = (j2 * 1000 / h7) * (j12 * j32 * (1 + j33 + j34) + j13) '因数
End If

Rem 大截面分割导体不能忽略的涡流损耗
Dim k1 As Single
Dim k2 As Single
Dim k3 As Single
Dim k4 As Single
Dim k5 As Single
Dim k6 As Single
Dim k7 As Single
Dim k8 As Single
Dim k9 As Single
Dim k10 As Single
Dim k11 As Single
Dim k12 As Single
Dim k13 As Single
Dim k14 As Single
Dim k15 As Single
Dim k16 As Single
Dim k17 As Single
Dim k18 As Single
Dim k19 As Single
Rem 三角形排列不能忽略的涡流损耗因数
k1 = 3 * j15 * (j16 ^ 2)      'λ0
k2 = 1.14 * (j14 ^ 2.45) + 0.33
k3 = 0.92 * j14 + 1.66
k4 = k2 * (j16 ^ k3)      'Δ1
k5 = 0                         'Δ2
k6 = j12 * k1 * (1 + k4 + k5) + j13
k7 = (j2 * 1000 / h7) * k6 '涡流损耗因数

Rem 平面排列不能忽略的涡流损耗因数
Rem 三根单芯电缆平面排列 中间电缆的涡流损耗因数
k8 = 6 * j15 * (j16 ^ 2) 'λ0
k9 = 0.86 * (j14 ^ 3.08) * j16 ^ (1.4 * j14 + 0.7) 'Δ1
k10 = 0 'Δ2
k11 = (j2 * 1000 / h7) * (j12 * k8 * (1 + k9 + k10) + j13) '因数
Rem  越前相的外侧电缆涡流损耗因数
k12 = 1.5 * j15 * (j16 ^ 2) 'λ0
k13 = 4.7 * j14 ^ 0.7 * j16 * (0.16 * j14 + 0.7) 'Δ1
k14 = 21 * j14 ^ 3.3 * j16 ^ (1.47 * j14 + 5.06) 'Δ2
k15 = (j2 * 1000 / h7) * (j12 * k12 * (1 + k13 + k14) + j13) '因数
Rem  滞后相的外侧电缆涡流损耗因数
k16 = 1.5 * j15 * (j16 ^ 2) 'λ0
k17 = ((0.74 * (j14 + 2) * j14 ^ 0.5) / (2 + (j14 - 0.3) ^ 2)) * j16 ^ (j14 + 1) 'Δ1
k18 = 0.92 * j14 ^ 3.7 * j16 ^ (j14 + 2) 'Δ2
k19 = (j2 * 1000 / h7) * (j12 * k16 * (1 + k17 + k18) + j13) '因数

Rem 涡流损耗因数需乘以因数
Dim l1 As Single 'M
Dim l2 As Single 'N
If Combo5.Text = "三角形排列" Then
l1 = j2 / j3
l2 = j2 / j3
ElseIf Combo5.Text = "平面不接触排列" Then
l1 = j2 / (j3 + j5)
l2 = j2 / (j3 - j5 / 3)
End If
Dim l3 As Single
Dim l4 As Single
Dim l5 As Single 'F
l3 = 4 * l1 ^ 2 * l2 ^ 2 + (l1 + l2) ^ 2
l4 = 4 * (l1 ^ 2 + 1) * (l2 ^ 2 + 1)
l5 = l3 / l4

Rem 电缆的热阻计算
Rem 电缆绝缘热阻
Dim m1 As Single
Dim m2 As Single
m1 = 3.5 '交联聚乙烯的热阻系数
m2 = (m1 / (2 * 3.14)) * Log(((a6 + a7) / 2 - a8) / a2) '绝缘热阻

Rem 金属屏蔽和铠装之间的热阻
Dim n1 As Single '内衬层热阻
n1 = 0
Rem 外护层热阻
Dim o1 As Single '外护层的热阻系数
Dim o2 As Single
If Combo1.Text = "YJLW02" Or Combo1.Text = "YJLLW02" Then
o1 = 6
ElseIf Combo1.Text = "YJLW03" Or Combo1.Text = "YJLLW03" Then
o1 = 3.5
End If
Dim o3 As Single
Dim o4 As Single
o3 = a7 + 2 * a9
o4 = (a6 + a7) / 2 + a8
o2 = (o1 / (2 * 3.14)) * Log(o3 / o4)


Rem 空气中电缆外部热阻T4
Rem 不受日光直接照射的电缆
Dim p1 As Single '散热系数h
If Combo5.Text = "平面不接触排列" Then
p1 = 1.31 / (a10 * 0.001) ^ 0.2 + 2
ElseIf Combo5.Text = "三角形排列" Then
p1 = 0.96 / (a10 * 0.001) ^ 0.2 + 1.25
End If

Dim p2 As Single '金属套损耗因数
If Len(Combo2.Text) <= 6 Then
If Combo5.Text = "三角形排列" And Option3.Value = True Then
p2 = j4
ElseIf Combo5.Text = "三角形排列" And Option2.Value = True Then
p2 = j23
ElseIf Combo5.Text = "平面不接触排列" And Option3.Value = True Then
p2 = j8
ElseIf Combo5.Text = "平面不接触排列" And Option2.Value = True Then
p2 = j27
End If
Else
If Combo5.Text = "三角形排列" And Option3.Value = True Then
p2 = j4 + k7 * l5
ElseIf Combo5.Text = "三角形排列" And Option2.Value = True Then
p2 = j23
ElseIf Combo5.Text = "平面不接触排列" And Option3.Value = True Then
p2 = j8 + k11 * l5
ElseIf Combo5.Text = "平面不接触排列" And Option2.Value = True Then
p2 = j27
End If
End If

Dim p3 As Single '铠装损耗因数
p3 = 0

Rem 空气中
If Option4.Value = True Then
Rem 计算(Δθs)^(1/4)
Dim p6 As Single
Dim p7 As Single
Dim p8 As Single
Dim p9 As Single
Dim p10 As Single
Dim p11 As Single
Dim p12 As Single
Dim p13 As Single
Dim p14 As Single
Dim p15 As Single

p6 = 3.14 * a10 * 0.001 * p1 / (1 + p2 + p3)
p7 = 1 'n
p8 = 2 '(Δθs)^(1/4)
p9 = m2 / p7 + n1 * (1 + p2) + o2 * (1 + p2 + p3)
p10 = p6 * p9 'KA
p11 = i2 * ((1 / (1 + p2 + p3) - 0.5) * m2 - (p7 * p3 * n1) / (1 + p2 + p3))
p12 = 1 + p10 * p8
p13 = ((a11 - a12 + p11) / p12) ^ (1 / 4) '(Δθs)n+1^(1/4)
p14 = p13 - p8

If p14 < 0 Then
p14 = -p14
End If
While p14 > 0.001
p9 = m2 / p7 + n1 * (1 + p2) + o2 * (1 + p2 + p3)
p10 = p6 * p9 'KA
p11 = i2 * ((1 / (1 + p2 + p3) - 0.5) * m2 - (p7 * p3 * n1) / (1 + p2 + p3))
p12 = 1 + p10 * p8
p13 = ((a11 - a12 + p11) / p12) ^ (1 / 4) '(Δθs)n+1^(1/4)
p7 = p7 + 1
p14 = p13 - p8
If p14 < 0 Then
   p14 = -p14
End If
    p8 = p13
Wend
Rem 空气中热阻

p15 = 1 / (3.14 * a10 * 0.001 * p1 * p8)
End If


Rem 埋地电缆的外部热阻T4
Dim q1 As Single '土壤中热阻系数
q1 = 1
Dim q2 As Single 'u
q2 = 2 * a13 / a10
Rem 埋地电缆群(相互不接触) 等间距平面排列金属套损耗大致相等的三根电缆
If Option5.Value = True And Combo5.Text = "平面不接触排列" Then
Dim q3 As Single
q3 = Log(q2 + (q2 ^ 2 - 1) ^ (1 / 2))
Dim q4 As Single
q4 = Log(1 + (2 * a13 / d1) ^ 2)
Dim q5 As Single '热阻
q5 = (q1 / (2 * 3.14)) * (q3 + q4)
End If

Rem 等负荷埋地电缆群(相互接触)
Dim q6 As Single
If Option5.Value = True And Combo5.Text = "三角形排列" Then
q6 = (1.5 * q1 / 3.14) * (Log(2 * q2) - 0.63)
End If

Rem 埋于土壤中的水泥管道
Rem 管道和电缆之间的热阻T4'
Dim r1 As Single 'θm
Dim r2 As Single 'T4'
r2 = 5.2 / (1 + 0.1 * (1.1 + 0.011 * r1) * a10)
Rem 管道本身热阻T4''
Dim r3 As Single '管道内径
r3 = 1.5 * a10
Dim r4 As Single '管道外径
r4 = 1.68 * a10
Dim r5 As Single 'T4 ''
r5 = (1 / (2 * 3.1416)) * 1 * Log(r3 / r4)
Rem 管道外部热阻T4'''
Dim r6 As Single '土壤中热阻系数
r6 = 1
Dim r7 As Single 'u
r7 = 2 * a13 / r4
Rem 埋地电缆群(相互不接触) 等间距平面排列金属套损耗大致相等的三根电缆
If Option6.Value = True And Combo5.Text = "平面不接触排列" Then
Dim r8 As Single
r8 = Log(r7 + (r7 ^ 2 - 1) ^ (1 / 2))
Dim r9 As Single
r9 = Log(1 + (2 * a13 / 2 * r4) ^ 2)
Dim r10 As Single '热阻
r10 = (r6 / (2 * 3.14)) * (r8 + r9)
End If
Rem 等负荷埋地电缆群(相互接触)
Dim r11 As Single
If Option6.Value = True And Combo5.Text = "三角形排列" Then
r11 = (1.5 * r6 / 3.14) * (Log(2 * r7) - 0.63)
End If

Dim r12 As Single '管道热阻T4
If Option6.Value = True And Combo5.Text = "平面不接触排列" Then
r12 = r2 + r5 + r10
ElseIf Option6.Value = True And Combo5.Text = "三角形排列" Then
r12 = r2 + r5 + r11
End If

Rem 计算载流量
Text14.Text = Round(h7, 4) '交流电阻
Text14.Text = Format(Text14.Text, "0.0000")
Text15.Text = Round(i2, 4) '绝缘损耗
Text15.Text = Format(Text15.Text, "0.0000")
Text16.Text = Round(p2, 4) '金属套的损耗
Text16.Text = Format(Text16.Text, "0.0000")
Text17.Text = p3 '铠装损耗
Text18.Text = Round(m2, 4) '绝缘热阻T1
Text18.Text = Format(Text18.Text, "0.0000")
Text19.Text = n1 '内衬层热阻T2

If Option4.Value = True Then
Text20.Text = Round(o2, 4) '外护层热阻T3
Text20.Text = Format(Text20.Text, "0.0000")
Text21.Text = Round(p15, 4) '外部热阻T4
Text21.Text = Format(Text21.Text, "0.0000")
ElseIf Option5.Value = True And Combo5.Text = "平面不接触排列" Then
Text20.Text = Round(o2, 4) '外护层热阻T3
Text20.Text = Format(Text20.Text, "0.0000")
Text21.Text = Round(q5, 4) '外部热阻T4
Text21.Text = Format(Text21.Text, "0.0000")
ElseIf Option5.Value = True And Combo5.Text = "三角形排列" Then
Text20.Text = Round(o2 * 1.6, 4) '外护层热阻T3
Text20.Text = Format(Text20.Text, "0.0000")
Text21.Text = Round(q6, 4) '外部热阻T4
Text21.Text = Format(Text21.Text, "0.0000")
ElseIf Option6.Value = True And Combo5.Text = "平面不接触排列" Then
Text20.Text = Round(o2, 4) '外护层热阻T3
Text20.Text = Format(Text20.Text, "0.0000")
Text21.Text = Round(r12, 4) '外部热阻T4
Text21.Text = Format(Text21.Text, "0.0000")
ElseIf Option6.Value = True And Combo5.Text = "三角形排列" Then
Text20.Text = Round(o2 * 1.6, 4) '外护层热阻T3
Text20.Text = Format(Text20.Text, "0.0000")
Text21.Text = Round(r12, 4) '外部热阻T4
Text21.Text = Format(Text21.Text, "0.0000")
End If


Dim z1 As Single
Dim z2 As Single
Dim z3 As Single
Dim z4 As Single
Dim z5 As Single
Dim z6 As Single
Dim z7 As Single
Dim z8 As Single
Dim z9 As Single
Dim z10 As Single
Dim z11 As Single

z1 = Val(Text14.Text)
z2 = Val(Text15.Text)
z3 = Val(Text16.Text)
z4 = Val(Text17.Text)
z5 = Val(Text18.Text)
z6 = Val(Text19.Text)
z7 = Val(Text20.Text)
z8 = Val(Text21.Text)
z9 = a11 - a12 - z2 * (0.5 * z5 + z6 + z7 + z8)
z10 = z1 * z5 + z1 * (1 + z3) * z6 + z1 * (1 + z3 + z4) * (z7 + z8)
z11 = (z9 * 1000 / z10) ^ (1 / 2)
Text22.Text = Round(z11, 1) '载流量
End Sub



Private Sub Command2_Click()
Form1.Show
Unload Form2
End Sub

Private Sub Command3_Click()
End
End Sub

Private Sub Form_Load()
Combo1.AddItem "YJLW02"
Combo1.AddItem "YJLW03"
Combo1.AddItem "YJLLW02"
Combo1.AddItem "YJLLW03"

Combo2.AddItem "240mm2"
Combo2.AddItem "300mm2"
Combo2.AddItem "400mm2"
Combo2.AddItem "500mm2"
Combo2.AddItem "630mm2"
Combo2.AddItem "800mm2"
Combo2.AddItem "1000mm2"
Combo2.AddItem "1200mm2"
Combo2.AddItem "1400mm2"
Combo2.AddItem "1600mm2"
Combo2.AddItem "1800mm2"
Combo2.AddItem "2000mm2"
Combo2.AddItem "2500mm2"


Combo3.AddItem "0"
Combo3.AddItem "1"
Combo3.AddItem "2"

Combo5.AddItem "平面不接触排列"
Combo5.AddItem "三角形排列"

Combo6.AddItem "0.00393"
Combo6.AddItem "0.00403"

End Sub
Private Sub Option4_Click()
If Option4.Value = True Then
Text12.Text = 40
End If
End Sub

Private Sub Option5_Click()
If Option5.Value = True Then
Text12.Text = 25
End If
End Sub

Private Sub Option6_Click()
If Option6.Value = True Then
Text12.Text = 25
End If
End Sub


 最后,如果各位需要软件,可以私信给我。

猜你喜欢

转载自blog.csdn.net/Crazydoubao/article/details/121553759