import math
#Initialization of variables
nu = 0.001 #ft**2 /s
L = 1.5 #ft
U = 2. #ft/s
s = 0.925
ro = 1.94
b = 6.
#calculations
R = L*U/nu
Cf = 1.328/math.sqrt(R)
Ff = Cf*s*ro*U*b/12 *L
delta = 4.91 *L/math.sqrt(R)
T0 = 0.332*nu*s*ro*U/L *math.sqrt(R)
print R
#Results
print "Friction drag = %.3f lb"%(Ff)
print " Thickness of boundary layer = %.4f ft"%(delta)
print " Shear stress = %.4f lb/ft**2"%(T0)
#Similar calculations are done for SI units case
import math
#Initialization of variables
nu = 0.00015 #ft**2/s
L = 35. #ft
U = 88. #fps
g = 32.2 #ft/s**2
b = 10. #ft
w = 8. #ft
rho = 0.0725
#calculations
R = L*U/nu
Cf = 0.455 /(math.log10(R))**2.58
B = 2*b + w
Ff = Cf*rho/g *U**2 /2 *L*B
Rx = R/10**5
delta = L*0.377 /(b* Rx**(0.2))
T0 = 0.0587 *rho/g *U**2 /2 *(nu/(L*U))**(0.2)
#Results
print "Frictional drag = %.1f lb"%(Ff)
print " Thickness of boundary layer = %.3f ft"%(delta)
print " Shear stress = %.4f lb/ft**2"%(T0)
import math
#Initialization of variables
nu = 0.0000166 #ft**2 /s
U = 5.06 #fps
L = 50. #ft
g = 32.2
dia = 10. #ft
#calculations
R = L*U/nu
Cf = 0.0028
Ff = Cf*64/g *U**2 /2 *math.pi*dia*L
Rx = R/L
ec = 26*nu/U *Rx**(0.25)
Rx2 = Rx*L/2
T02 = 0.0587*U**2 /2 /(Rx2)**(0.2)
delta2 = 60*nu/math.sqrt(T02)
#Results
print "Friction drag = %.f lb"%(Ff)
print " Critical roughness = %.4f ft"%(ec)
print " height of roughness = %.4f ft"%(delta2)
import math
#Initialization of variables
Cd = 0.45
rho = 0.0725/32.2
V = 88. #fps
A = 8*10.
#calculations
Fd = Cd*rho*V**2 /2 *A
Drag2 = 23
D = Fd-Drag2
#Results
print "Pressure drag = %.f lb"%(D)
from sympy import Symbol,solve
import math
#Initialization of variables
Cd = 0.2
D = 8.5/12 #in
v = 1.57*10**-4
rho = 0.00238
#calculations
A = (math.pi*D**2)/4
#From trail and error method,
V = 412 #fps
R = (D*V)/v
#Results
print "Free fall velocity = %.2e fps"%(R)
print "Since the values of R and Cd check with the figure, V = 412 fps"
#Initialization of variables
nu = 1.15*10**-5 #m**2/s
D = 2.*10**-3 #m
V = 15. #m/s
T = -20. #C
#calculations
R = D*V/nu
f = 0.2 *V/D *(1+T/R)
#Results
print "Frequency of oscillation = %d Hz"%(round(f,-2))
import math
#Initialization of variables
n = 90. #rpm
R = 2.
rho = 0.0765/32.2
B = 25.
U = 120. #fps
#calculations
vt = 2*math.pi*R*n/60
T = 2*math.pi*R*vt
Fl = rho*B*U*T
theta = math.degrees(math.asin(-T/(4*math.pi*R*U)))
#Results
print "Peripheral velocity = %.2f fpx"%vt
print "Value of circulation = %.f ft62/s"%(T)
print " Transverse or lift force = %d lb"%(round(Fl,-1))
print " Position of stagnation points = %.1f degrees"%(180-theta)
import math
#Initialization of variables
B = 36. #ft
c = 6. #ft
Cl = 0.8
tau = 0.175
rho = 0.001756
V = 300. #fps
#calculations
alphai = Cl/(math.pi*B/c) *(1+tau) *180/math.pi
alpha = 5.4
lift = -5.6 #degrees
alphao = alpha-alphai
alphaod = alphao-lift
alphaor = alphaod*math.pi/180
eta = Cl/(2*math.pi*alphaor)
Fl = Cl*rho*V**2 /2 *B*c
Fd = 0.047/Cl *13680
HP = Fd*V/550
#Results
print "Friction coefficient = %.3f "%(eta)
print " weight of the wing = %d lb"%(round(Fl,-1))
print " Horsepower required = %d hp"%(HP)
# rounding off error
import math
#Initialization of variables
k = 1.4
R = 287.
T = 249. #K
v = 600. #velocity - m/s
d = 0.2 #diameter - m
#calculations
c = math.sqrt(k*R*T)
M = v/c
Cd = 0.62
rho = 47.22*10**3 /(R*T)
Fd = Cd*rho*v**2 /2 *math.pi*d**2 /4
#Results
print "Drag = %d N"%(Fd)
# note : answer is accurate