In [1]:

```
import math
#Input data
n = 6. #Number of cylinders
d = 9. #Bore in cm
l = 10. #Stroke in cm
N = 2500. #Speed in r.p.m
Ta = 25.+273 #Temperature of air entering the compressor in K
q = 16800. #Heat rate in kcal/hour
T = 60.+273 #Temperature of air leaving the cooler in K
p = 1.6 #Pressure of air leaving the cooler in kg/cm**2
t = 14.5 #Engine torque in kg.m
nv = 75. #Volumetric efficiency in percent
nm = 74. #Mechanical efficiency in percent
R = 29.27 #Characteristic gas constant in kg.m/kg.K
Cp = 0.24 #Specific heat at constant pressure n kcal/kg.K
#Calculations
BHP = (2*3.14*N*t)/4500 #Brake horse power in B.H.P
IHP = (BHP/(nm/100)) #Indicated horse power in I.H.P
pm = ((IHP*4500)/((l/100)*(3.14/4)*d**2*(N/2)*n)) #Mean effective pressure in kg/cm**2
Vs = (n*(3.14/4)*(d/100)**2*(l/100)*(N/2)) #Swept volume in m**3/min
Va = (Vs*(nv/100)) #Aspirated Volume of air into engine in m**3/min
ma = (p*10**4*Va)/(R*T) #Aspirated mass flow into the engine in kg/min
mcdT = ((BHP*4500/427)/Cp) #Product of mass flow rate and change in temperature
msdT = ((q/60)/Cp) #Product of mass flow rate and change in temperature
x = (mcdT/msdT) #Ratio
T2 = ((Ta-(x*T)))/(1-x) #Temperature in K
mc = (msdT/(T2-T)) #Air flow in kg/min
#Output
print 'a) the mean effective pressure is %3.2f kg/cm**2 \
\nb) the air consumption is %3.3f kg/min \
\nc) the air flow into the compressor is %3.2f kg/min'%(pm,ma,mc)
```

In [2]:

```
import math
#Input data
IMEP = 10. #Indicated mean effective pressure in kg/cm**2
x = 20. #Mixture strength 20% richer math.tan chemically correct
pIMEP = 0.41 #Pumping Indicated mean effective pressure in kg/cm**2
p1 = 0.97 #Charge pressure at the beginning of compression in kg/cm**2
T1 = 100.+273 #Charge temperature at the beginning of compression in K
pm = 0.91 #Mean pressure during the conduction stroke in kg/cm**2
bn = 70. #Blower adiabatic efficiency in percent
T2 = 50. #Temperature of the charge after delivery by the blower in degree C
dp = 0.07 #Pressure drop in kg/cm**2
pi = 1.47 #Charge pressure in the cylinder during the induction stroke in kg/cm**2
Ta = 15.+273 #Atomspheric temperature in K
pa = 1.03 #Atmospheric pressure in kg/cm**2
g = 1.4 #Ratio of specific heats
#Calculations
T2x = ((((pi/pa)**((g-1)/g)-1)/(bn/100))+1)*Ta+T2 #Temperature in K
rIMEP = ((pi/pa)*(T1/T2x)) #Ratio of I.M.E.P
gIMEP = (rIMEP*IMEP) #Gross I.M.E.P in kg/cm**2
nsIMEP = (gIMEP+(pi-pa)) #Net I.M.E.P supercharged in kg/cm**2
nuIMEP = (IMEP-pIMEP) #Net I.M.E.P unsupercharged in kg/cm**2
iIMEP = (nsIMEP-nuIMEP) #Increase in I.M.E.P in kg/cm**2
pei = (iIMEP*100)/nuIMEP #Percentage increase
#Output
print 'Percentage increase in the net I.M.E.P due to supercharging is %3.1f percent'%(pei)
```

In [5]:

```
import math
#Input data
l = 4.5 #Capacity in litres
P = 20. #Power in H.P per m**3 of free air induced per minute
N = 1700. #Speed in r.p.m
nv = 75. #Volumetric efficiency in percent
Ta = 27.+273 #Atomspheric temperature in K
pa = 1.03 #Atmospheric pressure in kg/cm**2
pr = 1.75 #Pressure ratio
ie = 70. #Isentropic efficiency in percent
nm = 75. #Mechanical efficiency in percent
g = 1.4 #Ratio of specific heats
nb = 80. #Efficiency of blower in percent
R = 29.27 #Characteristic gas constant in kg.m/kg.K
Cp = 0.24 #Specific heat at constant pressure in kJ/kg.K
J = 427. #Mechanical equivalent of heat in kg.m/kcal
#Calculations
Vs = (l/1000*(N/2)) #Swept volume in m**3/min
uVs = ((nm/100)*Vs) #Unsupercharged swept volume in m**3/min
dp = (pr*pa) #Blower delivery pressure in kg/cm**2
Tc = (Ta*pr**((g-1)/g)) #Temperature after isentropic compression in K
dT = (Ta+(Tc-Ta)/(ie/100)) #Blow delivery temperature in K
Va = (Vs*(dp*Ta)/(pa*dT)) #Equivalent volume at free air condition in m**3/min
iiv = (Va-uVs) #Increase in the induced volume in m**3/min
iIHP = (P*iiv) #ncrease in I.H.P
iBHP = (iIHP*(nm/100)) #Increase in B.H.P
ma = (dp*10**4*Vs)/(R*dT) #Mass of air delivered by blower in kg/min
HP = (ma*Cp*(dT-Ta)*J)/(4500*(80./100)) #H.P required for blower
nibhp = (iBHP-HP) #Net increse in engine b.h.p
pei = (nibhp/(P*uVs))*100 #Percentage increase
#Output
print 'Percentage net increase in B.H.P is %3.1f percent'%(pei)
```