0% found this document useful (0 votes)
116 views21 pages

Math Module 5

m5

Uploaded by

Mrudula P
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
116 views21 pages

Math Module 5

m5

Uploaded by

Mrudula P
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Complex Analysis, Probability and Statistical Methods

(Subject code: 21MAT41)

Module 3: Statistical methods and curve fitting

__________________________________________________________________

Syllabus:
Statistical methods: Correlation and regression – Karl Pearson’s coefficient of correlation and
rank correlation – problems, Regression analysis – lines of regression – problems.
Curve fitting: Curve fitting by the method of least squares – fitting the curves of the form –
𝑦 = 𝑎𝑥 + 𝑏, 𝑦 = 𝑎𝑥 𝑏 and 𝑦 = 𝑎𝑥 2 + 𝑏𝑥 + 𝑐 .

3.1 Correlation analysis


Introduction:

 Two variables are said to be correlated if the changes in the values of one variable are
associated with the changes in the values of the other variable.
 Two variables are said to be positively correlated if an increase (decrease) in the values
of one variable corresponds to an increase (decrease) in the other variable.
 Two variables are said to be negatively correlated if an increase (decrease) in the values
of one variable corresponds to a decrease (increase) in the other variable.
 Two variables are said to be independent or uncorrelated if there is no relationship
indicated between the variables.
 Measure of correlation is called as the coefficient of correlation which is denoted by
𝜌 𝑜𝑟 𝑟. − 1 ≤ 𝜌 ≤ 1.
 Karl Pearson’s Coefficient of correlation is given by
nΣxy−ΣxΣy
𝜌= .
√[nΣ𝑥 2 −(Σx)2 ][nΣ𝑦 2 −(Σ𝑦)2 ]

Dr. Narasimhan G, RNSIT 1


1. Find the correlation coefficient for the following data:
x 1 2 3 4 5
y 2 5 3 8 7

Karl Pearson’s Coefficient of correlation is given by


𝑛𝛴𝑥𝑦−𝛴𝑥𝛴𝑦
𝑟=
√[𝑛𝛴𝑥 2 −(𝛴𝑥)2 ][𝑛𝛴𝑦 2 −(𝛴𝑦)2 ]
𝑥 𝑦 𝑥𝑦 𝑥 2 𝑦 2
5(88) − (15)(25) 1 2 2 1 4
= 2 5 10 4 25
√(5(55) − 225)(5(151) − 625) 3 3 9 9 9
= 0.8062 4 8 32 16 64
5 7 35 25 49
15 25 88 55 151
Σ𝑥 Σ𝑦 Σ𝑥𝑦 Σ𝑥 2 Σ𝑦 2

2. Obtain the correlation coefficient for the following data:

x 10 14 18 22 26 30
y 18 12 24 6 30 36

Karl Pearson’s Coefficient of correlation is given by


nΣxy−ΣxΣy
𝑟= 𝑥 𝑦 𝑥𝑦 𝑥2 𝑦2
√[nΣ𝑥 2 −(Σx)2 ][nΣ𝑦 2 −(Σ𝑦)2 ]
10 18 180 100 324
6(2772) − (120)(126) 14 12 168 196 144
=
√(6(2680) − 1202 )(6(3276) − 1262 ) 18 24 432 324 576
22 6 132 484 36
1512 26 30 780 676 900
= = 0.6
√1680×3780 30 36 1080 900 1296
120 126 2772 2680 3276
Σ𝑥 Σ𝑦 Σ𝑥𝑦 Σ𝑥 2 Σ𝑦 2

Dr. Narasimhan G, RNSIT 2


3. Find the co-efficient of correlation between industrial production and export using
the following data and comment on the result.
Production (In Crores) 55 56 58 59 60 60 62
Exports (In Crores) 35 38 38 39 44 43 45

Karl Pearson’s Coefficient of correlation is given by


nΣxy−ΣxΣy
𝑟=
√[nΣ𝑥 2 −(Σx)2 ][nΣ𝑦 2 −(Σ𝑦)2 ] 𝑥 𝑦 𝑥𝑦 𝑥2 𝑦2
7(16568) − (410)(282) 55 35 1925 3025 1225
= 56 38 2128 3136 1444
√(7(24050) − 4102 )(7(11444) − 2822 )
58 38 2204 3364 1444
= 0.9317 59 39 2301 3481 1521
60 44 2640 3600 1936
60 43 2580 3600 1849
62 45 2790 3844 2025
410 282 16568 24050 11444
Σ𝑥 Σ𝑦 Σ𝑥𝑦 Σ𝑥 2 Σ𝑦 2

𝝈𝟐𝒙 +𝝈𝟐𝒚 −𝝈𝟐𝒙−𝒚


4. Using the formula 𝒓 = find 𝒓 from the following data:
𝟐𝝈𝒙 𝝈𝒚

x 92 89 87 86 83 77 71 63 53 50
y 86 88 91 77 68 85 52 82 37 57

Σ𝑥 = 751, Σ𝑦 = 723, 𝑥 𝑦 𝑥−𝑦 𝑥2 𝑦2 (𝑥 − 𝑦)2


Σ𝑥 2 = 58487, Σ𝑦 2 = 55245, 92 86 6 8464 7396 36
Σ(𝑥 − 𝑦) = 28, 89 88 1 7921` 7744 1
87 91 -4 7569 8281 16
Σ(𝑥 − 𝑦)2 = 1450.
86 77 9 7396 5929 81
Σ𝑥 2 Σ𝑥 2
𝜎𝑥2 = −(𝑛) 83 68 15 6889 4624 225
𝑛
58487 751 2
77 85 -8 5929 7225 64
= − ( 10 ) = 208.69 71 52 19 5041 2704 361
10
Σ𝑦 2 Σ𝑦 2 63 82 -19 3969 6724 361
𝜎𝑦2 = −(𝑛) 53 37 16 2809 1369 256
𝑛
11387 723 2 50 57 -7 2500 3249 49
= − ( 10 ) = 297.2
10 751 723 28 58487 55245 1450
Σ(𝑥−𝑦)2 Σ(𝑥−𝑦) 2 2 2
2
𝜎(𝑥−𝑦) = −( ) Σ𝑥 Σ𝑦 Σ(𝑥 − 𝑦) Σ𝑥 Σ𝑦 Σ(𝑥 − 𝑦)2
𝑛 𝑛
1450 28 2
= − (10) = 137.16
10
𝜎𝑥2 +𝜎𝑦2 −𝜎𝑥−𝑦
2
𝑟= 2𝜎𝑥 𝜎𝑦
208.69+297.2−137.16
= 2(249.04)
= 0.7403

Dr. Narasimhan G, RNSIT 3


5. Find the co-efficient of correlation for the data given below:
𝒏 = 𝟏𝟖, 𝚺𝒙 = 𝟏𝟐, 𝚺𝒚 = 𝟏𝟖, 𝚺𝒙𝟐 = 𝟔𝟎, 𝚺𝒚𝟐 = 𝟗𝟔, 𝚺𝒙𝒚 = 𝟒𝟖.

Karl Pearson’s Coefficient of correlation is given by


nΣxy−ΣxΣy
𝑟=
√[nΣ𝑥 2 −(Σx)2 ][nΣ𝑦 2 −(Σ𝑦)2 ]
18(48)−(12)(18)
=
√(18(60)−122 )(18(96)−182 )
= 0.5653

6. While calculating co-efficient of correlation between two variables x and y from 25


pairs of observations, the following results were obtained:
𝒏 = 𝟐𝟓, 𝚺𝒙 = 𝟏𝟐𝟓, 𝚺𝒙𝟐 = 𝟔𝟓𝟎, 𝚺𝒚 = 𝟏𝟎𝟎, 𝚺𝒚𝟐 = 𝟒𝟔𝟎, 𝚺𝒙𝒚 = 𝟓𝟎𝟖.
Later it was discovered at the time of checking that the pair x y values
8 12
6 8
were copied down as Obtain the x y correct value of correlation co-
6 14
efficient.
8 6

Wrong values are (6, 14), (8, 6) and correct values are (8, 12), (6, 8).
New Total = Total −wrong values+Correct values
Corrected values are
Σ𝑥 = 125 − 6 − 8 + 8 + 6 = 125 − 14 + 14 = 125
Σ𝑦 = 100 − 14 − 6 + 12 + 8 = 100
Σ𝑥 2 = 650 − 62 − 82 + 82 + 62 = 650
Σ𝑦 2 = 460 − 142 − 62 + 122 + 82 = 436
Σ𝑥𝑦 = 508 − 6(14) − 8(6) + 8(12) + 6(8) = 520
Therefore, Coefficient of correlation is given by
nΣxy−ΣxΣy
𝑟=
√[nΣ𝑥 2 −(Σx)2 ][nΣ𝑦 2 −(Σ𝑦)2 ]
25(520)−(125)(100)
=
√(25(650)−1252 )(25(460)−1002 )
= 0.5653

Dr. Narasimhan G, RNSIT 4


3.2 Rank Correlation
Introduction:
6Σ𝑑2
 Rank Correlation is given by 𝜌 = 1 − 𝑛3 −𝑛

1. Ten participants in a contest are ranked by two judges as follows:


x 1 6 5 10 3 2 4 9 7 8
y 6 4 9 8 1 2 3 10 5 7
Calculate the rank correlation co-efficient.

Co-efficient of rank correlation is given by


𝑥 𝑦 𝑑 =𝑥−𝑦 𝑑2
Σ𝑑2
𝑟 = 1 − 6 (𝑛3 −𝑛) 1 6 -5 25
60 6 4 2 4
= 1 − 6( 3 ) 5 9 -4 16
10 − 10
60 10 8 2 4
= 1 − 6( ) 3 1 2 4
990
7 2 2 0 0
= 4 3 1 1
11
9 10 -1 1
7 5 2 4
8 7 1 1
60

2. Calculate the rank correlation co-efficient from the following data showing the
ranks of 10 students in two subjects:
Mathematics 3 8 9 2 7 10 4 6 1 5
Physics 5 9 10 1 8 7 3 4 2 6

Co-efficient of rank correlation is given by 𝑥 𝑦 𝑑 =𝑥−𝑦 𝑑2


Σ𝑑2
𝑟 = 1 − 6 (𝑛3 −𝑛) 3 5 -2 4
24 8 9 -1 1
= 1 − 6( 3 ) 9 10 -1 1
10 − 10
24 2 1 1 1
= 1 − 6( ) 7 8 -1 1
990
10 7 3 9
= 0.8545
4 3 1 1
6 4 2 4
1 2 -1 1
5 6 -1 1
24

Dr. Narasimhan G, RNSIT 5


3. Find the rank correlation for the following data:
x 56 42 72 36 63 47 55 49 38 42 68 69
y 147 125 160 118 149 128 150 145 115 140 152 155

Co-efficient of rank correlation is given by


Σ𝑑2
𝑟 = 1 − 6 (𝑛3 −𝑛) 𝑥 𝑦 𝑅1 𝑅2 𝑑 =𝑥−𝑦 𝑑2
14 56 147 5 6 -1 1
= 1 − 6 (123 −12) 42 125 9 10 -1 1
72 160 1 1 0 0
= 0.9510 36 118 12 11 1 1
63 149 4 5 -1 1
47 128 8 9 -1 1
55 150 6 4 2 4
49 145 7 7 0 0
38 115 11 12 -1 1
42 140 10 8 2 4
68 152 3 3 0 0
69 155 2 2 0 0
14

4. Three judges A, B, C give the following ranks. Find which pair of judges has
common approach.
A 1 6 5 10 3 2 4 9 7 8
B 3 5 8 4 7 10 2 1 6 9
C 6 4 9 8 1 2 3 10 5 7
Co-efficient of rank correlation is given by
Σ𝑑2
𝐴𝐵
𝑟𝐴𝐵 = 1 − 6 (𝑛3 −𝑛 ) 2 2 2
𝐴 𝐵 𝐶 𝑑𝐴𝐵 𝑑𝐵𝐶 𝑑𝐶𝐴 𝑑𝐴𝐵 𝑑𝐵𝐶 𝑑𝐶𝐴
200
= 1 − 6 (103 −10) = −0.2 1 3 6 -2 -1 5 4 9 5
6 5 4 1 1 -2 1 1 -2
Σ𝑑2 5 8 9 -3 -1 4 9 1 4
𝐵𝐶
𝑟𝐵𝐶 = 1 − 6 (𝑛3 −𝑛 ) 10 4 8 6 -4 -2 36 16 -2
14 3 7 1 -4 6 -2 16 36 -2
= 1 − 6 (103 −10) = −0.3
2 10 2 -8 8 0 64 64 0
4 2 3 2 -1 -1 4 1 -1
Σ𝑑2
𝐶𝐴 9 1 10 8 -9 1 64 81 1
𝑟𝐶𝐴 = 1 − 6 (𝑛3 −𝑛 )
7 6 5 1 1 -2 1 1 -2
14
= 1 − 6 (103 −10) = 0.6 8 9 7 -1 2 -1 1 4 -1
200 214 60
𝑟𝐶𝐴 is maximum.
Therefore, Judges C and A has nearest common approach.

Dr. Narasimhan G, RNSIT 6


3.3 Regression analysis

Introduction:

 Regression line of y on x is 𝑦 − 𝑦̅ = 𝑏𝑦𝑥 (𝑥 − 𝑥̅ )


𝜎𝑦 𝑛Σ𝑥𝑦−Σ𝑥Σ𝑦
Where 𝑏𝑦𝑥 = 𝑟 𝜎 = 𝑛Σ𝑥 2 −(Σ𝑥)2 is called the regression co-efficient of y on x.
𝑥
 Regression line of x on y is 𝑥 − 𝑥̅ = 𝑏𝑥𝑦 (𝑦 − 𝑦̅)
𝜎 𝑛Σ𝑥𝑦−Σ𝑥Σ𝑦
Where 𝑏𝑥𝑦 = 𝑟 𝜎𝑥 = 𝑛Σ𝑦 2 −(Σ𝑦)2 is called the regression co-efficient of x on y.
𝑦

 The correlation coefficient is the geometric mean between the


two regression coefficients. That is, 𝑟 = √𝑏𝑦𝑥 × 𝑏𝑥𝑦 .
 𝑟 is considered as positive if both the regression coefficients are positive.
 𝑟 is considered as negative if both the regression coefficients are negative.
 It is impossible to get regression coefficients in opposite signs.

Problems:

1. Find the regression line of y on x for the following data:


x 1 3 4 6 8 9 11 14
y 1 2 4 4 5 7 8 9
Estimate the value of y when 𝒙 = 𝟏𝟎.

Σ𝑥 56 𝑥 𝑦 𝑥𝑦 𝑥2 𝑦2
𝑥̅ = = =7
𝑛 8 1 1 1 1 1
Σ𝑦 40
𝑦̅ = = =5 3 2 6 9 4
𝑛 8
𝑛Σ𝑥𝑦−Σ𝑥Σ𝑦 4 4 16 16 16
𝑏𝑦𝑥 = 𝑛Σ𝑥 2 −(Σ𝑥)2 6 4 24 36 16
2912−2240 8 5 40 64 25
= 4192−3136
9 7 63 81 49
= 0.6364 11 8 88 121 64
Regression line of y on x is 14 9 126 196 81
𝑦 − 𝑦̅ = 𝑏𝑦𝑥 (𝑥 − 𝑥̅ ) 56 40 364 524 256
𝑦 − 5 = 0.6364(𝑥 − 7) Σ𝑥 Σ𝑦 Σ𝑥 2 Σ𝑦 2 Σ𝑥𝑦
When 𝑥 = 10, 𝑦 = 6.9092

Dr. Narasimhan G, RNSIT 7


2. Obtain the lines of regression and hence find the coefficient of correlation for the
following data:
x 1 3 4 2 5 8 9 10 13 15
y 8 6 10 8 12 16 16 10 32 32

𝑥̅ =
Σ𝑥 70
= 10 = 7 𝑥 𝑦 𝑥𝑦 𝑥2 𝑦2
𝑛
Σ𝑦 150
1 8 8 1 64
𝑦̅ = = = 15 3 6 18 9 36
𝑛 10
𝑛Σ𝑥𝑦−Σ𝑥Σ𝑦
𝑏𝑦𝑥 = 𝑛Σ𝑥 2 −(Σ𝑥)2 =
14100−10500
= 1.7647 4 10 40 16 100
6940−4900 2 8 16 4 64
𝑛Σ𝑥𝑦−Σ𝑥Σ𝑦 14100−10500
𝑏𝑥𝑦 = 𝑛Σ𝑦 2 −(Σ𝑦)2 = 30680−22500 = 0.44 5 12 60 25 144
8 16 128 64 256
Regression line of y on x is given by
9 16 144 81 256
𝑦 − 𝑦̅ = 𝑏𝑦𝑥 (𝑥 − 𝑥̅ ) 10 10 100 100 100
𝑦 − 15 = 1.7647(𝑥 − 7) 13 32 416 169 1024
Regression line of 𝑥 on 𝑦 is given by 15 32 480 225 1024
𝑥 − 𝑥̅ = 𝑏𝑥𝑦 (𝑦 − 𝑦̅) 70 150 1410 694 3068
𝑥 − 7 = 0.44(𝑦 − 15) Σ𝑥 Σ𝑦 Σ𝑥𝑦 Σ𝑥 2 Σ𝑦 2
Coefficient of correlation is given by
𝑟 = √ 𝑏𝑦𝑥 × 𝑏𝑥𝑦 = √1.7647 × 0.44 = 0.8812

3. Find the coefficient of correlation and two regression lines for the following:
x 1 2 3 4 5 6 7 8 9 10
y 10 12 16 28 25 36 41 49 40 50
Σ𝑥 55
𝑥̅ = = 10 = 5.5 𝑥 𝑦 𝑥𝑦 𝑥2 𝑦2
𝑛
Σ𝑦 307 1 10 10 1 100
𝑦̅ = = = 30.7
𝑛 10 2 12 24 4 144
𝑛Σ𝑥𝑦−Σ𝑥Σ𝑦 20740−(55)(307)
𝑏𝑦𝑥 = 𝑛Σ𝑥 2 −(Σ𝑥)2 = = 4.6727 3 16 48 9 256
3850−3025
𝑛Σ𝑥𝑦−Σ𝑥Σ𝑦 20740−(55)(307) 4 28 112 16 384
𝑏𝑥𝑦 = = = 0.1965 5 25 125 25 625
𝑛Σ𝑦 2 −(Σ𝑦)2 113870−(307)2
6 36 216 36 1926
Regression line of y on x is given by 7 41 287 49 1681
𝑦 − 𝑦̅ = 𝑏𝑦𝑥 (𝑥 − 𝑥̅ ) 8 49 392 64 2401
9 40 360 81 1600
𝑦 − 30.7 = 4.6727(𝑥 − 5.5)
10 50 500 100 2500
Regression line of 𝑥 on 𝑦 is given by 55 307 2074 385 11387
𝑥 − 𝑥̅ = 𝑏𝑥𝑦 (𝑦 − 𝑦̅) Σ𝑥 Σ𝑦 Σ𝑥𝑦 Σ𝑥 2 Σ𝑦 2
𝑥 − 5.5 = 0.1965(𝑦 − 30.7)
Coefficient of correlation is given by
𝑟 = √ 𝑏𝑦𝑥 × 𝑏𝑥𝑦 = √4.6727 × 0.1965 = 0.9582

Dr. Narasimhan G, RNSIT 8


4. The two regression equations of the variables x and y are 𝒙 = 𝟏𝟗. 𝟏𝟑 − 𝟎. 𝟖𝟕𝒚 and
𝒚 = 𝟏𝟏. 𝟔𝟒 − 𝟎. 𝟓𝟎𝒙. Find (i) mean of x and y (ii) The correlation coefficient
between x and y.

Two regression lines are passing through (𝑥̅ , 𝑦̅).


𝑥̅ = 19.13 − 0.87𝑦̅
𝑦̅ = 11.64 − 0.50𝑥̅
That is,
𝑥̅ + 0.87𝑦̅ = 19.13
0.50𝑥̅ + 𝑦̅ = 11.64
By solving,
𝑥̅ = 15.94, 𝑦̅ = 3.67
By data,
𝑏𝑦𝑥 = −0.5 , 𝑏𝑥𝑦 = −0.87
Therefore,
𝑟 = −√0.5 × 0.87 = −0.6595

5. The equations of regression lines of two variables x and y are 𝒚 = 𝟎. 𝟓𝟏𝟔𝒙 + 𝟑𝟑. 𝟕𝟑
and 𝒙 = 𝟎. 𝟓𝟏𝟐𝒚 + 𝟑𝟐. 𝟓𝟐 Find the correlation coefficient and the means of x and y.

Two regression lines are passing through (𝑥̅ , 𝑦̅).


𝑥̅ = 0.512𝑦̅ + 32.52
𝑦̅ = 0.516𝑥̅ + 33.73
That is,
𝑥̅ − 0.512𝑦̅ = 32.52
−0.516𝑥̅ + 𝑦̅ = 33.73
By solving,
𝑥̅ = 67.67, 𝑦̅ = 68.65
By data,
𝑏𝑦𝑥 = 0.516 , 𝑏𝑥𝑦 = 0.512
Therefore,
𝑟 = √0.516 × 0.512 = 0.5140

Dr. Narasimhan G, RNSIT 9


6. In a partially destroyed laboratory record, only the lines of regression of y on x and
x on y are available as 𝟒𝒙 − 𝟓𝒚 + 𝟑𝟑 = 𝟎 and 𝟐𝟎𝒙 − 𝟗𝒚 = 𝟏𝟎𝟕 respectively.
Calculate 𝒙̅, 𝒚
̅ and the coefficient of correlation between x and y.

Two regression lines are passing through (𝑥̅ , 𝑦̅).


4𝑥̅ − 5𝑦̅ = −33
20𝑥̅ − 9𝑦̅ = 107
By solving,
𝑥̅ = 13, 𝑦̅ = 17
Given regression lines can be written as
4 33 9 107
𝑦 = 5𝑥 + , 𝑥 = 20 𝑦 +
5 20
4 9
Regression coefficients are 𝑏𝑦𝑥 = 5 , 𝑏𝑥𝑦 = 20
Coefficient of correlation between 𝑥 and 𝑦 is
4 9
𝑟 = √𝑏𝑦𝑥 × 𝑏𝑥𝑦 = √5 × 20 = 0.6

Dr. Narasimhan G, RNSIT 10


3.4 Curve fitting – Fitting the curve of the form 𝒚 = 𝒂𝒙 + 𝒃

Introduction:

 The curve obtained by predicting the most suitable values for the unknowns is
called the curve of best fit.
 The process of determining a curve of best fit is called curve fitting.
 The method employed for curve fitting is called the method of least squares.
 To fit the straight line 𝑦 = 𝑎 + 𝑏𝑥, solve the normal equations
Σ𝑦 = 𝑛𝑎 + 𝑏Σ𝑥
Σ𝑥𝑦 = 𝑎 Σ𝑥 + 𝑏Σ𝑥 2
Problems:

1. find the straight line that best fits the following data:
x 1 2 3 4 5
y 14 27 40 55 68

Straight line is of the form 𝑦 = 𝑎𝑥 + 𝑏 ---------- (1)


Solve the normal equations
Σ𝑦 = 𝑛𝑎 + 𝑏Σ𝑥 𝑥 𝑦 𝑥𝑦 𝑥2
Σ𝑥𝑦 = 𝑎 Σ𝑥 + 𝑏Σ𝑥 2 1 14 14 1
By table, 2 27 54 4
3 40 120 9
204 = 5𝑎 + 15𝑏
4 55 220 16
748 = 15𝑎 + 55𝑏 5 68 340 25
By solving, 15 204 748 55
𝑎 = 0, 𝑏 = 13.6 Σ𝑥 Σ𝑦 Σ𝑥𝑦 Σ𝑥 2
By substituting in (1),
𝑦 = 13.6𝑥
This is the straight line best fit.

Dr. Narasimhan G, RNSIT 11


2. Fit a straight line to the following data:
X 4 8 12 16 20
Y 8 10 12 10 16
and find the value of Y when X is 22.

Straight line is of the form 𝑦 = 𝑎 + 𝑏𝑥 ---------- (1)


Solve the normal equations
Σ𝑦 = 𝑛𝑎 + 𝑏Σ𝑥 𝑥 𝑦 𝑥𝑦 𝑥2
Σ𝑥𝑦 = 𝑎 Σ𝑥 + 𝑏Σ𝑥 2 4 8 32 16
By table, 8 10 80 64
12 12 144 144
56 = 5𝑎 + 60𝑏
16 10 160 256
736 = 60𝑎 + 880𝑏 20 16 320 400
By solving, 60 56 736 880
𝑎 = 6.4, 𝑏 = 0.4 Σ𝑥 Σ𝑦 Σ𝑥𝑦 Σ𝑥 2
By substituting in (1),
𝑦 = 6.4 + 0.4𝑥
This is the straight line of best fit.
Expected value of Y when X is 22:
𝑦 = 6.4 + 0.4(22) = 15.2

3. A simply supported beam carries a concentrated load P (lb) at its mid point.
Corresponding to various values of P, the maximum deflection Y (in) is
measured. The data are given below:
P 100 120 140 160 180 200
Y 0.45 0.55 0.6 0.70 0.80 0.85
Find the law of the form 𝒀 = 𝒂 + 𝒃𝑷.

Straight line is of the form 𝑦 = 𝑎 + 𝑏𝑝 ---------- (1)


Solve the normal equations
Σ𝑦 = 𝑛𝑎 + 𝑏Σ𝑝 𝑥 𝑦 𝑥𝑦 𝑥2
Σ𝑝𝑦 = 𝑎 Σ𝑝 + 𝑏Σ𝑝2 100 0.45 45 10000
By table, 120 0.55 660 14400
140 0.6 84 19600
3.95 = 6𝑎 + 900𝑏
160 0.7 11.2 25600
621 = 900𝑎 + 142000𝑏
180 0.8 144 32400
By solving, 200 0.85 170 40000
𝑎 = 0.0476, 𝑏 = 0.0041 900 3.95 621 142000
By substituting in (1), Σ𝑝 Σ𝑦 Σ𝑝𝑦 Σ𝑝2
𝑦 = 0.0476 + 0.0041𝑝
The law is of the form,
𝑦 = 0.0476 + 0.0041𝑝

Dr. Narasimhan G, RNSIT 12


4. If P is the pull required to lift a load W by means of a pulley block, find a
linear law of the form 𝑷 = 𝒎𝑾 + 𝒄 connecting P and W, using the following
data:
P 12 15 21 25
W 50 70 100 120
Where P and W are taken Kg. Compute P when W=150Kg.

Straight line is of the form 𝑦 = 𝑎 + 𝑏𝑤 ---------- (1)


Solve the normal equations
Σ𝑝 = 𝑛𝑎 + 𝑏Σ𝑤 𝑤 𝑝 𝑤𝑝 𝑤2
Σ𝑤𝑝 = 𝑎 Σ𝑤 + 𝑏Σ𝑤 2 50 12 600 2500
By table, 70 15 1050 4900
73 = 4𝑎 + 340𝑏 100 21 2100 10000
120 25 3000 14400
6750 = 340𝑎 + 31800𝑏
340 73 6750 31800
By solving,
Σ𝑤 Σ𝑝 Σ𝑤𝑝 Σ𝑤 2
𝑎 = 2.2759, 𝑏 = 0.1879
By substituting in (1),
𝑝 = 2.2759 + 0.1879𝑤
This is the straight line of best fit.
When 𝑤 = 150 𝑘𝑔.,
𝑝 = 2.2759 + 0.1879(150) = 30.4635 kg.

Dr. Narasimhan G, RNSIT 13


3.5 Curve fitting – Fitting the curve of the form 𝒚 = 𝒂 + 𝒃𝒙 + 𝒄𝒙𝟐

Introduction:

 To fit the parabola 𝑦 = 𝑎 + 𝑏𝑥 + 𝑐𝑥 2 , solve the normal equations


Σ𝑦 = 𝑛𝑎 + 𝑏Σ𝑥 + 𝑐Σ𝑥 2
Σ𝑥𝑦 = 𝑎 Σ𝑥 + 𝑏Σ𝑥 2 + 𝑐Σ𝑥 3
Σ𝑥 2 𝑦 = 𝑎Σ𝑥 2 + 𝑏Σ𝑥 3 + 𝑐Σ𝑥 4

Problems:

1. Fit a second degree parabola to the following data:


x 0 1 2 3 4
y 1 1.8 1.3 2.5 6.3

𝑥 𝑦 𝑥𝑦 𝑥2 𝑥2𝑦 𝑥3 𝑥4
0 1 0 0 0 0 0
1 1.8 1.8 1 1.8 1 1
2 1.3 1.8 4 5.2 8 16
3 2.5 2.6 9 22.5 27 81
4 6.3 7.5 16 100.8 64 256
10 12.9 25.2 30 130.3 100 354
Σ𝑥 Σ𝑦 Σ𝑥𝑦 Σ𝑥 2 Σ𝑥 2 𝑦 Σ𝑥 3 Σ𝑥 4

Second degree parabola is of the form 𝑦 = 𝑎 + 𝑏𝑥 + 𝑐𝑥 2 ---------- (1)


Solve the normal equations
Σ𝑦 = 𝑛𝑎 + 𝑏Σ𝑥 + 𝑐Σ𝑥 2
Σ𝑥𝑦 = 𝑎 Σ𝑥 + 𝑏Σ𝑥 2 + 𝑐Σ𝑥 3
Σ𝑥 2 𝑦 = 𝑎Σ𝑥 2 + 𝑏Σ𝑥 3 + 𝑐Σ𝑥 4
On substituting the values from the table,
12.9 = 4𝑎 + 10𝑏 + 30𝑐
37.1 = 10𝑎 + 30𝑏 + 100𝑐
130.3 = 30𝑎 + 100𝑏 + 354𝑐
By solving these equations,
𝑎 = 1.42, 𝑏 = −1.07, 𝑐 = 0.55
The best fitting second degree parabola is
𝑦 = 1.42 − 1.07𝑥 + 0.55𝑥 2

Dr. Narasimhan G, RNSIT 14


2. Find the parabola of the form 𝒚 = 𝒂 + 𝒃𝒙 + 𝒄𝒙𝟐 which fits closely with the
observations:
x -3 -2 -1 0 1 2 3
y 4.63 2.11 0.67 0.09 0.63 2.15 4.58

𝑥 𝑦 𝑥𝑦 𝑥2 𝑥2𝑦 𝑥3 𝑥4
-3 4.63 -13.89 9 41.67 -27 81
-2 2.11 -4.22 4 8.44 -8 16
-1 0.67 -0.67 1 0.67 -1 1
0 0.09 0 0 0 0 0
1 0.63 0.63 1 0.63 1 1
2 2.15 8.6 4 8.6 8 16
3 4.58 41.22 9 41.22 27 81
0 14.86 101.23 28 101.23 0 28
Σ𝑥 Σ𝑦 Σ𝑥𝑦 Σ𝑥 2 Σ𝑥 2 𝑦 Σ𝑥 3 Σ𝑥 4
Second degree parabola is of the form 𝑦 = 𝑎 + 𝑏𝑥 + 𝑐𝑥 2 ---------- (1)
Solve the normal equations
Σ𝑦 = 𝑛𝑎 + 𝑏Σ𝑥 + 𝑐Σ𝑥 2
Σ𝑥𝑦 = 𝑎 Σ𝑥 + 𝑏Σ𝑥 2 + 𝑐Σ𝑥 3
Σ𝑥 2 𝑦 = 𝑎Σ𝑥 2 + 𝑏Σ𝑥 3 + 𝑐Σ𝑥 4
On substituting the values from the table,
14.86 = 7𝑎 + 0𝑏 + 28𝑐
−0.11 = 0𝑎 + 28𝑏 + 0𝑐
101.23 = 28𝑎 + 0𝑏 + 196𝑐
By solving these equations,
𝑎 = 0.1329, 𝑏 = −0.0039, 𝑐 = 0.4975
The best fitting second degree parabola is
𝑦 = 0.1329 − 0.0039𝑥 + 0.4975𝑥 2

Dr. Narasimhan G, RNSIT 15


3. Fit a parabola 𝒚 = 𝒂 + 𝒃𝒙 + 𝒄𝒙𝟐 to the following data:
x 2 4 6 8 10
y 3.07 12.85 31.47 57.38 91.29

𝑥 𝑦 𝑥𝑦 𝑥2 𝑥2𝑦 𝑥3 𝑥4
2 3.07 6.14 4 12.28 8 16
4 12.85 51.4 16 205.6 64 256
6 31.47 188.82 36 1132.92 216 1296
8 57.38 459.04 64 3672.32 512 4096
10 91.29 912.9 100 9129 1000 10000
30 196.06 1618.3 220 14152.12 1800 15664
Σ𝑥 Σ𝑦 Σ𝑥𝑦 Σ𝑥 2 Σ𝑥 2 𝑦 Σ𝑥 3 Σ𝑥 4

Second degree parabola is of the form 𝑦 = 𝑎 + 𝑏𝑥 + 𝑐𝑥 2 ---------- (1)


Solve the normal equations
Σ𝑦 = 𝑛𝑎 + 𝑏Σ𝑥 + 𝑐Σ𝑥 2
Σ𝑥𝑦 = 𝑎 Σ𝑥 + 𝑏Σ𝑥 2 + 𝑐Σ𝑥 3
Σ𝑥 2 𝑦 = 𝑎Σ𝑥 2 + 𝑏Σ𝑥 3 + 𝑐Σ𝑥 4
On substituting the values from the table,
196.06 = 5𝑎 + 30𝑏 + 220𝑐
1618.3 = 30𝑎 + 220𝑏 + 1800𝑐
14152.12 = 220𝑎 + 1800𝑏 + 15664𝑐
By solving these equations,
𝑎 = 0.6960, 𝑏 = −0.8551, 𝑐 = 0.9920
The best fitting second degree parabola is
𝑦 = 0.6960 − 0.8551𝑥 + 0.9920𝑥 2

Dr. Narasimhan G, RNSIT 16


4. The following table gives the results of the measurements of train
resistances; V is the velocity in miles per hour. R is the resistance in pounds
per ton.
V 20 40 60 80 100 120
R 5.5 9.1 14.9 22.8 33.3 46.0
If R is related to V by the relation 𝑹 = 𝒂 + 𝒃𝒗 + 𝒄𝒗𝟐 find 𝒂, 𝒃 and 𝒄.

𝑉 𝑅 𝑉𝑅 𝑉2 𝑉 2𝑅 𝑉3 𝑉4
20 5.5 110 400 2200 8000 160000
40 9.1 364 1600 14560 64000 2560000
60 14.9 894 3600 53640 216000 12960000
80 22.8 1824 6400 145920 512000 40960000
100 33.3 3330 10000 333000 1000000 1004
120 46.0 5520 14400 662400 1728000 1204
420 131.6 12042 36400 1211720 3528000 364000000
Σ𝑉 Σ𝑅 Σ𝑉𝑅 Σ𝑉 2 Σ𝑉 2 𝑅 Σ𝑉 3 Σ𝑉 4
Second degree parabola is of the form 𝑅 = 𝑎 + 𝑏𝑉 + 𝑐𝑉 2 ---------- (1)
Solve the normal equations
Σ𝑅 = 𝑛𝑎 + 𝑏Σ𝑉 + 𝑐Σ𝑉 2
Σ𝑉𝑅 = 𝑎 Σ𝑉 + 𝑏Σ𝑉 2 + 𝑐Σ𝑉 3
Σ𝑉 2 𝑅 = 𝑎Σ𝑉 2 + 𝑏Σ𝑉 3 + 𝑐Σ𝑉 4
On substituting the values from the table,
12042 = 6𝑎 + 420𝑏 + 36400𝑐
12042 = 420𝑎 + 36400𝑏 + 3528000𝑐
1211720 = 36400𝑎 + 3528000𝑏 + 364000000𝑐
By solving these equations,
𝑎 = 4.35, 𝑏 = 0.0024, 𝑐 = 0.0029
The best fitting second degree parabola is
𝑅 = 4.35 + 0.0024𝑉 + 0.0029𝑉 2

Dr. Narasimhan G, RNSIT 17


3.6 Curve fitting – Fitting the curve of the form 𝒚 = 𝒂𝒙𝒃

Introduction:
 To fit the curve of the form 𝑦 = 𝑎𝑥 𝑏 , Take log on both sides,
log 𝑦 = log 𝑎 + 𝑏 log 𝑥 or 𝑌 = 𝐴 + 𝑏𝑋. Solve the normal equations
Σ𝑌 = 𝑛𝐴 + 𝑏Σ𝑋
Σ𝑋𝑌 = 𝐴 Σ𝑋 + 𝑏Σ𝑋 2
 Use natural log only.
1. Find the curve of the form 𝒚 = 𝒂𝒙𝒃 that fits the best the following data:
𝒙 3 4 5 6 7
𝒚 6 9 10 11 12

Curve is of the form 𝑦 = 𝑎𝑥 𝑏 -------- (1)


By taking log, log 𝑦 = log 𝑎 + 𝑏 log 𝑥
This is of the form 𝑌 = 𝐴 + 𝑏𝑋, where 𝑋 = log 𝑥 , 𝑌 = log 𝑦
Solve the normal equations
Σ𝑌 = 𝑛𝐴 + 𝑏Σ𝑋
Σ𝑋𝑌 = 𝐴 Σ𝑋 + 𝑏Σ𝑋 2

𝑋 = log 𝑥 𝑌 = log 𝑦 𝑋𝑌 𝑋2
1.0986 1.7918 1.9685 1.2069
1.3863 2.1927 3.0460 1.9218
1.6094 2.3026 3.7058 2.5902
1.7918 2.3979 4.2966 3.2105
1.9459 2.4849 4.8354 3.7865
7.8320 11.1744 17.8523 12.7159
Σ𝑋 Σ𝑌 Σ𝑋𝑌 Σ𝑋 2

On substituting the values from the table,


11.1744 = 5𝐴 + 7.8320𝑏
17.8523 = 7.8320𝐴 + 12.7159𝑏
By solving these equations,
𝐴 = 1.0152, 𝑏 = 0.7786
𝑎 = 𝑒 𝐴 = 2.7599, 𝑏 = 0.7786
The equation of the best fitting curve is
𝑦 = 2.7599𝑥 0.7786

Dr. Narasimhan G, RNSIT 18


2. Predict 𝒚 at 𝒙 = 𝟑. 𝟕𝟓 by fitting a power curve 𝒚 = 𝒂𝒙𝒃 to the data:
𝒙 1 2 3 4 5 6
𝒚 2. 98 4.26 5.21 6.10 6.80 7.50

Curve is of the form 𝑦 = 𝑎𝑥 𝑏 -------- (1)


By taking log, log 𝑦 = log 𝑎 + 𝑏 log 𝑥
This is of the form 𝑌 = 𝐴 + 𝑏𝑋, where 𝑋 = log 𝑥 , 𝑌 = log 𝑦
Solve the normal equations
Σ𝑌 = 𝑛𝐴 + 𝑏Σ𝑋
Σ𝑋𝑌 = 𝐴 Σ𝑋 + 𝑏Σ𝑋 2

𝑋 = log 𝑥 𝑌 = log 𝑦 𝑋𝑌 𝑋2
0 1.0919 0 0
0.6931 1.4492 1.0044 0.4804
1.0968 1.6506 1.8133 1.2069
1.3863 1.8083 2.5068 1.9218
1.6094 1.9169 3.0851 2.5909
1.7918 2.0149 3.6103 3.2105
6.5792 9.9318 12.0199 9.4098
Σ𝑋 Σ𝑌 Σ𝑋𝑌 Σ𝑋 2

On substituting the values from the table,


9.9318 = 6𝐴 + 6.5792b
12.0199 = 6.5792A + 9.4098b
By solving these equations,
𝐴 = 1.0912, 𝑏 = 0.5144
𝑎 = 𝑒 𝐴 = 2.9778, 𝑏 = 0.5144
The equation of the best fitting curve is
𝑦 = 2.9778𝑥 0.5144

Dr. Narasimhan G, RNSIT 19


3. An experiment gave the following values:
𝒗 350 400 500 600
𝒕 61 26 7 2.6
It is known that 𝒗 and 𝒕 are connected by the relation 𝒗 = 𝒂𝒕𝒃 . Find the best
possible values of 𝒂 and 𝒃.

Curve is of the form 𝑣 = 𝑎𝑡 𝑏 -------- (1)


By taking log, log 𝑣 = log 𝑎 + 𝑏 log 𝑡
This is of the form 𝑌 = 𝐴 + 𝑏𝑋, where 𝑋 = log 𝑡 , 𝑌 = log 𝑣
Solve the normal equations
Σ𝑌 = 𝑛𝐴 + 𝑏Σ𝑋
Σ𝑋𝑌 = 𝐴 Σ𝑋 + 𝑏Σ𝑋 2

𝑋 = log 𝑡 𝑌 = log 𝑣 𝑋𝑌 𝑋2
4.1109 5.8579 24.0812 16.8995
3.2581 5.9915 19.5209 10.6152
1.9459 6.2146 12.0930 3.7865
0.9555 6.3969 6.1122 0.9130
10.2704 24.4609 61.8073 29.2142
Σ𝑋 Σ𝑌 Σ𝑋𝑌 Σ𝑋 2

On substituting the values from the table,


24.4609 = 4𝐴 + 10.2704b
61.8073 = 10.2704A + 29.2142b
By solving these equations,
𝐴 = 7.0167, 𝑏 = −0.3511
𝑎 = 𝑒 𝐴 = 1115.10, 𝑏 = −0.3511
The equation of the best fitting curve is
𝑦 = 1115.10𝑥 −0.3511

Dr. Narasimhan G, RNSIT 20


4. The pressure and volume of a gas are related by an equation 𝒑𝒗𝜸 = 𝒌, 𝜸 and
𝒌 being constants. Find this equation to the following set of observations:
𝒑 (𝒌𝒈./𝒄𝒎𝟐 ) 0.5 1 1.5 2 2.5 3
𝒗(𝒍𝒊𝒕𝒓𝒆𝒔) 1.62 1.00 0.75 0.62 0.52 0.46

Curve is of the form 𝑝 = 𝑘𝑣 −𝛾 -------- (1)


By taking log, log 𝑝 = log 𝑘 − 𝛾 log 𝑣
This is of the form 𝑌 = 𝐴 − 𝛾𝑋, where 𝑋 = log 𝑣 , 𝑌 = log 𝑝
Solve the normal equations
Σ𝑌 = 𝑛𝐴 + (−𝛾)Σ𝑋
Σ𝑋𝑌 = 𝐴 Σ𝑋 + (−𝛾)Σ𝑋 2

𝑋 = log 𝑣 𝑌 = log 𝑝 𝑋𝑌 𝑋2
0.4824 −0.6931 −.03344 0.48242
0 0 0 0
−0.2877 0.4055 −0.1167 0.28772
−0.4780 0.6961 −0.3313 0.47802
−0.6539 0.9163 −0.5992 0.65392
−0.7765 1.0985 −0.8530 0.77652
−1.7137 2.4203 −2.2346 1.5746
Σ𝑃 Σ𝑉 Σ𝑃𝑉 Σ𝑃2

On substituting the values from the table,


2.4203 = 6𝐴 − 1.7137(−𝛾)
−2.2346 = −1.7137𝐴 + 1.5746(−𝛾)
By solving these equations,
𝐴 = 0.0028, 𝛾 = 1.4223
𝑎 = 𝑒 𝐴 = 0.9972, 𝛾 = 1.4223
The equation of the best fitting curve is
𝑝 = 0.9972𝛾 −1.4223

Dr. Narasimhan G, RNSIT 21

You might also like