# Introduction to Chemical Engineering Processes/Different Ways to Plot Data

## Linearization

In the statistics section, the concept of linearization was introduced as an extension to linear regression. It is discussed here in terms of plotting. Linearization is particularly useful because it allows an engineer to easily tell whether a simple model (such as an exponential model) is a good fit to data, and to locate outliers.

In order to linearize nonlinear data, it is necessary to assume a model that can be linearized. Some requirements for a linearizable function are:

1. The equation must be separable (i.e. you must be able to put all instances of y or functions of y on one side of the equation, and all instances of x or functions of x on the other)
2. You must be able to express the function in the form ${\displaystyle f(y)=A*f(x)+B}$
3. Simple linearization can only provide a maximum of two constant values (A and B).

Some examples of functions that can be linearized and their linear forms are given in the statistics section. Here is a summary:

${\displaystyle y=A*b^{x}\rightarrow ln(y)=ln(A)+x*ln(b)}$ (exponential model, ${\displaystyle f(y)=ln(y);f(x)=x}$)
${\displaystyle y=A*x^{b}\rightarrow ln(y)=ln(A)+b*ln(x)}$ (power-law model, ${\displaystyle f(y)=ln(y);f(x)=ln(x)}$)
${\displaystyle y={\frac {k_{1}*x}{k_{2}+x}}\rightarrow {\frac {1}{y}}=({\frac {k_{2}}{k_{1}}})*{\frac {1}{x}}+{\frac {1}{k_{1}}}}$ (Michaelis-Menton)
 To do: Show some more examples of linearizable functions

An effective method to check the validity of an assumed model is to first evaluate f(y) and f(x) at all data points and then plot f(y) vs. f(x). Spreadsheets are ideal for this computation. If the model assumed is correct, the plot of f(y) vs. f(x) should be linear and randomly scattered around the plot. If the assumed model is known to be correct, the linear plot can be used to quickly identify outlying data points.

 To do: Show a diagram of this

## Log-log and semi-log plots

In engineering, exponential and power-law models show up so often that they have their own special paper that can be used to graph them easily. They are called semilog paper and log-log paper, respectively, because of the linearized forms of the exponential and power-law functions. These types of paper use a base-10 logarithm (which differs from a natural logarithm by a constant) because it is easier to visualize a base-10 than it is to visualize a base-e.

 To do: Explain more about the log-log and x-log plots, show some diagrams

## Parity Plots

Often, in engineering analysis, there will be a theoretical value of a parameter (for example, the outlet temperature of a reactor calculated from an energy balance), and there will be an actually-measured value. It is often desirable to compare them. One easy graphical way to do this is with a parity plot. In a parity plot, one plots the measured values against the experimental values (for the same trial). The y=x line is also plotted as a reference. If the theoretical and experimental values agree, they should lie close to the y=x line and be randomly scattered around it. If they do not (due to either a problematic assumption in the theory, errors in measurement, or both), then the data will be skewed away from the y=x line. This is also useful for identifying outlying measurements.

In addition to checking for actual agreement, a parity plot can be used to tell if the theoretical and experimental values are at least correlated (in which case the plot would be linear, even if not near the y=x line).
{"extraction_info": {"found_math": true, "script_math_tex": 0, "script_math_asciimath": 0, "math_annotations": 6, "math_alttext": 0, "mathml": 0, "mathjax_tag": 0, "mathjax_inline_tex": 0, "mathjax_display_tex": 0, "mathjax_asciimath": 0, "img_math": 0, "codecogs_latex": 0, "wp_latex": 0, "mimetex.cgi": 0, "/images/math/codecogs": 0, "mathtex.cgi": 0, "katex": 0, "math-container": 0, "wp-katex-eq": 0, "align": 0, "equation": 0, "x-ck12": 0, "texerror": 0, "math_score": 0.7779074311256409, "perplexity": 544.8308171378796}, "config": {"markdown_headings": true, "markdown_code": true, "boilerplate_config": {"ratio_threshold": 0.18, "absolute_threshold": 10, "end_threshold": 15, "enable": true}, "remove_buttons": true, "remove_image_figures": true, "remove_link_clusters": true, "table_config": {"min_rows": 2, "min_cols": 3, "format": "plain"}, "remove_chinese": true, "remove_edit_buttons": true, "extract_latex": true}, "warc_path": "s3://commoncrawl/crawl-data/CC-MAIN-2018-05/segments/1516084886794.24/warc/CC-MAIN-20180117023532-20180117043532-00504.warc.gz"}