Download (right-click, save target as ...) this page as a jupyterlab notebook from: Lab13


Laboratory 13: Data Models and Graphing

LAST NAME, FIRST NAME

R00000000

ENGR 1330 Laboratory 13 - In-Lab

Example 1

Consider the data below

Methanol Mole Fraction (Liquid Phase) Methanol Mole Fraction (Vapor Phase)
1.0 1.0
0.882 0.929
0.765 0.849
0.653 0.764
0.545 0.673
0.443 0.575
0.344 0.471
0.25 0.359
0.159 0.241
0.072 0.114
0.0 0.0

Estimate the vapor mole fraction of methanol corresponding to the liquid mole fraction of methanol of x = 0.15.

Let's try a few different functional forms as a data model; first linear, then quadratic, and then a power-law model.

As a first step, lets import some minimal needed packages, and build a plotting function.

Next lets define some data models; linear, quadratic, and power-law

Now lets make some model fits (trial-and-error); First the needed data

Now choose which data model to use and make the estimate

Exercise 1

A meaningful modification is to make the estimate using all the models (you will have to use care in parameter names, but its an easy mod!). It is left as an exercise.

Example 2

Same data as above, only this time use interpolating polynomials (as in the lesson).

Methanol Mole Fraction (Liquid Phase) Methanol Mole Fraction (Vapor Phase)
1.0 1.0
0.882 0.929
0.765 0.849
0.653 0.764
0.545 0.673
0.443 0.575
0.344 0.471
0.25 0.359
0.159 0.241
0.072 0.114
0.0 0.0

Estimate (interpolate) the vapor mole fraction of methanol corresponding to the liquid mole fraction of methanol of x = 0.15.