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
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
|
{
"cells": [
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# example1.1 Page number 10\n",
"#downstream direction as x\n",
"#direction across river as y\n",
"\n",
"from math import sqrt,atan,pi\n",
"\n",
"#variable declaration\n",
"\n",
"Vx= 8 #velocity of stream, km/hour\n",
"Vy=float(20) #velocity of boat,km/hour\n",
"\n",
"V=sqrt(pow(Vx,2)+pow(Vy,2)) #resultant velocity, km/hour\n",
"theta=Vy/Vx\n",
"\n",
"alpha= atan(theta)*180/pi #angle, degrees \n",
"\n",
"print \" The resultant velocity :\",round(V,2),\"km/hour\"\n",
"print round(alpha,2),\"°\"\n"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# example 1.2 Page number 10\n",
"\n",
"\n",
"#components of force in horizontal and vertical components. \n",
"from math import cos,sin,pi\n",
"#variable declaration\n",
"\n",
"F= 20 #force in wire, KN\n",
"\n",
"#calculations\n",
"Fx= F*cos(60*pi/180) \n",
"Fy= F*sin(60*pi/180)\n",
"\n",
"print round(Fx,2),\"KN\" ,\"(to the left)\"\n",
"print round(Fy,2), \"KN\" ,\"(downward)\"\n",
"\n",
"\n"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# example 1.3 Page number 11\n",
"\n",
" #The plane makes an angle of 20° to the horizontal. Hence the normal to the plane makes an angles of 70° to the horizontal i.e., 20° to the vertical\n",
"from math import cos,sin,pi\n",
"#variable declaration\n",
"W= 10 # black weighing, KN\n",
"\n",
"#calculations\n",
"\n",
"Nor= W*cos(20*pi/180) #Component normal to the plane\n",
"para= W*sin(20*pi/180) #Component parallel to the plane\n",
"\n",
"print \"Component normal to the plane :\",round(Nor,2),\"KN\"\n",
"print \"Component parallel to the plane :\",round(para,2) , \"KN\"\n",
"\n",
"\n",
"\n"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# example 1.4 Page number 11\n",
"\n",
"#Let the magnitude of the smaller force be F. Hence the magnitude of the larger force is 2F\n",
"\n",
"from math import pi,sqrt, acos\n",
"#variable declaration\n",
"R1=260 #resultant of two forces,N\n",
"R2=float(180) #resultant of two forces if larger force is reversed,N\n",
"\n",
"\n",
"\n",
"#calculations\n",
"\n",
"F=sqrt((pow(R1,2)+pow(R2,2))/10)\n",
"F1=F\n",
"F2=2*F\n",
"theta=acos((pow(R1,2)-pow(F1,2)-pow(F2,2))/(2*F1*F2))*180/pi\n",
"\n",
"print \"F1=\",F1,\"N\"\n",
"print \"F2=\",F2,\"N\"\n",
"print \"theta=\",round(theta,1),\"°\"\n",
"\n",
"\n"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# example 1.5 Page number 12\n",
"\n",
"#Let ?ABC be the triangle of forces drawn to some scale\n",
"#Two forces F1 and F2 are acting at point A\n",
"#angle in degrees '°'\n",
"\n",
"from math import sin,pi\n",
" \n",
"#variabble declaration\n",
"cnv=pi/180\n",
"\n",
"BAC = 20*cnv #Resultant R makes angle with F1 \n",
" \n",
"ABC = 130*cnv \n",
"\n",
"ACB = 30*cnv \n",
"\n",
"R = 500 #resultant force,N\n",
"\n",
"#calculations\n",
"#sinerule\n",
"\n",
"F1=R*sin(ACB)/sin(ABC)\n",
"F2=R*sin(BAC)/sin(ABC)\n",
"\n",
"print \"F1=\",round(F1,2),\"N\"\n",
"print \"F2=\",round(F2,2),\"N\"\n",
"\n",
"\n"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# example 1.6 Page number 12\n",
"\n",
"#Let ABC be the triangle of forces,'theta' be the angle between F1 and F2, and 'alpha' be the angle between resultant and F1 \n",
"\n",
"from math import sin,acos,asin,pi\n",
"\n",
"#variable declaration\n",
"cnv= 180/pi\n",
"F1=float(400) #all forces are in newtons,'N'\n",
"F2=float(260)\n",
"R=float(520)\n",
"\n",
"#calculations\n",
"\n",
"theta=acos((pow(R,2)-pow(F1,2)-pow(F2,2))/(2*F1*F2))*cnv\n",
"\n",
"alpha=asin(F2*sin(theta*pi/180)/R)*cnv\n",
"\n",
"print\"theta=\",round(theta,2),\"°\"\n",
"print \"alpha=\",round(alpha,2),\"°\"\n",
"\n"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# example 1.7 Page number 13\n",
"\n",
"#The force of 3000 N acts along line AB. Let AB make angle alpha with horizontal.\n",
"\n",
"from math import cos,sin,pi,asin,acos\n",
"\n",
"#variable declaration\n",
"F=3000 #force in newtons,'N'\n",
"BC=80 #length of crank BC, 'mm'\n",
"AB=200 #length of connecting rod AB ,'mm'\n",
"theta=60*pi/180 #angle b/w BC & AC\n",
"\n",
"#calculations\n",
"\n",
"alpha=asin(BC*sin(theta)/200)*180/pi\n",
"\n",
"HC=F*cos(alpha*pi/180) #Horizontal component \n",
"VC= F*sin(alpha*pi/180) #Vertical component \n",
"\n",
"#Components along and normal to crank\n",
"#The force makes angle alpha + 60 with crank.\n",
"alpha2=alpha+60\n",
"CAC=F*cos(alpha2*pi/180) # Component along crank \n",
"CNC= F*sin(alpha2*pi/180) #Component normal to crank \n",
"\n",
"\n",
"print \"horizontal component=\",round(HC,1),\"N\"\n",
"print \"Vertical component = \",round(VC,1),\"N\"\n",
"print \"Component along crank =\",round(CAC,1),\"N\"\n",
"print \"Component normal to crank=\",round(CNC,1),\"N\""
]
}
],
"metadata": {
"anaconda-cloud": {},
"kernelspec": {
"display_name": "Python [Root]",
"language": "python",
"name": "Python [Root]"
},
"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.12"
}
},
"nbformat": 4,
"nbformat_minor": 0
}
|