Sei sulla pagina 1di 6

Instructions

DEWCALC.XLS
This workbook will calculate dew point temperatures and pressures using Modified Raoult's Law.

DewCalc This is the worksheet that carries out the calculations. The method uses iterative
It is currently provided to perform calculations using the one-term Margules equat
be modified for other activity relations. As provided, the spreadsheet uses the An
equation for vapor pressure.

Background This worksheet provides background on the iterative calculations.

Worksheets are protected. Values in blue may be changed without unlocking the spreadsheet, which
permit most common calculations. To unprotect, use Tools...Protection...Unprotect. Enter "thermo" fo
password.

Copyright 1997, Carl Lira


For use with "An Introduction to Applied Thermodynamics" by J.R. Elliott, C.T. Lira
www.egr.msu.edu/~lira/thermtxt.htm

Page 1
Instructions

odified Raoult's Law.

e method uses iterative calculations.


one-term Margules equations, but
preadsheet uses the Antoine

g the spreadsheet, which will


rotect. Enter "thermo" for the

Page 2
444033946.xls

Dew Point Calculator protected without password


Modified Raoult's Law, One term Margules
GE/RT = A *x1*x2
System Acetone(1)-Methanol(2), B = 0.64

T(C)= 55.1 P= 629 (mm Hg)


A
Margules Parameter 0.64 For Dew Temperature
Calculation, adjust T until
component 1 2 xT = 1.
y 0.3 0.7 For Dew Pressure
Antoine A 7.11714 8.08097 calculations, adjust P until
Antoine B 1210.595 1582.271 xT = 1.
Antoine C 229.664 239.726
Psat(mm Hg) 734.3751 517.8142
x' Err:522 Err:522
xn Err:522 Err:522
 Err:522 Err:522

xT Err:522
This spreadsheet uses circular references.
If you receive an error "Cannot resolve circular references", then Excel is not expecting
circular references. To permit circular references, choose Tools..Options... Calculation... and click
on the box for Iterations. Click on the "Background" tab to learn more about circular references.
Occasionly, circular references don't work. In that event a macro can be written to perform succesive su
See the appendix of the text for instructions on writing macros.

Page 3
444033946.xls

adjust T until

s, adjust P until

is not expecting
ns... Calculation... and click
about circular references.
be written to perform succesive substitution.

Page 4
Background

The iterations in this spreadsheet involve the rows for x', x(n), gamma.
1. each x' is calculated from the appropriate y * P / ( * Psat).
2. xn is the normalized composition calculated using the x' values.
3. 

The worksheet "DewCalc" uses circular references to set up iterative calculations. For a dew calculation,
the value of  depends on x, which is not known until the answer is obtained. Therefore, the initial guess
from the last converged answer. This value is used to calculate a new value for x, which in turn changes
value of , which is used to calculate a new value for x. Programming the cells sets up a circular referenc
the values in the cells for  and x reference each other. Iteration procedes until the values change by les
value of the "Maximum Change" variable or the number of iterations set in the "Maximum Iterations" va

Iteration is controlled by choosing Tools... Options...Calculations...


This spreadsheet was converged using Maximum Iterations = 100, Maximum Change = 0.0001.

Note that in a spreadsheet using circular references, a large change in parameter/variable values
from one problem to the next can create a poor first guess which causes the calculations
to diverge. If you have problems with this, load your saved version, and change the
values gradually over wide ranges.

To set up your own iterative spreadsheet:


Before entering a circular reference, choose Tools... Options... Calculation .... and click on Manual
to set the calculations to manual. (F9 will start the calculation in Manual mode.)
You must enter formulas in the order the iteration should procede. In this example,

finally C15, where the order is important. Reasonable values for all cells should be used because
the initial guess is established as you type in the formulas. When all the formulas are entered,
the calculations may be turned back to Automatic.
Save the spreadsheet after it is set up. A poor guess can cause an interative calculation to
diverge, giving a error, and the best way to recover is to reload the saved spreadsheet.

Page 5
Background



s. For a dew calculation,


erefore, the initial guess is taken
x, which in turn changes the
ets up a circular reference which
he values change by less than the
Maximum Iterations" variable.

ange = 0.0001.

er/variable values

d click on Manual


be used because
s are entered,

culation to

Page 6

Potrebbero piacerti anche