-
Notifications
You must be signed in to change notification settings - Fork 0
/
bloco_b.py
36 lines (31 loc) · 1.17 KB
/
bloco_b.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
"""
BLOCO_B
INPUTS:
diameterCm --> um (01) perfil : Item access --> type: float
dois ou n perfis : List access --> type: float
thicknessCm --> um (01) perfil : Item access --> type: float
dois ou n perfis : List access --> type: float
materialResistance --> Item access --> type: float
OUTPUTS:
out --> informações visuais (resistência(s) máxima(s))
maximumResistance --> lista de resistência(s) máxima(s)
"""
listDiameter = (diameterCm)
listThickness = (thicknessCm)
num = (len(listThickness))
cont = 0
maximumResistance = []
while cont < num:
diameter = listDiameter[cont] * 10
thickness = listThickness[cont] * 10
profileArea = (((3.14159 * diameter ** 2)/4)
- ((3.14159 * (diameter-(thickness*2)) **2 )/4))
maxRes = profileArea * materialResistance
maximumResistance.append(maxRes)
cont += 1
size_maximumResistance = len(maximumResistance)
cont_2 = 0
for i in range(size_maximumResistance):
valor = maximumResistance[cont_2]
print("Res. Máxima perfil %s = %.2f KN." %(i, valor))
cont_2 += 1