import math
# Variables:
c = 1.2
b = 2.7 #m
#Solution:
#Calculating the inclination of the track arm to the longitudinal axis
alpha = math.tan(c/(2*b))*180/math.pi #degrees
#Results:
print " Inclination of the track arm to the longitudinal axis, alpha = %.1f degrees."%(alpha)
import math
# variables
a = 180. - 160. # degrees
N = 1500. # r.p.m.;
m = 12. # kg ;
k = 0.1 # m
# calculations
w = round(2*math.pi*N/60)
I = m*k**2
cos2theta = 2*math.sin(math.radians(a))**2/(2 - math.sin(math.radians(a))**2)
theta = math.degrees(math.acos(cos2theta))/2
dw1bydt = w**2*math.cos(math.radians(a)) * math.sin(math.radians(2*theta)) * math.sin(math.radians(a))**2 / ( 1 - math.cos(math.radians(theta))**2 * math.sin(math.radians(a))**2)**2
max_t = I * dw1bydt
# results
print "Maximum angular acceleration of the driven shaft : %.f rad/s**2"%dw1bydt
print "maximum torque required : %.f N-m"%max_t
# answers are different because of rounding error. please check using calculator.
import math
# Variables:
alpha = 18*math.pi/180 #radians
#Solution:
#Maximum velocity is possible when
theta1 = 0.
theta2 = 180. #degrees
#Calculating the angle turned by the driving shaft when the velocity ratio is unity
theta3 = math.cos(math.sqrt((1-math.cos(alpha))/(math.sin(alpha)**2)))*180/math.pi #degrees
theta4 = 180-theta3 #degrees
#Results:
print " Angle turned by the driving shaft when the velocity ratio is maximum, theta = %d degrees\
or %d degrees."%(theta1,theta2)
print " Angle turned by the driving shaft when the velocity ratio is unity, theta = %.1f degrees or\
%.1f degrees."%(theta3,theta4)
import math
# Variables:
N = 500. #rpm
#Solution:
#Calculating the angular velocity of the driving shaft
omega = 2*math.pi*N/60.0 #rad/s
#Calculating the total fluctuation of speed of the driven shaft
q = 12./100*omega #rad/s
#Calculating the greatest permissible angle between the centre lines of the shafts
#alpha = math.cos((-(q/omega)+math.sqrt(0.12**2+4))/2.0)*180/math.pi #degrees
cosalpha =((-(q/omega)+math.sqrt(0.12**2+4))/2.0) #degrees
alpha = math.degrees(math.acos(cosalpha))
#Results:
print " Greatest permissible angle between the centre lines of the shafts, alpha = %.2f degrees."%(alpha)
import math
# Variables:
N = 1200.
q = 100. #rpm
#Solution:
#Calculating the greatest permissible angle between the centre lines of the shafts
cosalpha = ((-(100./1200)+math.sqrt(0.083**2+4))/2)
alpha = math.degrees(math.acos(cosalpha)) #degrees
#Calculating the maximum speed of the driven shaft
N1max = N/cosalpha #rpm
#Calculating the minimum speed of the driven shaft
N1min = N*cosalpha #rpm
#Results:
print " Greatest permissible angle between the centre lines of the shafts, alpha = %.1f degrees."%(alpha)
print " Maximum speed of the driven shaft, N1max = %d rpm."%(N1max)
print " Minimum speed of the driven shaft, N1min = %d rpm."%(N1min)
import math
# variables
N = 240. # r.p.m
w = 2 * math.pi * 240./60 #rad/s
alpha = 20
m = 55. # kg ;
k = .150
mm = 0.15 #m ;
T1 = 200. #N-m ;
theta = 45. # ° ;
q = 24. # r.p.m.
# calculations
I = round(m * k**2,2)
dw1bydt = round(-(w**2)*math.cos(math.radians(alpha))*math.sin(math.radians(2*theta))*math.sin(math.radians(alpha))**2 / (1- math.cos(math.radians(theta))**2 * math.sin(math.radians(alpha))**2)**2,2)
T2 = I * dw1bydt
T = T1 + T2
Tdash = T*math.cos(math.radians(alpha))/(1-math.cos(math.radians(theta))**2 * math.sin(math.radians(alpha))**2)
cosapha = (-0.1+math.sqrt((0.1**2)+4))/2
alpha = math.degrees(math.acos(cosapha))
# result
print "T' = %.1f N-m"%Tdash
print "Alpha a = %.1f degrees"%alpha
# rounding off error
import math
# Variables:
alpha = 20. #degrees
NA = 500. #rpm
#Solution:
#Calculating the maximum speed of the intermediate shaft
NBmax = NA/math.cos(math.radians(alpha)) #rpm
#Calculating the minimum speed of the intermediate shaft
NBmin = NA*math.cos(math.radians(alpha)) #rpm
#Calculating the maximum speed of the driven shaft
NCmax = NBmax/math.cos(math.radians(alpha)) #rpm
#Calculating the minimum speed of the driven shaft
NCmin = NBmin*math.cos(math.radians(alpha)) #rpm
#Results:
print " Maximum speed of the intermediate shaft( NBmax) = %.1f rad/s."%(NBmax)
print " Minimum speed of the intermediate shaft( NBmin) = %.2f rad/s."%(NBmin)
print " Maximum speed of the driven shaft( NCmax) = %.2f rad/s."%(NCmax)
print " Minimum speed of the driven shaft( NCmin) = %.1f rad/s."%(NCmin)