from __future__ import division
from math import pi
# Initialisation of Variables
d=0.1#..................#Cylinder bore in m
l=0.12#................#Cylinder stroke in m
N=1800#..................#Engine rpm
d2=0.028#................#Throat diameter in m
Cda=0.8#................#Co efficient of air flow
etaV=0.75#..................#Volumetric efficiency
rhoa=1.2#................#Density of air in kg/m**3
n=4#.......................#No of cylinders
#Calculations
Vs=(pi/4)*d*d*l*n#.................#Stroke Volume in m**3
Va=etaV*Vs#.......................#Actual volume per stroke in m**3
Vas=Va*(N/2)*(1/60)#.............#Actual volume sucked per second
ma=Vas*rhoa#.........................#Air consumed in kg/sec
delp=((ma/(Cda*(pi/4)*d2*d2))**2)/(2*rhoa)#.............#Suction at throat in N/m**2
print "Suction at throat = %0.2f N/m**2 "%delp
from __future__ import division
from math import sqrt
# Initialisation of Variables
cp=5#.................#Consumption of petrol in kg/h
afr = 16#...............#Air fuel ratio
Af=2*10**(-6)#..............#Fuel orifice area in m**2
z=0.005#................#Distance between tip of jet and level of petrol in float chamber in m
spgrp=0.75#..............#Specific gravity of petrol
rhow=1000#.................#Density of water in kg/m**3
rhoa=1.2#....................#Density of air in kg/m**3
Cda=0.8#...............#Coefficient of discharge for venturi throat
g=9.81#...............#Acceleration due to gravity in m/sec**2
#Calculations
mf=cp/3600#.................#Fuel consumed in kg/sec
delp=(((mf/(Af*Cda))**2)*(1/(2*spgrp*rhow)))+(g*z*spgrp*rhow)#
print "Suction at the throat = %0.2f N/m**2 "%delp
ma=mf*afr#................#Air flow rate
Atsqr=((ma/Cda)**2)*(1/(2*rhoa*delp))#....................#Throat area in m**2
print "Throat area = %0.2f cm**2 "%(sqrt(Atsqr)*10**4)
from __future__ import division
from math import pi,sqrt
# Initialisation of Variables
pc=7.2#.................#Petrol consumed in kg/h
spgrp=0.75#................#Specific gravity of fuel
rhow=1000#.................#Density of water in kg/m**3
t1=300#...................#Temperature of air in Kelvin
afr=15#....................#Air fuel ratio
d2=0.024#....................#Diameter of choke tube in m
z=0.0042#...................#The height of the jet above petrol level in float chamber in m
Cda=0.8#....................#Coefficient of discharge for air
Cdf=0.7#.....................#Coefficient of discharge for fuel
p1=1.013#.....................#Atmospheric pressure in bar
g=9.81#.......................#Acceleration due to gravity in m/s**2
R=287#........................#Gas constant in J/kg.K
#calculations
mf=pc/3600#....................#Rate of fuel consumption in kg/sec
rhof=spgrp*rhow#...............#Density of fuel in kg/m**3
rhoa=(p1*10**5)/(R*t1)#............#Density of air in kg/m**3
ma=mf*afr#.......................#Air flow rate
delpa=((ma/(Cda*(pi/4)*d2**2))**2)*(1/(2*rhoa))#....................#Suction in N/m**2
df=sqrt((mf/sqrt(2*rhof*(delpa-(g*z*rhof))))*(1/(Cdf*(pi/4))))#.................#Diameter of fuel jet in m
print "Diameter of the fuel jet = %0.2f mm"%(df*1000)
from __future__ import division
from math import sqrt,pi
# Initialisation of Variables
pc=5.45#......................#Petrol consumption in kg/h
afr=15#......................#Air fuel ratio
af=2*10**(-6)#................#Fuel jet orifice area in m**2
z=0.00635#...................#Distance between tip of fuel jet and level of petrol in the float chamber in m
Cda=0.8#............................#Coefficient of discharge of venturi throat
rhoa=1.29#........................#Density of air in kg/m**3
spgrp=0.72#........................#Specific gravity of fuel
rhow=1000#.........................#Density of water in kg/m**3
g=9.81#..............................#Acceleration due to gravity in m/s**2
Cdf=0.75#........................#Coefficient of discharge of the fuel
#calculations
mf=pc/3600#....................#Fuel consumed in kg/sec
rhof=spgrp*rhow#...............#Density of fuel in kg/m**3
delp=(((mf/(af*Cdf))**2)*(1/(2*rhof)))+(g*z*rhof)#......................#Depression in venturi throat in N/m**2
h2odep=delp/(g*1000)#................................#Depression in venturi throat in cm of Water
print "Suction at the throat = %0.2f cm of Water "%(h2odep*100)
ma=mf*afr#................#Air flow rate
At=sqrt(((ma/Cda)**2)*(1/(2*rhoa*delp)))#....................#Throat area in m**2
dt=sqrt(At/(pi/4))#........................................#Throat diameter in m
print "Throat area = %0.2f cm "%(dt*100)
Ct=sqrt((2*g*z*rhof)/rhoa)#..........................#Velocity of air across the venturi throat in m/sec
print "Velocity of air across the venturi throat = %0.2f m/s "%(Ct)
from __future__ import division
from math import sqrt,pi
# Initialisation of Variables
afr=15#.....................#Air fuel ratio
p1=1#.........................#Atmospheric pressure in bar
p2=0.8#.......................#Pressure at venturi throat in bar
pd=30#....................#Pressure drop to air cleaner in mm of Hg
rhohg=13600#....................#Density of Hg in kg/m**3
af=240#........................#Air flow at sea level in kg/h
g=9.81#.....................#Acceleration due to gravity in m/s**2
#calculations
delpa=p1-p2#........................#When there is no air cleaner
pt=1-(rhohg*g*(pd/1000)*10**(-5))-delpa#..........................#Throat pressure in bar
print "Throat pressure = %0.2f bar "%pt
afrn=afr*sqrt(delpa/(p1-pt))#...............................#Air fuel ratio when the air cleaner is fitted
print "Air fuel ratio when the air cleaner is fitted : %0.2f"%afrn
from __future__ import division
from math import sqrt,pi
# Initialisation of Variables
As=4.6#........................#Air supply in kg/min
p1=1.013#.......................#Atmospheric pressure in bar
t1=298#......................#Atmospheric temperature in Kelvin
C2=80#........................#Air flow velocity in m/s
Cv=0.8#....................#Velocity co efficient
ga=1.4#........................#Degree of freedom of gas
R=0.287#........................#Gas constant in kJ/kgK
#Calculations
cp=R*(ga/(ga-1))#.......................#Specific heat capacity of air in kJ/kgK
p2=((1-(((C2/Cv)**2)*(1/(2*cp*1000*t1))))**(ga/(ga-1)))*p1#...................#Throat pressure in bar
rho1=(p1*10**5)/(R*1000*t1)#
rho2=rho1*(p2/p1)**(1/ga)#
ma=As/60#...................#Air flow in kg/s
A2=ma/(rho2*C2)#.................#Throat area in m**2
d2=sqrt((4*A2)/pi)#................#Throat diameter in m
print "Throat diameter = %0.2f m"%d2
from __future__ import division
from math import sqrt,pi
# Initialisation of Variables
As=6#........................#Air supply in kg/min
fs=0.45#..........................#Fuel supply in kg/min
p1=1.013#.......................#Atmospheric pressure in bar
t1=300#......................#Atmospheric temperature in Kelvin
rhof=740#......................#Density of fuel in kg/m**3
C2=92#........................#Air flow velocity in m/s
Cda=0.8#....................#Velocity co efficient
Cdf=0.6#.........................#Coefficient of discharge for fuel
ga=1.4#........................#Degree of freedom of gas
r=0.75#......................#ratio of pressure drop across venturi and of that of choke
R=0.287#........................#Gas constant in kJ/kgK
#Calculations
ma=As/60#.................................#Air flow in kg/s
mf=fs/60#.................................#Fuel flow in kg/s
cp=R*(ga/(ga-1))#.......................#Specific heat capacity of air in kJ/kgK
p2=((1-(((C2/Cda)**2)*(1/(2*cp*1000*t1))))**(ga/(ga-1)))*p1#...................#Throat pressure in bar
v1=(R*t1*1000)/(p1*10**5)#
v2=v1*(p1/p2)**(1/ga)#................#specific volume in m**3/kg
A2=(ma*v2)/(C2)#.................#Throat area in m**2
d2=sqrt((4*A2)/pi)#................#Throat diameter in m
print "Throat diameter = %0.2f cm "%(d2*100)
pdv=p1-p2#..........#Pressure drop at venturi in bar
pdj=r*pdv#.............#Pressure drop at jet in bar
Af=((mf/Cdf)*(1/sqrt(2*rhof*pdj*10**5)))#.............#Area of orifice in m**2
df=sqrt((4*Af)/pi)#................#Orifice diameter in m
print "Orifice diameter = %0.4f cm "%(df)
from __future__ import division
from math import sqrt,pi
# Initialisation of Variables
Vs=1489*10**(-6)#.......................#Capacity of engine in m**3
N=4200#...............#Engine rpm at which max speed is developed
etaV=0.75#.....................#Volumetric efficiency
afr=13#........................#air fuel ratio
Ct=85#..........................#Theoretical air speed at peak power in m/s
C2=Ct#
Cda=0.82#....................#Coefficient of discharge for the venturi
Cdf=0.65#....................#Coefficient of discharge of main petrol jet
spgr=0.74#..................#Specific gravity of petrol
z=0.006#.................................#Level of petrol surface below choke
p1=1.013#......................#Atmospheric pressure in bar
t1=293#.........................#Atmospheric temperature in Kelvin
r=0.4#.............................#Ratio of diameter of emulsion tube to choke diameter
R=0.287#.............................#Gas constant in kJ/kgK
ga=1.4#..............................#Degree of freedom for air
g=9.81#..............................#Acceleration due to gravity in m/s**2
rhow=1000#...........................#Density of water in kg/m**3
#calculations
rhof=rhow*spgr#............................#Density of fuel in kg/m**3
Va=(etaV*Vs*N)/(60*2)#.....................#Volume of air induced in m**3/s
ma=(p1*10**5*Va)/(R*t1*1000)#...............#mass flow of air in kg/s
cp=R*(ga/(ga-1))#.......................#Specific heat capacity of air in kJ/kgK
p2=((1-(((C2)**2)*(1/(2*cp*1000*t1))))**(ga/(ga-1)))*p1#...................#Throat pressure in bar
pt=p2#
vt=Va*(p1/p2)**(1/ga)#.....................#Volume flow of air at choke in m**3/s
At=vt/(Ct*Cda)#...................#Area of emulsion tube in m
D=sqrt((4*At*10**6)/(pi*(1-r**2)))#...................#Diameter of choke in mm
print "Diameter of choke = %0.2f mm "%D
mf=ma/afr#..................#Mass flow of fuel in kg/s
delpa=(p1-p2)*10**5#
df=sqrt((mf/sqrt(2*rhof*(delpa-(g*z*rhof))))*(1/(Cdf*(pi/4))))#.................#Diameter of fuel jet in m
print "Diameter of the fuel jet = %0.2f mm "%(df*1000)
from __future__ import division
from math import sqrt,pi
# Initialisation of Variables
da=0.018#..........................#Throat Diameter in m
df=0.0012#......................#Diameter of fuel orifice in m
Cda=0.82#.................#Coefficient of air flow
Cdf=0.65#......................#Coefficient of fuel flow
z=0.006#........................#Level of petrol surface below the throat
rhoa=1.2#.......................#density of air in kg/m**3
rhof=750#.........................#density of fuel in kg/m**3
g=9.81#........................#Acceleration due to gravity in m/s**2
delp=0.065*10**5#...................#Pressure drop in N/m**2
#Calculations
afr1=(Cda/Cdf)*((da/df)**2)*sqrt(rhoa/rhof)#..................#Air fuel ratio when the nozzle lip is neglected
print "Air fuel ratio when the nozzle lip is neglected : ",round(afr1,2)
afr2=afr1*sqrt(delp/(delp-(g*z*rhof)))#.....................#Air fuel ratio when nozzle lip is taken into account
print "Air fuel ratio when nozzle lip is taken into account : ",round(afr2,2)
C2=sqrt((2*g*z*rhof)/rhoa)#.........................#Minimum velocity of air in m/s
print "Minimum velocity of air = %0.2f m/s"%C2
from __future__ import division
from math import sqrt,pi
# Initialisation of Variables
d=0.11#..................#Engine bore in m
l=0.11#..................#Engine length in m
da=0.042#................#Throat diameter of the choke tube in m
N=3000#..................#Engine rpm
etaV=0.75#...............#Volumetric efficiency
Ra=287#..................#Gas constant for air in J/kgK
Rv=97#...................#Gas constant for fuel vapour in J/kgK
t=273#....................#Temperature in Kelvin
p=1.013#...................#Pressure in bar
delpa=0.12#.................#Pressure depression in bar
t2=273+15#...................#Temperature at throat
n=8#........................#No of cylinders
mO=32#.......................#Mass of Oxygen molecule in amu
mC=12#........................#Mass of Carbon molecule in amu
mH=1#.......................#Mass of Hydrogen molecule in amu
cC=84#......................#Composition of carbon in %
cH2=16#.....................#Composition of Hydrogen in %
#Calculations
Vfm=(pi/4)*d*d*l*n*(N/2)*etaV#.....................#Volume of fuel mixture supplied in m**3/min
afr=((cC*(mO/mC))+(cH2*(mO/(4*mH))))/23#..................#Air fuel ratio
va=(Ra*t)/(p*10**5)#.....................#Volume of 1 kg of air in m**3/kg
vf=(Rv*t)/(p*10**5)#......................#Volume of 1 kg of fuel vapour in m**3/kg
fc=(Vfm/((afr*va)+vf))*60#...............#Fuel consumption in kg/h
print "Fuel consumption = %0.2f kg/h "%fc
rhoa=((p-delpa)*10**5)/(Ra*t2)#...............#Density of air at the throat in kg/m**3
Ca=(afr*(fc/3600))/((pi/4)*da*da*rhoa)#................#Velocity of air at the throat in m/s
print "Velocity of air at the throat = %0.2f m/s "%Ca
from __future__ import division
from math import sqrt,pi
# Initialisation of Variables
a=4500#.................#Altitude
afr=14#...............#Air fuel ratio at sea level
t1=25#...........#Temperature at sea level in Celsius
p1=1.013#...........#Pressure at sea level in bar
#Calculations
t2=t1-(0.0064*a)#.........................#Temperature at the given altitude using the given formula in Celsius
p2=p1/(10**(a/19300))#....................#Pressure at the given altitude using the given formula in bar
afr2=afr*sqrt((p2*(t1+273))/(p1*(t2+273)))#...................#Air fuel ratio at the altitude
print "Air fuel ratio at the altitude : %0.2f"%afr2