化工應用數學 授課教師: 郭修伯 lecture 2 實驗數據的分析. 實驗精確程度 the...

26
化化化化化化 化化化化 化化化 Lecture 2 實實實實實實實

Upload: kristina-henderson

Post on 02-Jan-2016

240 views

Category:

Documents


5 download

TRANSCRIPT

Page 1: 化工應用數學 授課教師: 郭修伯 Lecture 2 實驗數據的分析. 實驗精確程度 The degree of accuracy sought in any investigation should depend upon the projected

化工應用數學

授課教師: 郭修伯

Lecture 2 實驗數據的分析

Page 2: 化工應用數學 授課教師: 郭修伯 Lecture 2 實驗數據的分析. 實驗精確程度 The degree of accuracy sought in any investigation should depend upon the projected

實驗精確程度 The degree of accuracy sought in any investigation should

depend upon the projected use of the results, and the accuracy of the required data and calculations should be consistent with the desired accuracy in the results.

It is desirable to complete the investigation and obtain the required accuracy with a minimum of time and expense.

The accuracy of a number representing the value of a quantity is the degree of concordance between this number and the number that represents the true value of the quantity; it may be expressed in either absolute or relative terms.

Page 3: 化工應用數學 授課教師: 郭修伯 Lecture 2 實驗數據的分析. 實驗精確程度 The degree of accuracy sought in any investigation should depend upon the projected

誤差來源 Accidental errors of measurement

– Such errors are inevitable in all measurements and that they result from small unavoidable errors of observation due to more or less fortuitous variation in the sensitivity of measuring instrument and the keenness of the senses of perception. (例如用了不準的 A來校正 B,用 B的錯誤校正曲線進行量測)

Precision and constant errors– A result may be extremely precise and at the same time highly inaccurate.– Constant errors can be detected only by performing the measurement with a nu

mber of different instruments and , if possible, by several independent methods and observers. (例如用了不準確的儀器或樣品取樣在不具代表性的地方)

Errors of Methods– These arises as a result of approximations and assumptions made in the theore

tical development of an equation used to calculate the desired result. (例如在計算時,用的錯誤的假設)

Page 4: 化工應用數學 授課教師: 郭修伯 Lecture 2 實驗數據的分析. 實驗精確程度 The degree of accuracy sought in any investigation should depend upon the projected

Variance and distribution of random errors

If an experimental measurement is repeated a number of times, the recorded values of the measured quantity almost invariably differ from one another.

The data so obtained may be used for two purposes:– to evaluate the precision of the measurement– to obtain an estimate of the probability that the mean of the

measurement differs from the true value of the measured quantity by some special amount

The “scatter” of the repeated measurements of the quantity is commonly reported in terms of the “variance” or “standard deviation” of the sets of measurements.

Page 5: 化工應用數學 授課教師: 郭修伯 Lecture 2 實驗數據的分析. 實驗精確程度 The degree of accuracy sought in any investigation should depend upon the projected

n

xxn

kk

1

2

2

)(

2

n

xx

n

kk

1

Sample variance and standard deviation

Sample mean

Sample variance

Sample standard deviation

Page 6: 化工應用數學 授課教師: 郭修伯 Lecture 2 實驗數據的分析. 實驗精確程度 The degree of accuracy sought in any investigation should depend upon the projected

n

xxn

kk

n

1

2

2

)(

lim

2

n

xx

n

kk

n

1lim

Population variance and standard deviation

Population mean

Population variance

Population standard deviation

Page 7: 化工應用數學 授課教師: 郭修伯 Lecture 2 實驗數據的分析. 實驗精確程度 The degree of accuracy sought in any investigation should depend upon the projected

Population and sample

Population

Sample 1

Page 8: 化工應用數學 授課教師: 郭修伯 Lecture 2 實驗數據的分析. 實驗精確程度 The degree of accuracy sought in any investigation should depend upon the projected

Normal frequency distribution

If an infinite data set the variation in x are random, it was first shown by Gauss that the distribution of values of x about the population mean is given by

– f is frequency, or probability of occurrence, of a value of magnitude x.

2

}]/))[(2/1(exp{ 2xxf

Page 9: 化工應用數學 授課教師: 郭修伯 Lecture 2 實驗數據的分析. 實驗精確程度 The degree of accuracy sought in any investigation should depend upon the projected

Normal frequency distribution

The probability that a single measurement will give a value lying between x - dx/2 and x + dx/2 is

The probability is less than 5% that a single measurement of x will differ from by more than twice the standard deviation, i.e. by more than 2.

The range 2 is frequently called the “95 percent confidence belt

on x”.

dxxx

fdx

2

}]/))[(2/1(exp{ 2

x

Page 10: 化工應用數學 授課教師: 郭修伯 Lecture 2 實驗數據的分析. 實驗精確程度 The degree of accuracy sought in any investigation should depend upon the projected

More about variance...

The sample mean is the best estimate of the population mean.

The sample variance is not the best estimate of the population variance. A better estimate is given by

sample Population

21

2

2

11

)(

n

n

n

xxs

n

kk

Sample estimate of the population variance

Page 11: 化工應用數學 授課教師: 郭修伯 Lecture 2 實驗數據的分析. 實驗精確程度 The degree of accuracy sought in any investigation should depend upon the projected

Number of measurment

By how much can the mean of n measurement be expected to differ from the best value of the population mean?

Population ,

Set 1, k times, s1

2

Set 2, k times, s2

2 … n sets1x 2x

x 2

Estimate of the set of means, Estimate variance of the set of means,

mx22im ss

Page 12: 化工應用數學 授課教師: 郭修伯 Lecture 2 實驗數據的分析. 實驗精確程度 The degree of accuracy sought in any investigation should depend upon the projected

Sample variance of the mean

The grand mean

The sample estimate of the variance of the set of means

The sample estimate of the variance of the set of means may be estimated by a single set

n

xx

n

ii

m

1

1

)(1

2

2

n

xxs

n

imi

m

k

ssm

22

sample Population

(Sample猜測的 population mean)

(Sample猜測的 population variance)

Page 13: 化工應用數學 授課教師: 郭修伯 Lecture 2 實驗數據的分析. 實驗精確程度 The degree of accuracy sought in any investigation should depend upon the projected

Confident limits for small samples

To associate the magnitude of deviations of from the population mean with the probability of the occurrence of such deviations.

It is known that if the sample set contains at least 20 entries, the error introduced by the previous slide is not serious.

For smaller samples, however, s2/k is not an adequate estimate of m

2.

ix

x

22

2mm k

ss

Page 14: 化工應用數學 授課教師: 郭修伯 Lecture 2 實驗數據的分析. 實驗精確程度 The degree of accuracy sought in any investigation should depend upon the projected

Student’s t test

The solution to small number of entries was first pointed out in Biometrika, Vol. VI, 1908, by W.S. Gossett, who signed his article “STUDENT”.

The dimensionless quantity of particular interest in a confidence-limit analysis is called “Student’s t”:

It involves estimates obtained from a sample of finite size.

m

i

s

xxt

Page 15: 化工應用數學 授課教師: 郭修伯 Lecture 2 實驗數據的分析. 實驗精確程度 The degree of accuracy sought in any investigation should depend upon the projected

Student’s t test

t is the difference between the measured sample mean and the true population mean divided by the sample estimate of the standard deviation of the population of means.

“Student” derived the frequency distribution for t:

– Cf is a function of f only

– f is the “degree of freedom”, defined as the number of values used to calculate the means on which t is based, less the number of means so calculated.

dtf

tCdtf fft })1{( 2/)1(

2

Page 16: 化工應用數學 授課教師: 郭修伯 Lecture 2 實驗數據的分析. 實驗精確程度 The degree of accuracy sought in any investigation should depend upon the projected

Student’s t test

The distribution funcion of t is used to calculate the probability value of the size of the sample (the degrees of freedom f).

Probability calculation of this kind have been carried out over a wide range of conditions, and the results are tablulated in the handout given in the course.

sample Populationt

Page 17: 化工應用數學 授課教師: 郭修伯 Lecture 2 實驗數據的分析. 實驗精確程度 The degree of accuracy sought in any investigation should depend upon the projected

T test 範例

Two methods were used to measure a quantity. It is desired to use these data to obtain the following information:

Procedure 1 Procedure 2Xi1 55.3 52.6Xi2 56.9 54.3Xi3 55.8 58.0Xi4 57.3 52.7Xi5 57.7 60.0Xi 56.6 55.5 (Xik- Xi)

2 4.1 43.9S1

2(Xi) 1.0 11Sm

2 0.2 2.295% confidence limits 55.3 = X1 = 57.9 51.3 = X2 = 59.9

Page 18: 化工應用數學 授課教師: 郭修伯 Lecture 2 實驗數據的分析. 實驗精確程度 The degree of accuracy sought in any investigation should depend upon the projected

T test 範例(續)

The confidence limits to be assigned to the results of procedures 1 and 2

The significance of the difference between the mean values of the results of procedures 1 and 2

The “best value” to be assigned to the sample analysis

The confidence limits of the best value

Page 19: 化工應用數學 授課教師: 郭修伯 Lecture 2 實驗數據的分析. 實驗精確程度 The degree of accuracy sought in any investigation should depend upon the projected

T test 範例(續) Confidence limits

– The sample mean of procedure 1 is easily found to be 56.6

– The external probability limit on t will be arbitrarily set at 0.05, corresponding to 95 percent confidence limits.

– Five measured values are used and one mean is calculated, degree of freedom: f = 5 - 1 = 4

– From the “t table” for f = 4, values of t lying outside 2.776 only are 0.05 probable.

– The 95 percent confidence limits on t are:

– The 95 percent confidence limits on x1 are then

776.2776.2 t

20.05

4/1.4)1/()( 211

212

1,

k

kxx

k

ss im

9.573.55

3.120.0776.2776.2

1

1,11

x

sxx m

Page 20: 化工應用數學 授課教師: 郭修伯 Lecture 2 實驗數據的分析. 實驗精確程度 The degree of accuracy sought in any investigation should depend upon the projected

T test 範例(續) The significant of the difference

– The mean value obtained by procedure 1 is 56.6 with 95 percent limits of

– The mean value obtained by procedure 2 is 55.5 with 95 percent limits of

– The sample means are different, which might be taken to indicate a systematic difference or bias between the two methods of analysis.

– The 95 percent confidence limits analysis shows that the mean of sample 2 is included with the confidence limits of sample 1, and vice versa.

– It may be concluded that the difference between the two means has no statitical significance.

9.573.55 1 x

9.593.51 2 x

Page 21: 化工應用數學 授課教師: 郭修伯 Lecture 2 實驗數據的分析. 實驗精確程度 The degree of accuracy sought in any investigation should depend upon the projected

T test 範例(續) The best value?

– Since the difference between the mean value obtained by procedure 1 and that by procedure 2 is not statistically significant, the best value to be assigned to the sample analysis is a weighted combination of the two mean values.

– If the difference between the means has been significant, it would have been concluded that one or both of the procedures were affected by non-random factors (errors of method or bias). In this case, the best value cannot be estimated.

Page 22: 化工應用數學 授課教師: 郭修伯 Lecture 2 實驗數據的分析. 實驗精確程度 The degree of accuracy sought in any investigation should depend upon the projected

T test 範例(續) The best value obtainable from a series of sets of

measurements exhibiting statistically equivalent means is given by

iss

kkW

W

xWx

mi

i

i

ii

n

ii

n

iii

valuebest

,

1)()(222

1

1

the number of measurements in the ith set

Population variance

6.562.2/12.0/1

2.2/5.552.0/6.56

1

1

n

ii

n

iii

valuebest

W

xWx

Page 23: 化工應用數學 授課教師: 郭修伯 Lecture 2 實驗數據的分析. 實驗精確程度 The degree of accuracy sought in any investigation should depend upon the projected

T test 範例(續) The confidence limits of the best value

– the variance of the best value is needed:

– the degree of freedom: f = 10 - 2 = 8– the t limits are 2.3– Consequetly, the 95 percent confidence limits on the best va

lue are

18.02.2/12.0/1

1

)/1(

1

]/)[(

1

1

,2

1

2,

2

n

i

im

n

iii

valuebestm

sk

6.576.55

0.118.03.2

x

Page 24: 化工應用數學 授課教師: 郭修伯 Lecture 2 實驗數據的分析. 實驗精確程度 The degree of accuracy sought in any investigation should depend upon the projected

Other test ( L test)

L test:– A calculation to determine the probability that the s

amples represent normal populations exhibiting the same population variance 2, but without regard to the population means

Page 25: 化工應用數學 授課教師: 郭修伯 Lecture 2 實驗數據的分析. 實驗精確程度 The degree of accuracy sought in any investigation should depend upon the projected

Other test (F test)

F test:– In a single set of data, two types of error are possible - random erro

rs and errors of method or bias. The magnitude of the random errors is estimated by the with-sample or error variance. However, from the single set of data, no estimate of the error due to method is possible. Suppose that other sets of data are available which are likewise subject to both random and method errors. For each data set, the within-sample or error variance may be calculated.

– The statistic F is the ratio of the variance which contains both random and method error to the variance which includes random errors only.

– The magnitude of F is a measure of the importance of errors of method which differ from one data set to the next.

Page 26: 化工應用數學 授課教師: 郭修伯 Lecture 2 實驗數據的分析. 實驗精確程度 The degree of accuracy sought in any investigation should depend upon the projected

最小平方法 (least squares)

Recall: A best straight line as the one for which the sum of the squares of the error terms is a minimum.

The best measure of the precision with which the points fit the line is the variance of estimate:

The estimate of the error variance of Yi is

The confidence limits of Yi is ( t ) se2(Yi )

)( xxbaY

2

)()( 1

2

2

n

yYys

n

iii

ie

degrees of freedom (2 = a, b)

])(

)(1)[()()()()]([)(

1

2

2222222

n

ii

i

iieeieieie

xx

xx

nysbsxxasxxbasYs