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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
|
{
"cells": [
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# Chapter 19: Drawing of Rods, Wires and Tubes"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"### Example 19.1, Analysis of Wiredrawing, Page No. 640"
]
},
{
"cell_type": "code",
"execution_count": 1,
"metadata": {
"collapsed": false
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"\n",
"Drawing Stress = 240.422 MPa\n",
"Drawing Force = 12.0849 kN\n",
"Power = 36.2548 kW\n",
"Horsepower = 48.599 hp\n"
]
}
],
"source": [
"from math import pi\n",
"from math import radians\n",
"from math import tan\n",
"from math import log\n",
"\n",
"#variable declaration\n",
"def cot(x):\n",
" return 1/tan(x);\n",
"Ab=10;\n",
"r=0.2;\n",
"alpha=12;\n",
"mu=0.09;\n",
"n=0.3;\n",
"K=1300;\n",
"v=3;\n",
"\n",
"#calculation\n",
"alpha=radians(alpha);\n",
"B=mu*cot(alpha/2);\n",
"e1=log(1/(1-r));\n",
"sigma=K*e1**0.3/(n+1);\n",
"Aa=Ab*(1-r);\n",
"sigma_xa=sigma*((1+B)/B)*(1-(Aa/Ab)**B);\n",
"Aa=pi*Aa**2/4;\n",
"Pd=sigma_xa*Aa;\n",
"Pd=Pd/1000; #conversion to kilo units\n",
"P=Pd*v;\n",
"H=P/0.746;\n",
"\n",
"#result\n",
"print('\\nDrawing Stress = %g MPa\\nDrawing Force = %g kN\\nPower = %g kW\\nHorsepower = %g hp')%(sigma_xa,Pd,P,H);"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"### Example 19.2, Analysis of Wiredrawing, Page No. 645"
]
},
{
"cell_type": "code",
"execution_count": 2,
"metadata": {
"collapsed": false
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"\n",
"By First Approximation, r = 0.514412\n",
"By Second Approximation, r = 0.830601\n"
]
}
],
"source": [
"from math import radians\n",
"from math import tan\n",
"from math import log\n",
"\n",
"#variable declaration\n",
"def cot(x):\n",
" return 1/tan(x);\n",
"alpha=12;\n",
"r=0.2;\n",
"mu=0.09;\n",
"n=0.3;\n",
"K=1300;\n",
"v=3;\n",
"\n",
"#calculation\n",
"alpha=radians(alpha);\n",
"B=mu*cot(alpha/2);\n",
"e1=log(1/(1-r));\n",
"sigma_xa=K*e1**0.3/(n+1);\n",
"r1=1-((1-(B/(B+1)))**(1/B));\n",
"e=log(1/(1-r1));\n",
"sigma0=1300*e**0.3;\n",
"r2=1-(1-((sigma0/sigma_xa)*(B/(B+1)))**(1/B));\n",
"\n",
"#result\n",
"print('\\nBy First Approximation, r = %g\\nBy Second Approximation, r = %g')%(r1,r2);"
]
}
],
"metadata": {
"kernelspec": {
"display_name": "Python 2",
"language": "python",
"name": "python2"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 2
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython2",
"version": "2.7.9"
}
},
"nbformat": 4,
"nbformat_minor": 0
}
|