PHYS 45 Sprng semester 7 Lecture : Dealng wth Expermental Uncertantes Ron Refenberger Brck anotechnology Center Purdue Unversty Lecture Introductory Comments Expermental errors (really expermental uncertantes) are common to all measurements They are never known exactly eed to know how to dentfy and deal wth them Sources of error: Random vs. Systematc Know how to calculate Mean and Standard devaton Understand error propagaton
Outlne Random vs. Systematc errors Mean and standard devaton Gaussan probablty dstrbuton functon (pdf) Standard error of the mean Combnng errors Regresson analyss Best ft to straght lne Plottng EXCEL Lnest uncertantes n fttng coeffcents Small sample problem Student t-factors and confdence levels The test 3 Random vs. Systematc Random Errors Affect each measurement dfferently Produce results dstrbuted around some mean value Can be reduced by takng multple measurements Random error and systematc errors combne by ether addng the squares of the separate errors and takng square root (uncorrelated errors) or by addng the errors (worst case error). EXAMPLE: Suppose a mass s measured to have a mass of 5 g usng a mass balance havng a calbraton accuracy of 5%. What s the total uncertanty n the measurement? Standard (uncorrelated) uncertanty Standard Fractonal Error Random Error Systematc Error Systematc Errors Affect all measurements n the same way Often dffcult to know Don t average out Maxmum uncertanty (worst case) ote: Unts are dfferent! Max. Fractonal Error Random Error Systematc Error.5.4.5.9 5 5 Standard Fractonal Error.4.64 Absolute Error.95g 4.5g Absolute Standard Error.645g 3.g Result 5 4.5 g Result 5 3 g 4 Standard s a word whch ndcates that a measurement represents a sample from a populaton
Gudelnes Beware of quotng too many sgnfcant fgures n your results do you mean.847 or.8? Errors can often be better estmated usng statstcs Errors are only approxmately known only quote or at most sgnfcant fgures. (.8.6) x 8 m/s vs. (.8.583) x 8 m/s Statstcal tests are ndcators. You must also be guded by ntuton, judgement, and common sense. 5 Calculatng the Mean and Standard Devaton If a quantty x s measured tmes, you can calculate the mean x and std. devaton s measurements x x s x x useful number to quantfy how data fluctuates about ts mean As The Gaussan probablty dstrbuton functon (pdf) <x>- <x>+ True Value Best Estmate Mean <x> x Varance s Standard devaton s Standard error of the mean m s/ <x> 68% of the dstrbuton between <x>- and <x>+ 95% of the dstrbuton between <x>-.96 and <x>+.96 ormal (Standard) dstrbuton calculator: http://onlnestatbook.com//calculators/normal_dst.html x 6 3
Why does random nose have a Gaussan shape? probablty of obtanng a specfc outcome when a quantty y o s measured n the presence of four ndependent and random sources of nose all wth the same sze. r Possble Devatons Total Devaton Measured Outcome Multplcty Probablty - - - - -4 y o -4 6.5% 3 - - - + - - + - - + - - + - - - - - + + - + - + - + + - + - - + + - + - + + - - - + + + + - + + + + - + + + + - - y o - 4 5.% y o 6 37.5% y o + 4 5.% 4 + + + + 4 y o + 4 6.5% Probablty 4 sources of error each contrbutng y.4.3... yo-4 y yo- y yo yo+ y yo+4 y Possble Values of Measurement 7 Combnng Errors When a result depends on more than one quantty, you must SYSTEMATICALLY combne errors Gven : x and y Quoted result :( x y) or ( x y) General Rule: IF z f x x y z x y z x y z z IF z x y or x y x z x y x y IF z xyor z z y z x y x y Quoted result :( xy) z or ( x ) y z df z x dx These formulas assume uncorrelated errors n x and y 8 4
Example Measurng the Focal Length of a Lens f o f focal length f, o o f f f o o - f o o - - o o o o - f o o o - -. o o o o o o o o o f o o o o Puttng n numbers:.6.4 cm o..3 cm f 7.9 f.6. f o 79.8 47.6. 4.4 f 7.9. cm..4.6.3.6. o o Largest contrbuton 9 To save tme, use onlne uncertanty calculator Choosng standard error, obtan f=7.9. cm same answer as on prevous slde http://denethor.wlu.ca/data/xc.shtml http://web.mst.edu/~gbert/java/uncertanty.html#operaton 5
Regresson Analyss noun: regress ˈrēˌɡres/ the acton of returnng to a former or less developed state The Regresson Effect Most data usually contans ) a predctable component ("sgnal") AD ) a statstcally ndependent unpredctable component ("nose"). The best we can hope for s to ft that part of the data due to the sgnal. Any reasonable ft should exhbt less varablty than the actual measurements. The fttng process therefore mples a regresson to the mean. Best Ft to a Straght Lne Specal Case of Regresson Analyss Collecton of data ponts {x, y } How to determne best values for a and b? Y The least-squares method mnmzes the sum of the squares of the devatons of the expermental data from the straght lne ft n an unbased fashon. One of the man lmtatons s an mplct assumpton that the errors n the ndependent varable (x) are neglgble.e. zero. X y ax b y y y R-squared s the percent of varance explaned by the model. R measures the percentage reducton n mean-squared-error that the regresson model acheves relatve to a nave model y=constant. 6
Best Ft to a Straght Lne Lnear Regresson y ax b To fnd the slope a that mnmzes,wetakethe dervatve wth respect to a and set t to zero. y ax bx y ax b a a yx x x a b DFaGb To fnd the ntercept b that mnmzes,wetake the dervatve wth respect to b and set t to zero. y ax b b b y ax b y x a b H GaJb yx x x y D F G H J 3 Results - Lnear Regresson Two equatons, two unknowns DG FH H J b and a b G FJ G G Uncertantes n a and b are gven by Goodness of Ft R F J FJ G FJ G b a y ax b y y 4 7
In Excel, the best ft to a straght lne s easy Example Speed of Lght Experment: Measure tme for lght pulse to go from pont A to pont B when separaton between A and B s known Default Plot Dstance Travelled 45 4 35 3 5 5 5 4 6 8 4 6 Tme delay 5 Better Roundtrp Dstance Travelled (m) 5 4 3 y =.9x R² =.998 4 8 6 Tme delay (nsec) 6 8
Best Tme delay (nsec) 6 8 4 y = 3.5897x R² =.9894 Speed of Lght 3 4 5 Roundtrp Dstance Travelled (m) Fgure : Tme delay vs. roundtrp dstance travelled for a lght pulse reflected from a mrror. The dashed lne s a best ft straght lne to the data wth an R value of.989. The nverse of the slope of the straght lne gves the speed of lght as.78 x 8 m/s. 7 Uncertantes n Ftted Coeffcents EXCEL Lnest Typcal Data round trp uncertanty dstance (m) (m) t (ns). In Excel, grab a x3 block of cells uncertanty (ns) 3.9. 3.6.5.7. 3.4 3.6 4.. 83. 5.3 9.6.4.4 6. 4..4 46.3 7.8 Steps to follow (on a PC). Ht the F key 3. Type =Lnest(range n y, range n x,,) 4. Ht the Ctrl Shft Enter keys = a a R Best Ft Straght Lne: Y=(3.79.8)X + (-5.884.64) Tme delay (nsec) 6 8 4-4 Data best ft b b stnd. error n y Speed of Lght 3 4 5 Roundtrp Dstance Travelled (m) 3.79 5.88.8 4.64.99 5.5 c = (.6. 3 ) x 8 m/s 8 9
The Small Sample Problem Statstcal methods assume a large number of observatons lead to relable estmates for the mean and standard devaton. Seldom the case. Whensmallernumberofobservatonsare made, less confdence n accuracy of calculated values. Can ths reduced level of confdence be quantfed? An addtonal statstc based on the degrees of freedom (dof), gves a multplcatve factor called the Student t-factor. W. S. Gosset developed ths approach n the early 9 s and publshed t under the pseudonym Student. Gosset s statstcs are partcularly applcable when dscussng the small sample problem. 9 The Student-t factors The dof s close to the number of data ponts. Varous constrants reduce the dof to an nteger value less than. If a problem has r constrants, then the dof=-r. As an example, from the prevous analyss we have 5 data ponts whch we used to determne the slope and standard devaton of 3.79.8. Snce we have calculated the mean () and standard devaton () from data, the dof=5-=3. At the 5% confdence level, the mean and standard devaton s 3.79 (.8x.765) =3.79.4 nsec/m At the 95% confdence level, the mean and standard devaton s 3.79 (.8x3.8) =3.79.57 nsec/m Table : t-factors for varous levels of confdence dof t(5%) t(9%) t(95%) t(99%). 6.3.7 63.7.86.9 4.3 9.9 3.765.35 3.8 5.84 4.74.3.78 4.6 5.77..57 4.3 6.78.94.45 3.7 7.7.89.36 3.5 8.76.86.3 3.36 9.73.83.6 3.5.7.8.3 3.7 5.69.75.3.95.687.7.9.85 3.683.7.4.75.674.64.96.58 When dof=, results are those from a Gaussan pdf
The test Suppose you measure the same quantty n a number of dfferent ways. Can the results be averaged to provde a better estmate for the quantty measured? Yes, f all the measurements are drawn from the same populaton. Test usng the statstc. Example: Measure the focal length of a convergng lens usng four dfferent technques Technque Measured focal length Geometry radus of curvature.9. cm Ray tracng.6. cm 3 Object at nfnty 9.3.3 cm 4 Bessel s conjugate focal ponts 9.9. cm 5 4 3 Focal Length Convergng Lens Radus of curvature Bessel s conjugate method Object at Ray tracng 8. 9.... 3. Measured focal length (cm) The test - graphcally y y n y n + Probablty y + + x n x x... x n
Step : Calculate weghted mean and weghted standard devaton 4 cm 4 w 4 9.99.73.85 cm w f 9.99.9 cm best answer?? w Step : Calculate and reduced from the data st x,, are results usng technque, etc. x x x Replace each... wth the weghted mean w x w fw f w f3 w f4 w 3 4...3..9 9.99.6 9.99 9.3 9.99 9.9 9.99 6.84 dof 43 6.84 reduced.8 dof 3 The f s the focal length determned by method 3 Step 3: Consult the probablty dstrbuton functon (pdf) f( ;dof) d( ) s the probablty that a partcular value of falls between and +d( ). + d( ) The probablty dstrbuton functon f( ;dof) for dof=,,3,4,5,.. as a functon of. The dstrbuton becomes more symmetrc as dof (=) ncreases. 4
reduced Step 4: Calculate, P f dof d P s the cumulatve probablty assocated wth a partcular value of reduced obtaned for the problem at hand. P (n percent) s the probablty that f another experment s conducted, the new data wll yeld a new value of reduced that falls between and the current reduced. SUMMARY: Re-measure the same x s (n ths case focal lengths) Calculate a new value of reduced from new measurements. P s the probablty that the new reduced wll on average be less than or equal to the orgnal reduced. You want P to be close to. For the measurements dscussed here.8 P f,3 d.48 Type: =CHISQ.DIST(.8,3,) nto an empty Excel cell and Excel should return the value.48. 5 Step 5: Interpret the result There s roughly a 48% chance that repeated measurements would gve values that would produce a value of.8 or less. Conversely, there s a 5% chance f the measurements are repeated, we mght get a value of >.8. We can nfer n an unbased and statstcal way that the result f 9.99.9 cm w w would only be obtaned agan, after performng a new set of measurements, wth a confdence level of about 5%. 6 3
Up ext Experment : Reflecton of Lght from Mrrors 7 4