In [1]:

```
from __future__ import division
from math import asin, pi
W=20e3#
m=W/9.81#
#diameter of brake drum
Db=0.6#
p=1#
Vi=1#
Vf=0#
D=1#
R=0.5#
wi=Vi/R#
wf=0#
w=1#
Vav=0.5#
S=2#
t=S/Vav#
#angle turned by by hoist drum=theta
theta=0.5*wi*t#
K_E=0.5*m*Vi**2#
P_E=2*W#
T_E=K_E+P_E#
T=T_E/theta#
P=wi*T*10**-3#
Rb=Db/2#
Ft=0.5*T*p/Rb#
u=0.35#
N=Ft/u#
#contact area of brake lining=A
A=N/p#
b=0.3*Db#
L=A*10**-6/(b)#
#angle subtended at brake drum centre=theta2
theta2=2*(asin(L/Db))#
theta2=theta2*180/pi# # converting radian to degree
print "T is %0.1f Nm "%(T)#
print "\nP is %0.4f kW "%(P)#
print "\nb is %0.2f m "%(b)#
print "\nL is %0.3f m "%(L)#
print "\ntheta2 is %0.0f deg "%(theta2)#
```

In [2]:

```
from math import exp,pi
b=80#
t=2#
theta=225*pi/180#
u=0.22#
#F1/F2=e**(u*theta)
#let F1/F2=x#
x=exp(u*theta)#
#maximum tensile stress in steel tape is siga
siga=60#
A=b*t#
F1=siga*A#
F2=F1/x#
r=0.2#
T=(F1-F2)*r#
OA=30#
OB=100#
OC=350#
P=((F2*OB)+(F1*OA))/OC#
OA=F2*OB/F1#
print "F1 is %0.0f N "%(F1)#
print "\nF2 is %0.1f N "%(F2)#
print "\nT is %0.2f Nm "%(T)#
print "\nOA is %0.2f mm "%(OA)#
```

In [3]:

```
from math import sin,pi
theta=pi/3#
r=160#
u=0.3#
pmax=0.9#
b=40#
R=(4*r*sin(theta))/((2*theta)+sin(2*theta))#
#frictional torque is T
T=2*u*pmax*b*(r**2)*sin(theta)#
T=2*T*10**-3#
Rx=0.5*pmax*b*r*((2*theta)+(sin(2*theta)))*10**-3#
Ry=u*Rx#
print "T is %0.2f Nmm "%(T)#
print "\nR is %0.3f mm "%(R)#
print "\nRx is %0.3f kN "%(Rx)#
print "\nRy is %0.2f kN "%(Ry)#
```

In [4]:

```
from math import sin, cos, pi, sqrt
d=320#
r=d/2#
b=50#
u=0.3#
pmax=1#
c=115*2#
# From to fig. 23-9, distance OA=R is calculated.
R=sqrt(115**2+66.4**2)#
C=115*2#
theta1=0#
theta2=120*pi/180#
theta0=120*pi/180#
thetamax=pi/2#
Tr=u*pmax*b*r**2*(cos(theta1)-cos(theta2))/sin(thetamax)*10**-3#
#the notation 'r' is used for moments of right hand shoe, similarly 'l' for the left shoe.
Mfr=u*pmax*b*r*(4*r*(cos(theta1)-cos(theta2))+(R*(cos(2*theta1)-cos(2*theta2))))/(4*sin(thetamax))*10**-3#
Mpr=pmax*b*r*R*((2*theta0)-(sin(2*theta2)-(sin(theta1))))/(4*sin(thetamax))*10**-3#
F=(Mpr-Mfr)/c*10**3#
#Mpl+Mfl=F*c#
x=F*c*10**-3#
y=(Mpr/pmax)+(Mfr/pmax)#
pmax2=x/y#
Tl=pmax2*Tr#
Mpl=pmax2*Mpr#
Mfl=pmax2*Mfr#
T=Tl+Tr#
print "Tr is %0.0f Nm "%(Tr)#
print "\nMf is %0.2f Nm "%(Mfr)#
print "\nMp is %0.2f Nm "%(Mpr)#
print "\nTl is %0.1f Nm "%(Tl)#
print "\nMfl is %0.2f Nm "%(Mfl)#
print "\nMpl is %0.2f Nm "%(Mpl)#
print "\nF is %0.1f N "%(F)#
print "\nT is %0.1f Nm "%(T)#
#The difference in the answers are due to rounding-off of values.
```

In [5]:

```
m=1100#
V=65*5/18#
t=4#
r=0.22#
mb=12#
C=460#
S=0.5*V*t#
#Total kinetic energy TE=K.E(vehicle)+K.E(rotating parts).
TE=((0.5*m*(V**2))+(0.1*0.5*m*(V**2)))#
E=TE/4#
w=V/r#
theta=S/r#
T=E/theta#
delT=E/(mb*C)#
print "S is %0.2f m "%(S)#
print "\nE is %0.2f Nm "%(E)#
print "\nT is %0.2f Nm "%(T)#
print "\ndelT is %0.2f "%(delT)#
#The difference in the answers are due to rounding-off of values.
```

In [6]:

```
from math import sqrt,asin,pi
T=35000#
u=0.4#
p=0.7#
r=200#
N=T/(u*r)
b=sqrt(N/p)#
l=b#
#2theta = theta2
theta2=2*asin(l/(2*r))#
F=u*N#
P=((250*N)-(u*N*80))/550#
Ry=N-P#
Rx=u*N#
R=sqrt(Rx**2+Ry**2)#
w=2*pi*100/60#
# Rate of heat generated is Q
Q=u*N*w*r/1000#
print "N is %0.1f N "%(N)#
print "\nb is %0.0f mm "%(b)#
print "\nP is %0.1f N "%(P)#
print "\nR is %0.2f N "%(R)#
print "\nQ is %0.2f J/s "%(Q)#
#The answer to Rate of heat generated 'Q' is calculated incorrectly in the book.
```

In [7]:

```
from math import pi,sqrt
Vi=20*5/18#
Vf=0#
m=80#
pmax=1#
u=0.1#
S=50#
KE=0.5*m*Vi**2#
N=KE/(u*S*2)#
t=sqrt(N/(pmax*3))#
b=3*t#
print "KE is %0.1f Nm "%(KE)#
print "\nN is %0.2f N "%(N)#
print "\nt is %0.1f mm "%(t)#
print "\nb is %0.1f mm "%(b)#
#The difference in the answers are due to rounding-off of values.
```