Consider the mass-spring system in Fig. P. The fre-

⎡ ⎢ ⎢ ⎣ 2 − x 2 p 2 − 1 − 1 2 − x 2 p 2 − 1 − 1 2 − x 2 p 2 − 1 − 1 2 − x 2 p 2 ⎤ ⎥ ⎥ ⎦ ⎧ ⎪ ⎪ ⎨ ⎪ ⎪ ⎩ y 1 y 2 y 3 y 4 ⎫ ⎪ ⎪ ⎬ ⎪ ⎪ ⎭ = 13.10 The curvature of a slender column subject to an axial load P Fig. P13.10 can be modeled by d 2 y d x 2 + p 2 y = where p 2 = P E I where E = the modulus of elasticity, and I = the moment of inertia of the cross section about its neutral axis. This model can be converted into an eigenvalue problem by substituting a centered finite-difference approximation for the second derivative to give y i + 1 − 2y i + y i − 1 x 2 + p 2 y i = where i = a node located at a position along the rod’s inte- rior, and x = the spacing between nodes. This equation can be expressed as y i − 1 − 2 − x 2 p 2 y i + y i + 1 = Writing this equation for a series of interior nodes along the axis of the column yields a homogeneous system of equa- tions. For example, if the column is divided into five seg- ments i.e., four interior nodes, the result is An axially loaded wooden column has the following charac- teristics: E = 10 × 10 9 Pa, I = 1.25 × 10 ⫺5 m 4 , and L = 3 m. For the five-segment, four-node representation: a Implement the polynomial method with MATLAB to determine the eigenvalues for this system. b Use the MATLAB eig function to determine the eigen- values and eigenvectors. c Use the power method to determine the largest eigen- value and its corresponding eigenvector. 13.11 A system of two homogeneous linear ordinary differ- ential equations with constant coefficients can be written as d y 1 dt = − 5y 1 + 3y 2 , y 1 0 = 50 d y 2 dt = 100y 1 − 301y 2 , y 2 0 = 100 If you have taken a course in differential equations, you know that the solutions for such equations have the form y i = ce λ t where c and λ are constants to be determined. Substituting this solution and its derivative into the original equations converts the system into an eigenvalue problem. The result- ing eigenvalues and eigenvectors can then be used to derive the general solution to the differential equations. For exam- ple, for the two-equation case, the general solution can be written in terms of vectors as {y} = c 1 {v 1 }e λ 1 t + c 2 {v 2 }e λ 2 t where {v i } = the eigenvector corresponding to the i th eigen- value λ i and the c’s are unknown coefficients that can be determined with the initial conditions. a Convert the system into an eigenvalue problem. b Use MATLAB to solve for the eigenvalues and eigen- vectors. c Employ the results of b and the initial conditions to determine the general solution. d Develop a MATLAB plot of the solution for t = 0 to 1. 13.12 Water flows between the North American Great Lakes as depicted in Fig. P13.12. Based on mass balances, the following differential equations can be written for the concentrations in each of the lakes for a pollutant that decays with first-order kinetics: a b x y y x P⬘ P 0, 0 L, 0 P⬘ M P FIGURE P13.10 a A slender rod. b A freebody diagram of a rod. PROBLEMS 319 S uperior 1 Michigan 2 Huron 3 Erie 4 Ontario 5 dc 1 dt = − 0.0056 + kc 1 dc 2 dt = − 0.01 + kc 2 dc 3 dt = 0.01902c 1 + 0.01387c 2 − 0.047 + kc 3 dc 4 dt = 0.33597c 3 − 0.376 + kc 4 dc 5 dt = 0.11364c 4 − 0.133 + kc 5 where k = the first-order decay rate yr, which is equal to 0.69315half-life. Note that the constants in each of the equations account for the flow between the lakes. Due to the testing of nuclear weapons in the atmosphere, the concentra- tions of strontium-90 90 Sr in the five lakes in 1963 were approximately {c} = {17.7 30.5 43.9 136.3 30.1} T in units of Bqm 3 . Assuming that no additional 90 Sr entered the sys- tem thereafter, use MATLAB and the approach outlined in Prob. 13.11 to compute the concentrations in each of the lakes from 1963 through 2010. Note that 90 Sr has a half-life of 28.8 years. 13.13 Develop an M-file function to determine the largest eigenvalue and its associated eigenvector with the power method. Test the program by duplicating Example 13.3 and then use it to solve Prob. 13.2. FIGURE P13.12 The North American Great Lakes. The arrows indicate how water flows between the lakes. This page intentionally left blank 321 P ART F OUR Curve Fitting

4.1 OVERVIEW

What Is Curve Fitting? Data are often given for discrete values along a continuum. However, you may require esti- mates at points between the discrete values. Chapters 14 through 18 describe techniques to fit curves to such data to obtain intermediate estimates. In addition, you may require a sim- plified version of a complicated function. One way to do this is to compute values of the function at a number of discrete values along the range of interest. Then, a simpler function may be derived to fit these values. Both of these applications are known as curve fitting. There are two general approaches for curve fitting that are distinguished from each other on the basis of the amount of error associated with the data. First, where the data exhibit a significant degree of error or “scatter,” the strategy is to derive a single curve that represents the general trend of the data. Because any individual data point may be incor- rect, we make no effort to intersect every point. Rather, the curve is designed to follow the pattern of the points taken as a group. One approach of this nature is called least-squares regression Fig. PT4.1a. Second, where the data are known to be very precise, the basic approach is to fit a curve or a series of curves that pass di- rectly through each of the points. Such data usually originate from tables. Exam- ples are values for the density of water or for the heat capacity of gases as a function of temperature. The estimation of values between well-known discrete points is called interpolation Fig. PT4.1b and c. Curve Fitting and Engineering and Science. Your first exposure to curve fitting may have been to determine in- termediate values from tabulated data— for instance, from interest tables for engineering economics or from steam tables for thermodynamics. Throughout the remainder of your career, you will have fre- quent occasion to estimate intermediate values from such tables. Although many of the widely used engineering and scientific properties have been tab- ulated, there are a great many more that are not available in this convenient form. Special cases and new problem contexts often require that you measure your own data and develop your own predictive relationships. Two types of applications are generally encountered when fitting experimental data: trend analysis and hypothesis testing. Trend analysis represents the process of using the pattern of the data to make predic- tions. For cases where the data are measured with high precision, you might utilize inter- polating polynomials. Imprecise data are often analyzed with least-squares regression. Trend analysis may be used to predict or forecast values of the dependent variable. This can involve extrapolation beyond the limits of the observed data or interpolation within the range of the data. All fields of engineering and science involve problems of this type. A second application of experimental curve fitting is hypothesis testing. Here, an existing mathematical model is compared with measured data. If the model coefficients are FIGURE PT4.1 Three attempts to fit a “best” curve through five data points: a least-squares regression, b linear interpolation, and c curvilinear interpolation. f x x a b c f x x f x x