Unformatted text preview:

1 Method of Least Squares 1. Introduction Suppose an experiment yields the following series of derivative data: Y X Yexp,1 Xexp,1 Yexp,2 Xexp,2 Yexp,3 Xexp,3 Yexp,4 Xexp,4 Yexp,5 Xexp,5 Yexp,6 Xexp,6 . . Yexp,n Xexp,n And further suppose that a plot of this data looks like Graph 1 given below. Gr aph 1Expe rim e nt Dat a01020304050607080901000246810X valuesY values2 The method of least squares requires a user choice for an equation. If the choice of an equation is not obvious from the theory behind the experiment, any equation can be used to make an empirical fit as long as it can be differentiated with respect to each of its fitting coefficients. Usually the type of equation to be used is either suggested by the theory of the experiment or by the shape of the graph of the experimental data. Examples of possible fitting equations: Ycalc = a + bXexp (linear data) Ycalc = a + bXexp + cX2exp (nonlinear data) Ycalc = a + bXexp + cX2exp + dX3exp (nonlinear data) Ycalc = aebx (exponential data) The purpose of method of least squares is to use the experimental values for X and Y to find the best values for a, b, c, etc in the fitting equation such that the differences between Yexp and Ycalc are as small as possible. The difference between Yexp and Ycalc is called the residual (R). 2. The basic method Step 1 -- Plot experimental data and remove any data point that is clearly in error. Step 2 – Decide on the general form of the fitting equation. This example will use a quadratic fitting equation of the form: Ycalc = a + bXexp + cX2exp Step 3 – Define the residual for each experimental point. R1 = Ycalc,1 - Yexp,1 = a + bXexp,1 + cX2exp,1 - Yexp,1 R2 = Ycalc,2 - Yexp,2 = a + bXexp,2 + cX2exp,2 - Yexp,2 R3 = Ycalc, - Yexp,3 = a + bXexp,3 + cX2exp,3 - Yexp,3 . . . . Rn = Ycalc,n - Yexp,n = a + bXexp,n + cX2exp,n - Yexp,n3 Step 4 – Square each residual. R21 = a2 + 2abXexp,1 + 2acX2exp,1 - 2aYexp,1 + b2X2exp,1 + 2bcX3exp,1 - 2bXexp,1Yexp,1 - 2cX2exp,1Yexp,1 + c2 X4exp,1 + Y2exp,1 R22 = a2 + 2abXexp,2 + 2acX2exp,2 - 2aYexp,2 + b2X2exp,2 + 2bcX3exp,2 - 2bXexp,2 Yexp,2 - 2cX2exp,2 Yexp,2 + c2 X4exp,2 + Y2exp,2 R23 = a2 + 2abXexp,3 + 2acX2exp,3 - 2aYexp,3 + b2X2exp,3 + 2bcX3exp,3 - 2bXexp,3 Yexp,3 - 2cX2exp,3 Yexp,3 + c2 X4exp,3 + Y2exp,3 . . . . R2n = a2 + 2abXexp,n + 2acX2exp,n - 2aYexp,n + b2X2exp,n + 2bcX3exp,n - 2bXexp,n Yexp,n - 2cX2exp,n Yexp,n + c2 X4exp,n + Y2exp,n Step 5 – Find the sum of the R2. ΣR2 = R21 + R22 + R23 + ⋅ ⋅ ⋅ ⋅ ⋅ ⋅ + R2n ΣR2 = na2 + 2abΣXexp + 2acΣX2exp - 2aΣYexp + [Finish the above equation in the space below.]4 Step 6 – Differentiate the ΣR2 equation with respect to each of the fitting coefficients. Calculate the following derivatives: (∂ΣR2/∂a)b,c ; (∂ΣR2/∂b)a,c ; (∂ΣR2/∂c)a,b [Do this calculation below.] Step 7 – Set each derivative equal to zero and solve the three resulting equations for a, b and c. [Do this set-up below. Do not solve the equations. However recall what technique is used to calculate the three unknowns from the three equations.]5 3. In-class problem Suppose a set of experimental data with n data points that is assumed to be linear. Y = a + bX 1. Derive the least squares equations to find the best values for a and b. 2. Using these equations to calculate the a and b coefficients for the following data. Y X 4.51 5 10.53 10 15.28 15 22.89 25 48.78 50 answers: ΣXexp = 105, ΣYexp = 101.99, ΣX2exp = 3475, ΣXexpYexp = 3368.3 a = 0.112 b = 0.966 Author: Roger Hoburg Editing: Ed


View Full Document

UNO CHEM 3354 - Method of Least Squares

Download Method of Least Squares
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view Method of Least Squares and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view Method of Least Squares 2 2 and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?