Question: Write a VBA subroutine to compute the average molecular weight of a gas mixture (MW average) with the following composition by mass (mass of

Write a VBA subroutine to compute the average molecular weight of a

Write a VBA subroutine to compute the average molecular weight of a gas mixture (MW average) with the following composition by mass (mass of component/total mass). Recall: MWaverage = where yi is the component mole fraction and M; is the component molecular weight. Hint make an assumption for the total mass). The user should specify the gas composition in mass fraction (i.e. g of component A/g of total gas) and your program should do all necessary calculations. Demonstrate your subroutine functions correctly by computing the average molecular weight of a gas composed of: 02 16% 4% CO2 17% 6882 N2 63%

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!