# Example 7.1
# Calculation
# Applying +ΣF_y(upward) = 0 Refer fig 7-4b
A_y = 16+4-12 #[kilo Newton]
# Applying +ΣF_y(upward) = 0 to segment AB
NB = 8 #[kilo Newton]
# Applying +ΣF_y(upward) = 0 to segment DC
NC = 4 #[kilo Newton]
# Result
print"A_y = ",(A_y),"kN"
print"NC = ",(NC),"kN"
# Example 7.2
# Calculation
# Applying +ΣM_x = 0 Refer fig 7-5b
TD = -10+15+20 #[Newton meter]
# Applying +ΣM_x = 0 to segment AB
TB = -10+15 #[Newton meter]
# Applying +ΣM_x = 0 to segment CD
TC = 25 #[Newton meter]
# Result
print"TB = ",(TB),"N.m"
print"TC = ",(TC),"N.m"
# Example 7.3
from __future__ import division
# Calculation
# Applying +ΣMD(counterclockwise) = 0 Refer fig 7-6b
A_y = (9+6*6)/9
# Consider segment AB
# Applying +ΣF_x(right) = 0
NB = 0 #[kilo Newton]
# Applying +ΣF_y(upward) = 0
VB = 5 #[kilo Newton]
# Applying +ΣMB(counterclockwise) = 0
MB = 5*3 #[kilo Newton meter]
# Consider segment AC
# Applying +ΣF_x(right) = 0
NC = 0 #[kilo Newton]
# Applying +ΣF_y(upward) = 0
VC = 6-5 #[kilo Newton]
# Applying +ΣMC(counterclockwise) = 0
MC = 5*3 #[kilo Newton meter]
# Result
print"NB = ",(NB),"kN"
print"VB = ",(VB),"kN"
print"MB = ",(MB),"kN.m"
print"NC = ",(NB),"kN"
print"VC = ",(VC),"kN"
print"MC = ",(MC),"kN.m"
# Example 7.4
from __future__ import division
# Calculation
# Refer fig 7-7b
# Applying +ΣMA(counterclockwise) = 0
FDC = (400*4)/((3/5)*8) #[Newton]
# Applying +ΣF_x(right) = 0
A_x = (4/5)*333.3 #[Newton]
# Applying +ΣF_y(upward) = 0
A_y = 400-((3/5)*333.3) #[Newton]
# Applying equations of equilibrium to segment AB
# Applying +ΣF_x(right) = 0
NB = 266.7 #[Newton]
# Applying +ΣF_y(upward) = 0
VB = 200-200 #[Newton]
# Applying +ΣMB(counterclockwise) = 0
MB = 200*4-200*2 #[Newton meter]
# Result
print"NB = ",(NB),"N"
print"VB = ",(VB),"N"
print"MB = ",(MB),"N.m"
# Example 7.5
import math
from __future__ import division
# Calculation
# Using +ΣF_y(upward) = 0 Refer fig 7-8b
R = round(600/math.sin(math.pi*45/180),1) #[Newton]
# Applying equations of equilibrium
# Applying +ΣF_x(right) = 0
VE = round(R*math.cos(math.pi*45/180),1) #[Newton]
# Applying +ΣF_y(upward) = 0
NE = round(R*math.sin(math.pi*45/180),1) #[Newton]
# Applying +ΣME(counterclockwise) = 0
ME = round(R*math.cos(math.pi*45/180)*0.5,1) #[Newton meter]
# Result
print"VE = ",(VE),"N"
print"NE = ",(NE),"N"
print"ME = ",(ME),"N.m"
# Example 7.6
from __future__ import division
import numpy as np
# Calculation
W = 650*9.81 #[kilo Newton]
Fw = 900/(6*2.5) #[kilo Newton]
# Using +ΣF_x(right) = 0
FA_x = 13.5 #[kilo Newton]
FA_y = 0 #[kilo Newton]
FA_z = 6.376 #[kilo Newton]
# Using ΣMA = 0, MA + r X (Fw + W)
a = np.cross([0,3,5.25],[-13.5,0,6.376])
MA_x = round(-a[0],1) #[kilo Newton meter]
MA_y = round(-a[1],1) #[kilo Newton meter]
MA_z = round(-a[2],1) #[kilo Newton meter]
# Result
print"MA_x = ",(MA_x),"kN.m"
print"MA_y = ",(MA_y),"kN.m"
print"MA_z = ",(MA_z),"kN.m" # Correction in MA_z
# Example 7.13
from __future__ import division
import math
# Calculation
# Consider free body diagram Refer fig 7-21b
# Using +ΣME(counterclockwise) = 0
A_y = (4*15+15*10+3*2)/18 #[kilo Newton]
# Using +ΣF_y(upward) = 0
E_y = -12+4+15+3 #[kilo Newton]
# Consider leftmost section which cuts cable BC Refer fig 7-21b
# Using +ΣMC(counterclockwise) = 0
A_x = (12*8-4*5)/12 #[kilo Newton]
thetaBC = round(math.degrees(math.atan((12-4)/6.33)),1) #[Degrees]
# Using +ΣF_x(right) = 0
TBC = round(6.33/math.cos(math.pi*thetaBC/180),1) #[kilo Newton]
thetaAB = round(math.degrees(math.atan(12/6.33)),1) #[Degrees]
# Applying +ΣF_x(right) = 0 at point A
TAB = round(12/math.sin(math.pi*thetaAB/180),1) #[kilo Newton]
thetaCD = round(math.degrees(math.atan((-10.2*math.sin(math.pi*51.6/180)+15)/(10.2*math.cos(math.pi*51.6/180)))),1) #[Degrees]
# Applying +ΣF_x(right) = 0 at point C
TCD = round((10.2*math.cos(math.pi*51.6/180))/math.cos(math.pi*thetaCD/180),1) #[kilo Newton]
thetaED = round(math.degrees(math.atan(10/6.33)),1) #[Degrees]
# Applying +ΣF_x(right) = 0 at point E
TED = round(10/math.sin(math.pi*thetaED/180),1) #[kilo Newton]
print"TBC = ",(TBC),"kN"
print"TAB = ",(TAB),"kN"
print"TCD = ",(TCD),"kN"
print"TED = ",(TED),"kN"