+ All Categories
Home > Documents > Lecture 14 - Curve Fitting (Intro&Regression)

Lecture 14 - Curve Fitting (Intro&Regression)

Date post: 03-Apr-2018
Category:
Upload: terminatorx75
View: 236 times
Download: 2 times
Share this document with a friend

of 17

Transcript
  • 7/29/2019 Lecture 14 - Curve Fitting (Intro&Regression)

    1/17

    PE 3723

    Numerical MethodsLecture 14: Curve Fitting

    (Introduction & Regression)Maysam Pournik

    Assistant Professor

    Spring 20121

  • 7/29/2019 Lecture 14 - Curve Fitting (Intro&Regression)

    2/17

    Curve Fitting Applications

    2

    Data given for discrete values along acontinuum

    Objective: Need to estimate values betweendiscrete values

    1. Techniques to fit curves to the data toobtain intermediate values

    2. Need simplified version of a complicatedfunction

    Compute values at discrete points & derive asimpler function to fit these values

  • 7/29/2019 Lecture 14 - Curve Fitting (Intro&Regression)

    3/17

    Approaches to Curve Fitting

    3

    Two general approaches for curve fitting:

    1. Data with error: Least-Squares Regression

    Single curve that represents

    general trend designed to followpattern, not intersect every point

    Applied to data exhibiting

    significant error

    2. Data with no error: Interpolation

    Fit a curve that pass directly through

    each of the points

    Applied to very precise data

  • 7/29/2019 Lecture 14 - Curve Fitting (Intro&Regression)

    4/17

    Simple Method - Noncomputer

    4

    Plot and fit a line that virtually conforms to data Valid for quick estimate

    Subjective viewpoint

    Need for systematic and objective methods

    Two types of application in fitting experimental data:A. Trend analysis: Process of using the data pattern for predictions.

    B. Hypothesis testing: An existing mathematical model is

    compared with experimental data.

  • 7/29/2019 Lecture 14 - Curve Fitting (Intro&Regression)

    5/17

    Mathematical Background

    5

    Use statistics to convey as much information aspossible about specific characteristics of data set

    Location of the center of distribution Arithmetic mean: sum of individual points divided by

    total number of data points

  • 7/29/2019 Lecture 14 - Curve Fitting (Intro&Regression)

    6/17

    Mathematical Background

    6

    Degree of spread of data set

    Standard deviation: square root of total sum of residuals

    between data points and mean value divided by total

    number of data points minus 1

    Variance: square of standard deviation

    Coefficient of variation: ratio of standard deviation tothe mean

    Provides a normalized measure of spread

    Similar to relative error as is ratio of a measure of error to an

    estimate of true value

  • 7/29/2019 Lecture 14 - Curve Fitting (Intro&Regression)

    7/17

    Mathematical Background

    7

    Shape of data distribution

    Histogram:

    visual representation of

    distribution

    Constructed by sorting

    measurements into intervals

    Plotted as units of measurement

    versus frequency of occurrence Can be represented by a single

    smooth curve

    One type is Normal distribution

    symmetric, bell-shaped curve

  • 7/29/2019 Lecture 14 - Curve Fitting (Intro&Regression)

    8/17

    Mathematical Background

    8

    Quantify confidence on a measurement

    For normal distribution:

    to + : contains 68% of total data

    to + : contains 95% of total data

    Need to estimate properties of a population based on

    limited sample of the populationStatistical

    Inference

    Define a confidence interval around our estimate

    & : sample information (estimated)

    & : population information (true)

  • 7/29/2019 Lecture 14 - Curve Fitting (Intro&Regression)

    9/17

    Mathematical Background

    9

    Interval estimator: gives range of values within

    which the parameter is expected to lie with a given

    probability

    One-sided intervalless than or greater than true

    Two-sided intervalno consideration to sign of

    discrepancy

  • 7/29/2019 Lecture 14 - Curve Fitting (Intro&Regression)

    10/17

    Mathematical Background

    10

    Probability that true mean of y, , falls within the

    bound from L to U is 1- ( is significance level)

    Standard normal estimate

    Normalized distance between and

    Normally distributed with mean of 0 and variance of 1

    Probability that it lies withinz/2 and z/2 is 1-

    Tabulated in books and software

  • 7/29/2019 Lecture 14 - Curve Fitting (Intro&Regression)

    11/17

    Mathematical Background

    11

    Estimation of L and U

    As true variance is not known, define based on

    estimated variance using new variable

    Based on t-distribution (not normal) & tabulated

    Represents interval around mean of width t/2,n-1

    times the standard deviation encompassing 95% of

    distribution

  • 7/29/2019 Lecture 14 - Curve Fitting (Intro&Regression)

    12/17

    Linear Regression

    12

    Systematic method to derive a curve that

    minimize discrepancy between data and curve

    Fit a straight line to data points

    y = a0 + a1x + e

    a0 = intercept

    a1 = slope

    e = error or residual betweenmodel and data

  • 7/29/2019 Lecture 14 - Curve Fitting (Intro&Regression)

    13/17

    Linear Regression Best Fit

    13

    Selection of best fit based on:

    Minimax method: Minimize the maximum distance that

    an individual point falls from the line.

  • 7/29/2019 Lecture 14 - Curve Fitting (Intro&Regression)

    14/17

    Linear Regression Least Square

    14

    Sum of the squares of residuals

    Yields unique solution

  • 7/29/2019 Lecture 14 - Curve Fitting (Intro&Regression)

    15/17

    Linear Regression Least Square

    15

    Standard deviation of regression line

    Standard error of estimate

    If sy/x < sy, then linear regression is valid and has merit

  • 7/29/2019 Lecture 14 - Curve Fitting (Intro&Regression)

    16/17

    Linear Regression Least Square

    16

    Goodness of the fit quantify improvement indescribing data by a straight line rather than an

    average value

    Coefficient of determination, r2 (r is correlation

    coefficient)

    r = 1 : perfect fit and explains data variability

    r = 0 : fit represents no improvement

  • 7/29/2019 Lecture 14 - Curve Fitting (Intro&Regression)

    17/17

    Example: Linear Regression

    17

    Perform linear regression for this data set


Recommended