Вы находитесь на странице: 1из 2

Letting Mathcad Handle Unit Conversions

For historical reasons, we are often faced with performing calculations involving quantities from both the SI system and the English engineering units. Conversion of units is a major headache and also the major source of errors in most student's work. This Mathcad module shows how to perform these unit conversions automatically with little extra effort by the student. To illustrate, we will take a few calculations from our first Hwk assignment. In particular, we will look at the solution to Prob. 4.3-8 in Geankoplis. The heat transfer coefficient hi is given as 500 btu/h.ft2. oF hi 500 If we define hi to be 500, Mathcad take the number to be diminsionless

To get Mathcad to make the unit conversions, we must assign the units to all constants instead of leaving them dimensionless. This can be done by multiplying (or dividing) the constant "500" by built-in constants representing the units. This is done in the example below: after typing "500", I typed the "multiply" symbol (*) and then typed "BTU". You must use the exact name Mathcad uses for each unit (including upper or lower case). If you don't remember the name of the unit, click on the "measuring cup" in the toolbar (if the 'toolbar' is not visible, go to the View menu and click on 'toolbar'). A dialog box will appear which allows you to select the proper unit. After entering "BTU", I typed "/hr*ft^2 *R" (the blank denotes a space made by hitting the space bar). Again, if I didn't know Mathcad's name for a unit, I can insert it at the current cursor location using the measuring cup tool.

hi

BTU 500 . 2 hr .ft .R

Once you have defined a variable like "hi", you can either use it in any calculations or display its value in any desired set of units. 3 3 1 hi = 2.839 10 kg sec K If you just type "=" after the constant, Mathcad displays the value in its default set of units (usually MKS unless you have declared a different default). Notice that the value displayed at left (as well as the units) are different from what we entered in the statement above.

If you click on the equation above, you will notice a placeholder appears at the end of the list of units. This placeholder is denoted by a solid square (about 1mm x 1mm in size). Moving the cursor to select this placeholder, you can enter any desired units in which the value of constant are to be displayed. kW
2 m .K

hi = 2.839

For example, if we enter "kW/m^2 *K" in this placeholder, we obtain the result at left. Notice that the value of hi has changed to reflect the different units used. Mathcad has automatically applied the conversion 1 kW = 1000 joules/sec = 1000 kg*m/sec^3. If we incorrectly enter the units as "BTU/ft^2 *R" (we have omitted the hr), Mathcad uses them, but appends the default unit of time "s^-1" to indicate that additional units are required. Of course, we do not recover our original

hi = 0.139 sec

1 BTU ft R
2

ft R value. hi = 500 BTU


2 hr .ft .R

If instead, we enter "BTU/hr*ft^2 *R" (including the "hr") in the units placeholder, we do recover the original value and units.

Now we will enter the rest of the variables appearing in this problem in the most convenient units (for us). 1500 . BTU
2 hr . ft . R

ho

45.1 .

W m .K

Di

2.067 .in

Do

2.375 .in

xW

Do 2 Do ln

Di

xW = 0.154 in

Here we calculate the wall thickness. I specified "in" as the unit to display the answer in. Here we calculate the log-mean diameter. Again I specified "in" as the unit to display the result.

Dlm

Di Do Di

Dlm = 2.217 in

Uo 1 ho

1 xW . Do k Dlm 1 . Do hi Di

Here we are calculating the overall coefficient using the formula at the top of page 9 of the class notes. Notice that we have mixed different sets of units when specifying values for the variables appearing in this equation. The units are correctly converted automatically.

Uo =

This is the display of the result using Mathcad's default units

Uo =

BTU
2 hr .ft .R

What remains is the display of the answer in two different sets of units. The last value should match with the answer in the solution key.

Uo =

W
2 m .K

Вам также может понравиться