Part 5 - Chapter 17 1 1.

Slides:



Advertisements
Similar presentations
Managerial Economics in a Global Economy
Advertisements

Lesson 10: Linear Regression and Correlation
Chapter 12 Simple Linear Regression
Statistical Techniques I EXST7005 Simple Linear Regression.
Copyright © 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 1 ~ Curve Fitting ~ Least Squares Regression Chapter.
13- 1 Chapter Thirteen McGraw-Hill/Irwin © 2005 The McGraw-Hill Companies, Inc., All Rights Reserved.
CmpE 104 SOFTWARE STATISTICAL TOOLS & METHODS MEASURING & ESTIMATING SOFTWARE SIZE AND RESOURCE & SCHEDULE ESTIMATING.
Chapter 10 Curve Fitting and Regression Analysis
Read Chapter 17 of the textbook
Chapter 10 Simple Regression.
Least Square Regression
Curve-Fitting Regression
Least Square Regression
The Islamic University of Gaza Faculty of Engineering Civil Engineering Department Numerical Analysis ECIV 3306 Chapter 17 Least Square Regression.
Linear Regression and Correlation
SIMPLE LINEAR REGRESSION
Probability & Statistics for Engineers & Scientists, by Walpole, Myers, Myers & Ye ~ Chapter 11 Notes Class notes for ISE 201 San Jose State University.
Copyright © 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display. by Lale Yurttas, Texas A&M University Chapter 171 CURVE.
Copyright © 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display. by Lale Yurttas, Texas A&M University Chapter 171 Least.
Correlation and Regression Analysis
Simple Linear Regression Analysis
Least-Squares Regression
Copyright © 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 1 ~ Curve Fitting ~ Least Squares Regression Chapter.
Introduction to Linear Regression and Correlation Analysis
Linear Regression and Correlation
Simple Linear Regression Models
Chapter 6 & 7 Linear Regression & Correlation
Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 1 Part 4 Curve Fitting.
Managerial Economics Demand Estimation. Scatter Diagram Regression Analysis.
CISE301_Topic41 CISE301: Numerical Methods Topic 4: Least Squares Curve Fitting Lectures 18-19: KFUPM Read Chapter 17 of the textbook.
MECN 3500 Inter - Bayamon Lecture 9 Numerical Methods for Engineering MECN 3500 Professor: Dr. Omar E. Meza Castillo
Applied Quantitative Analysis and Practices LECTURE#23 By Dr. Osman Sadiq Paracha.
Statistical Methods Statistical Methods Descriptive Inferential
Chapter 8 Curve Fitting.
Curve-Fitting Regression
Inference for Regression Simple Linear Regression IPS Chapter 10.1 © 2009 W.H. Freeman and Company.
Curve Fitting Pertemuan 10 Matakuliah: S0262-Analisis Numerik Tahun: 2010.
Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 1 Part 4 Chapter 15 General Least Squares and Non- Linear.
Copyright © 2011 by The McGraw-Hill Companies, Inc. All rights reserved. McGraw-Hill/Irwin Simple Linear Regression Analysis Chapter 13.
Curve Fitting Introduction Least-Squares Regression Linear Regression Polynomial Regression Multiple Linear Regression Today’s class Numerical Methods.
Copyright © 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 1 ~ Curve Fitting ~ Least Squares Regression.
OLS Regression What is it? Closely allied with correlation – interested in the strength of the linear relationship between two variables One variable is.
Chapter 14 Introduction to Regression Analysis. Objectives Regression Analysis Uses of Regression Analysis Method of Least Squares Difference between.
1 1 Slide © 2008 Thomson South-Western. All Rights Reserved Slides by JOHN LOUCKS St. Edward’s University.
The simple linear regression model and parameter estimation
Chapter 4: Basic Estimation Techniques
Chapter 4 Basic Estimation Techniques
Regression Analysis AGEC 784.
Part 5 - Chapter 17.
Basic Estimation Techniques
Correlation and Simple Linear Regression
Basic Estimation Techniques
CHAPTER 29: Multiple Regression*
Chapter 12 Curve Fitting : Fitting a Straight Line Gab-Byung Chae
Part 5 - Chapter 17.
Simple Linear Regression
Linear regression Fitting a straight line to observations.
Correlation and Simple Linear Regression
Simple Linear Regression
Discrete Least Squares Approximation
Simple Linear Regression and Correlation
Least Square Regression
Correlation and Regression
Product moment correlation
Simple Linear Regression
SKTN 2393 Numerical Methods for Nuclear Engineers
Algebra Review The equation of a straight line y = mx + b
Chapter Thirteen McGraw-Hill/Irwin
Correlation and Simple Linear Regression
Correlation and Simple Linear Regression
Presentation transcript:

Part 5 - Chapter 17 1 1

CURVE FITTING Describes techniques to fit curves (curve fitting) to discrete data to obtain intermediate estimates. There are two general approaches two curve fitting: Data exhibit a significant degree of scatter. The strategy is to derive a single curve that represents the general trend of the data. (Regression) Data is very precise. The strategy is to pass a curve or a series of curves through each of the points. (Interpolation) In engineering two types of applications are encountered: Trend analysis. Predicting values of dependent variable, may include extrapolation beyond data points or interpolation between data points. Hypothesis testing. Comparing existing mathematical model with measured data. 2

Figure PT5.1 3

Mathematical Background Simple Statistics/ In course of engineering study, if several measurements are made of a particular quantity, additional insight can be gained by summarizing the data in one or more well chosen statistics that convey as much information as possible about specific characteristics of the data set. These descriptive statistics are most often selected to represent The location of the center of the distribution of the data, The degree of spread of the data. 4

Standard deviation. The most common measure of a spread for a sample. Arithmetic mean. The sum of the individual data points (yi) divided by the number of points (n). Standard deviation. The most common measure of a spread for a sample. or 𝑦 = 𝑦 𝑖 𝑛 𝑖=1,…,𝑛 𝑆 𝑦 = 𝑆 𝑡 𝑛−1 𝑆 𝑡 = 𝑦 𝑖 − 𝑦 ) 2 𝑆 𝑦 2 = 𝑦 𝑖 2 − 𝑦 𝑖 2 𝑛 𝑛−1 5

Variance. Representation of spread by the square of the standard deviation. Coefficient of variation. Has the utility to quantify the spread of data. 𝑆 𝑦 2 = 𝑦 𝑖 − 𝑦 ) 2 𝑛−1 Degrees of freedom 𝑐.𝑣.= 𝑆 𝑦 𝑦 100 6

Figure PT5.2 7

Figure PT5.3 8

Least Squares Regression Linear Regression Fitting a straight line to a set of paired observations: (x1, y1), (x2, y2),…,(xn, yn). y=a0+a1x+e a1- slope a0- intercept e- error, or residual, between the model and the observations 9

Criteria for a “Best” Fit/ Minimize the sum of the residual errors for all available data: n = total number of points However, this is an inadequate criterion, so is the sum of the absolute values 𝑖=1 𝑛 𝑒 𝑖 = 𝑖=1 𝑛 𝑦 𝑖 − 𝑎 𝑜 − 𝑎 1 𝑥 𝑖 𝑖=1 𝑛 ∣ 𝑒 𝑖 ∣ = 𝑖=1 𝑛 ∣ 𝑦 𝑖 − 𝑎 0 − 𝑎 1 𝑥 𝑖 ∣ 10

Figure 17.2 11

Yields a unique line for a given set of data. Best strategy is to minimize the sum of the squares of the residuals between the measured y and the y calculated with the linear model: Yields a unique line for a given set of data. 𝑆 𝑟 = 𝑖=1 𝑛 𝑒 𝑖 2 = 𝑖=1 𝑛 𝑦 𝑖 ,measured− 𝑦 𝑖 ,model ) 2 = 𝑖=1 𝑛 𝑦 𝑖 − 𝑎 0 − 𝑎 1 𝑥 𝑖 ) 2 12

Least-Squares Fit of a Straight Line/ ∂ 𝑆 𝑟 ∂ 𝑎 𝑜 =−2 𝑦 𝑖 − 𝑎 𝑜 − 𝑎 1 𝑥 𝑖 =0 ∂ 𝑆 𝑟 ∂ 𝑎 1 =−2 𝑦 𝑖 − 𝑎 𝑜 − 𝑎 1 𝑥 𝑖 ) 𝑥 𝑖 =0 0= 𝑦 𝑖 − 𝑎 0 − 𝑎 1 𝑥 𝑖 0= 𝑦 𝑖 𝑥 𝑖 − 𝑎 0 𝑥 𝑖 − 𝑎 1 𝑥 𝑖 2 Normal equations, can be solved simultaneously 𝑎 0 = 𝑛𝑎 0 𝑛𝑎 0 + 𝑥 𝑖 𝑎 1 = 𝑦 𝑖 𝑎 1 = 𝑛 𝑥 𝑖 𝑦 𝑖 − 𝑥 𝑖 𝑦 𝑖 𝑛 𝑥 𝑖 2 − 𝑥 𝑖 2 𝑎 0 = 𝑦 − 𝑎 1 𝑥 Mean values 13

Figure 17.3 14

Figure 17.4 15

Figure 17.5 16

Sum of the squares of residuals around the regression line is Sr “Goodness” of our fit/ If Total sum of the squares around the mean for the dependent variable, y, is St Sum of the squares of residuals around the regression line is Sr St-Sr quantifies the improvement or error reduction due to describing data in terms of a straight line rather than as an average value. 𝑟 2 = 𝑆 𝑡 − 𝑆 𝑟 𝑆 𝑡 r2-coefficient of determination Sqrt(r2) – correlation coefficient 17

For r=r2=0, Sr=St, the fit represents no improvement. For a perfect fit Sr=0 and r=r2=1, signifying that the line explains 100 percent of the variability of the data. For r=r2=0, Sr=St, the fit represents no improvement. 18

Polynomial Regression Some engineering data is poorly represented by a straight line. For these cases a curve is better suited to fit the data. The least squares method can readily be extended to fit the data to higher order polynomials (Sec. 17.2). 19

General Linear Least Squares 𝑦= 𝑎 0 𝑧 0 + 𝑎 1 𝑧 1 + 𝑎 2 𝑧 2 +⋯+ 𝑎 𝑚 𝑧 𝑚 +𝑒 𝑧 0 , 𝑧 1 ,… , 𝑧 𝑚 are𝑚+1basis functions 𝑌 = 𝑍 𝐴 + 𝐸 𝑍 −matrix of the calculated values of the basis functions at the measured values of the independent variable 𝑌 −observed valued of the dependent variable 𝐴 −unknown coefficients 𝐸 −residuals 𝑆 𝑟 = 𝑖=1 𝑛 𝑦 𝑖 − 𝑗=0 𝑚 𝑎 𝑗 𝑧 𝑗𝑖 2 Minimized by taking its partial derivative w.r.t. each of the coefficients and setting the resulting equation equal to zero 20