Problem 1. Write a computer program (preferably in Excel

Problem 1. Write a computer program (preferably in Excel VBA) that converts a gaseous pollutant’s
mass concentration in the atmosphere into volumetric concentration.
The program will ask the following in order:





The mass concentration value
The mass concentration unit (mg/m3, µg/m3, ng/m3, or pg/m3)
The molar mass of the pollutant (g/mole)
Gas temperature (°C)
The volumetric concentration unit (ppm, ppb, or ppt)
The program will be run through the Excel sheet via a command button on the sheet. The inputs may be
through input boxes or through cells. The output will be given via a MsgBox statement as follows:
[Put_Mass_Concentration_Here] [Put_Unit_here] at 1 atm and [Put_Temperature_Here] °C = [Put_Calculated_Concentration_Here] [Put_Unit_Here].
Make the following unit conversions using your computer program:
a.
b.
c.
d.
e.
f.
g.
h.
250 mg/m3 of benzene (C6H6) at 25 °C into ppm.
250 µg/m3 of benzene (C6H6) at 25 °C into ppb.
250 ng/m3 of benzene (C6H6) at 25 °C into ppt.
920 mg/m3 of sulfur dioxide (SO2) at 140 °C into ppm.
1500 µg/m3 of sulfur dioxide (SO2) at 25 °C into ppb.
35 µg/m3 of toluene (C7H8) at 15 °C into ppt.
22 mg/m3 of xylene (C8H10) at 120 °C into ppb.
75 mg/Nm3 of benzene (C6H6) into ppm.
PS: Assume R = 0.08205746 atm.L/mole.K and TK = TC + 273.15
Problem 2. Write a computer program (preferably in Excel VBA) that converts a gaseous pollutant’s
volumetric concentration in the atmosphere into mass concentration.
The program will ask the following in order:





The volumetric concentration value
The volumetric concentration unit (ppm, ppb, or ppt)
The molar mass of the pollutant (g/mole)
Gas temperature (°C)
The mass concentration unit (mg/m3, µg/m3, ng/m3, or pg/m3)
The program will be run through the Excel sheet via a command button on the sheet. The inputs may be
through input boxes or through cells. The output will be given via a MsgBox statement as follows:
[Put_Volumetric_Concentration_Here] [Put_Unit_here] =[Put_Calculated_Concentration_Here] [Put_Unit_Here] at 1 atm and [Put_Temperature_Here] °C.
Make the following unit conversions using your computer program:
a.
b.
c.
d.
e.
f.
50 ppm of benzene (C6H6) into mg/m3 at 30 °C.
18 ppb of toluene (C7H8) into µg/m3 at 5 °C.
65 ppb of sulfur dioxide (SO2) into µg/m3 at 40 °C.
2400 ppm of carbon monoxide (CO) into mg/m3 at 160 °C.
450 ppb of nitrogen dioxide (NO2) into µg/m3 at 10 °C.
78.4 ppb of benzene (C6H6) into µg/m3 at 25 °C.
Problem 3. Write a computer program (preferably in Excel VBA) that makes pressure and temperature
corrections for pollutant concentration in stack gases.
The program will ask the following in order:




Actual stack gas concentration of the pollutant (mg/m3)
Stack gas temperature (°C)
Absolute stack gas pressure (atm, mmHg, or mb)
Correction base (normal conditions or standard conditions)
The program will be run through the Excel sheet via a command button on the sheet. The inputs may be
through input boxes or through cells. The output will be given via a MsgBox statement as follows:
[Put_Actual_Concentration_Here] mg/m3 at [Put_Pressure_Here] and [Put_Temperature_Here] °C. = [Put_Corrected_Concentration_Here] [mg/Nm3 or
mg/Sm3].
Make the following corrections using your computer program:
a.
b.
c.
d.
e.
f.
120 mg/m3 of particulate matter at 1020 mb and 120°C into normal conditions.
120 mg/m3 of particulate matter at 1020 mb and 120°C into standard conditions.
740 mg/m3 of sulfur dioxide at 768 mmHg and 140°C into normal conditions.
740 mg/m3 of sulfur dioxide at 768 mmHg and 140°C into standard conditions.
67 mg/m3 of benzene at 1.01 atm and 150°C into normal conditions.
67 mg/m3 of benzene at 1.01 atm and 150°C into standard conditions
PS: Normal conditions refer to 1 atm and 0°C, standard conditions refer to 1 atm and 25°C.
Problem 4. Write a computer program (preferably in Excel VBA) that makes reference oxygen and
humidity corrections for pollutant concentration in stack gases to calculate pollutant concentration on
dry basis at given reference oxygen concentration.
The program will ask the following in order:




Pollutant concentration (mg/m3)
Stack gas oxygen concentration (%)
Stack gas humidity (%)
Reference oxygen concentration (%)
The program will be run through the Excel sheet via a command button on the sheet. The inputs may be
through input boxes or through cells. The output will be given via a MsgBox statement as follows:
The concentration on dry basis at [Put_Reference_Oxygen_Here] % oxygen is [Put_Corrected_Concentration_Here] mg/m3.
Calculate the dry basis concentrations at 3% reference oxygen using your computer program:
a.
b.
c.
d.
e.
170 mg/m3 of sulfur dioxide, 6% oxygen, 4.3% humidity.
32 mg/m3 of benzene, 5.7% oxygen, 4.7% humidity.
15 mg/m3 of toluene, 3% oxygen, 5.3% humidity.
150 mg/m3 of particulate matter, 4.8% oxygen, 7.6% humidity.
100 mg/m3 of particulate matter, 5.6% oxygen, dry gas.