The Monte Carlo method what and how?

Similar documents
New approaches to uncertainty evaluation:

Estimation of uncertainties using the Guide to the expression of uncertainty (GUM)

Science. Approaches to measurement uncertainty evaluation. Introduction. for a safer world 28/05/2017. S L R Ellison LGC Limited, Teddington, UK

Revision of the Guide to the expression of uncertainty in measurement impact on national metrology institutes and industry

ISE/OR 762 Stochastic Simulation Techniques

Guide to the Expression of Uncertainty in Measurement (GUM) and its supplemental guides

Unit 4. Statistics, Detection Limits and Uncertainty. Experts Teaching from Practical Experience

Guide to the Expression of Uncertainty in Measurement Supplement 1 Numerical Methods for the Propagation of Distributions

Introduction to Statistical Methods for High Energy Physics

MEASUREMENT UNCERTAINTY AND SUMMARISING MONTE CARLO SAMPLES

Determinação da incerteza de medição para o ensaio de integral J através do método de Monte Carlo

Monte Carlo uncertainty estimation for wavelength calibration Abstract

AN EXPLANATION OF THE DG-1000 ACCURACY SPECIFICATIONS

Measurement Uncertainty Knowing the Unknown

A guide to expression of uncertainty of measurements QA4EO-QAEO-GEN-DQK-006

Measurement And Uncertainty

Ensemble Data Assimilation and Uncertainty Quantification

SAMM POLICY 5 (SP5) POLICY ON MEASUREMENT UNCERTAINTY REQUIREMENTS FOR SAMM TESTING LABORATORIES Issue 2, 28 February 2007 (Amd. 1, 11 August 2014)

Modeling Uncertainty in the Earth Sciences Jef Caers Stanford University

Chapter 4: Monte Carlo Methods. Paisan Nakmahachalasint

1 Normal Distribution.

CONTENTS. Preface List of Symbols and Notation

APPENDIX G EVALUATION OF MEASUREMENT UNCERTAINTY

Essentials of expressing measurement uncertainty

Doubt-Free Uncertainty In Measurement

The PUMA method applied to the measures carried out by using a PC-based measurement instrument. Ciro Spataro

Experiment A12 Monte Carlo Night! Procedure

Random number generators and random processes. Statistics and probability intro. Peg board example. Peg board example. Notes. Eugeniy E.

Lecture 1: Probability Fundamentals

UNCERTAINTY ANALYSIS FOR LABORATORY ACCREDITATION. Peter B. Crisp. Fluke Precision Measurement Ltd, 52 Hurricane Way, Norwich, UK

ABSTRACT. Page 1 of 9

G104 - A2LA Guide for Estimation of Measurement Uncertainty In Testing

Examples of measurement uncertainty evaluations in accordance with the revised GUM

APPENDIX G ESTIMATION OF UNCERTAINTY OF MEASUREMENT

RECOMMENDED TOOLS FOR SENSITIVITY ANALYSIS ASSOCIATED TO THE EVALUATION OF MEASUREMENT UNCERTAINTY

SHIFTED UP COSINE FUNCTION AS MODEL OF PROBABILITY DISTRIBUTION

2.1 Independent, Identically Distributed Trials

ELEG 3143 Probability & Stochastic Process Ch. 2 Discrete Random Variables

Statistics for Data Analysis. Niklaus Berger. PSI Practical Course Physics Institute, University of Heidelberg

A Unified Approach to Uncertainty for Quality Improvement

Topics for Today. Sampling Distribution. The Central Limit Theorem. Stat203 Page 1 of 28 Fall 2011 Week 5 Lecture 2

y, x k estimates of Y, X k.

Software Support for Metrology Best Practice Guide No. 6. Uncertainty Evaluation. NPL Report DEM-ES-011. M G Cox and P M Harris NOT RESTRICTED

Monte Carlo Methods in High Energy Physics I

Probability Distribution

Random number generation

Convergence of Random Processes

Lab 0: Modeling and Error. Goals 1. Review the lab procedures, safety issues and grading policies. 2. Understanding Modeling and Errors

Computational modeling

Review of the role of uncertainties in room acoustics

From the propagation of uncertainties to the propagation of distributions

Software Support for Metrology Best Practice Guide No. 6. Uncertainty and Statistical Modelling M G Cox, M P Dainton and P M Harris

POWER UNDERSTANDING MEASUREMENT UNCERTAINTY IN DP FLOW DEVICES

Probably About Probability p <.05. Probability. What Is Probability?

OIML G GUIDE. Edition 2009 (E) ORGANISATION INTERNATIONALE INTERNATIONAL ORGANIZATION

Traceability, validation and measurement uncertainty 3 pillars for quality of measurement results. David MILDE

OIML D 28 DOCUMENT. Edition 2004 (E) ORGANISATION INTERNATIONALE INTERNATIONAL ORGANIZATION. Conventional value of the result of weighing in air

TITLE OF THE CD (English): New OIML Document

R SANAS Page 1 of 7

Mathematical Probability

OUTLINE. Deterministic and Stochastic With spreadsheet program : Integrated Mathematics 2

Doing Physics with Random Numbers

Annex xxx General guidelines for the assessment of uncertainties in solar thermal systems performance testing

Uncertainty Analysis in High-Speed Multifunction Data Acquisition Device. M.Catelani, L.Ciani, S.Giovannetti, A.Zanobini

Human-Oriented Robotics. Probability Refresher. Kai Arras Social Robotics Lab, University of Freiburg Winter term 2014/2015

UNCERTAINTY OF COMPLEX SYSTEMS BY MONTE CARLO SIMULATION

Experiment 0 ~ Introduction to Statistics and Excel Tutorial. Introduction to Statistics, Error and Measurement

M. A. Navacerrada, C. Díaz, A. Pedrero and L. Iglesias

Safety Envelope for Load Tolerance and Its Application to Fatigue Reliability Design

4.5 Applications of Congruences

Modern Methods of Data Analysis - WS 07/08

Uncertainty Analysis of the Harmonoise Road Source Emission Levels

DISCRETE RANDOM VARIABLES EXCEL LAB #3

Week 4 Concept of Probability

Procedure for Uncertainty Determination for Calibration Consoles

Uncertainty due to Finite Resolution Measurements

Decision making and problem solving Lecture 1. Review of basic probability Monte Carlo simulation

Critical Values for the Test of Flatness of a Histogram Using the Bhattacharyya Measure.

Decision rules applied to conformity assessment

Practical Statistics for the Analytical Scientist Table of Contents

Specific Accreditation Guidance. Infrastructure and Asset Integrity. Measurement Uncertainty in Geotechnical Testing

Standard Model at the LHC (Lecture 3: Measurement of Cross-Sections) M. Schott (CERN)

Uncertainty Quantification and Validation Using RAVEN. A. Alfonsi, C. Rabiti. Risk-Informed Safety Margin Characterization.

Chem 7040 Statistical Thermodynamics Problem Set #6 - Computational Due 1 Oct at beginning of class

MEASUREMENT UNCERTAINTY PREPARED FOR ENAO ASSESSOR CALIBRATION COURSE OCTOBER/NOVEMBER Prepared by MJ Mc Nerney for ENAO Assessor Calibration

Introduction to Computer Tools and Uncertainties

Determination of Uncertainties for Correlated Input Quantities by the Monte Carlo Method

Establishing traceability and estimating measurement uncertainty in physical, chemical and biological measurements

Simulation. Where real stuff starts

Calculating Measurement Uncertainty of the Conventional value of the result of weighing in air

The GUM Supplement 1 and the Uncertainty Evaluations of EMC Measurements

An improved procedure for combining Type A and Type B components of measurement uncertainty

IV. The Normal Distribution

Document No: TR 12 Issue No: 1

Precision estimated by series of analysis ISO and Approach Duplicate Approach

University of Texas-Austin - Integration of Computing

João A. Sousa Alexandra M. Reynolds Álvaro S. Ribeiro

A Rocket Experiment for Measurement Science Education

Basics of Uncertainty Analysis

Monte Carlo Methods. Part I: Introduction

Transcription:

A top down approach in measurement uncertainty estimation the Monte Carlo simulation By Yeoh Guan Huah GLP Consulting, Singapore (http://consultglp.com) Introduction The Joint Committee for Guides in Metrology (JCGM) in 2008 published a supplement guide JCGM 101 [1], titled Evaluation of measurement data Supplement 1 to the Guide to the expression of uncertainty in measurement Propagation of distributions using a Monte Carlo method. This is a revolutionary document which brings in the application of computer simulation into the subject of measurement uncertainty (MU) evaluation. It is intended to give added value to the GUM (JCGM 100) [2] method by providing guidance on alternative aspects of uncertainty evaluation which have not been explicitly dealt with in the GUM. It is another top down MU approach which studies the overall method performance, i.e. looking at the probability distribution functions of the uncertainty components (budgets) through computer simulation. Another main reason for creating such a supplement is that the traditional GUM method has been found to be tedious in the estimation process, particularly for testing laboratories. This is because unlike calibration and physical measurements which are directly achieved with one or two steps, testing procedures have more steps to be followed and each step might contain a few uncertainty components to be considered. JCGM states in this guidance document that the described Monte Carlo method is a practical alternative to the GUM uncertainty framework, particularly giving value when (a) linearization of the model provides an inadequate representation (e.g. nonlinear model), or (b) the probability density function (PDF) for the output quantity departs appreciably from a Gaussian (Normal) distribution, or a scaled and shifted Student s t -distribution, e.g. due to marked asymmetry. In case (a), the estimate of the output quantity and the associated standard uncertainty provided by the GUM uncertainty framework might be unreliable, whilst in case (b), unrealistic coverage intervals (a generalization of expanded uncertainty in the GUM uncertainty framework with a coverage factor of 2) might be the outcome. 1

The Monte Carlo method what and how? Monte Carlo simulations are named after the Monte Carlo Casino, a famous gambling hot spot in Monaco, since chance and random outcomes are central to the modeling technique, much as they are to games like roulette, dice and slot machines. The technique was first developed by a mathematician Stanislaw Ulam. A simplified definition is that Monte Carlo (MC) methods are methods for simulation of mathematical models in which random numbers are involved. The MC methods are called stochastic techniques. The word stochastic is an adjective in English that describes something that was randomly determined. We can find these MC methods being applied in everything from economic forecasting to nuclear physics to regulating the flow of traffic. Hence, the Monte Carlo method is a technique which involves using random numbers as inputs and identified probability functions to solve problems. Before we discuss the Monte Carlo simulation (MCS) further, let s understand what a computer simulation is all about. Computer simulation uses computer models to imitate real life or make predictions of an event. If we have a model with some mathematical equations, we can use a spreadsheet such as Excel or some statistical software like Matlab or Minitab to insert a certain number of randomly selected input parameters (like standard deviation) to give a set of outputs or response variables. Such model is usually deterministic, meaning that we get the same output results no matter how many times we re-calculate them. A Monte Carlo method can thus be loosely described as a statistical method used in simulation of data, whilst a simulation is defined to be a method that utilizes sequences of large number of random numbers as data. This method is often used when the model is complex, nonlinear, or involves more than few uncertainty parameters. A simulation using a computer can typically involve over 10,000 evaluations or more of the model to provide approximate solutions to the population of interest. By doing so, MCS can be a good way to establish the validity of a statistical formula at its basic. This can usefully complement the theoretical approach of traditional statistics. In particular, an expression for the estimate of the population variance can be established from theoretical considerations. MCS can be effective in comparing actual and theoretical values for the estimate of the population variance. 2

How does MCS apply to our laboratory measurements? In short, a measurement model can be described in Figure 1 below. Figure 1 : Model of a measurement process Input quantities X 1,, X n Model Y = f(x 1,, X n) Output quantity Y Each X n is characterized by a probability distribution function (PDF) and the output PDF will be dependent on the measurement model, as shown schematically in Figure 2: Figure 2: An example of three uncertainty budgets with known PDF X 1 Y X 2 Y = f(x 1,X 2,X 3) X 3 In the above model, the contributors X 1, X 2 and X 3 can be of any probability distribution functions (PDF) (e.g. normal, rectangular, triangular, Poisson, etc) and the deterministic model has a function of these contributors in terms of an equation, giving an output Y with a PDF resulting from the inputs. This PDF for the output quantity describes the knowledge of that quantity, based on the knowledge of the input quantities, as described by the PDFs assigned to them. Once the PDF for the output quantity is available, that quantity can be summarized by its expectation, taken as an estimate of the quantity, and its standard deviation, taken as the standard uncertainty associated with the estimate. Furthermore, the PDF can be used to obtain a coverage interval, corresponding to a stipulated coverage probability, for the output quantity. 3

We make use of computers equipped with various PDF random number generators to create thousands or tens of thousands of data to fit the model equation. Readers who are familiar with the Eurachem/CITAC Guide CG4 [3] on measurement uncertainty for testing can look up its Appendix E3 with a simple Excel spreadsheet examples illustrated. It presents the MCS technique with detailed step-by-step manner. In this case, the results obtained by both GUM and MC approaches have been shown quite similar. How to use MS Excel spreadsheet to carry out a Monte Carlo Simulation? A statistical software to generate such vast number of random numbers, such as Matlab, based on a given probability distribution function can be employed. An Excel spreadsheet, which has also a random number generator function =RAND(), can also be used to carry out such calculation although it has a limited number of inputs, with a maximum of 48576 rows. However, for practical purposes, these inputs are already good enough to display the probability distribution in question. For example, given a mean of 35.5 and its standard deviation of 2.3 under the normal distribution function, some 48574 random data based on the Excel function =NORMINV(RAND(),35.5,2.3) can be generated as shown in Table 1: Table 1: Random data generated under normal distribution Series Data 1 33.1849 2 38.6867 3 34.9856 4 34.9793 ~ ~ 48572 38.1210 48573 29.5783 48574 34.1466 A histogram (Figure 3) is then generated using the Excel Data Analysis tool tab to calculate the frequencies of occurrence as shown in Table 2: 4

Table 2: The histogram table based on the data from Table 1 Bin Frequency Bin Frequency Bin Frequency Bin Frequency 26.5 3 31.5 743 36.5 3960 41.5 207 27.0 4 32.0 1061 37.0 3595 42.0 118 27.5 7 32.5 1649 37.5 3134 42.5 67 28.0 7 33.0 2092 38.0 2587 43.0 33 28.5 37 33.5 2630 38.5 2113 43.5 15 29.0 57 34.0 3129 39.0 1555 44.0 7 29.5 100 34.5 3637 39.5 1135 45.5 6 30.0 184 35.0 3806 40.0 776 More 1 30.5 315 35.5 4295 40.5 512 31.0 524 36.0 4185 41.0 288 Figure 3: A histogram chart generated from data in Table 2 5000 4000 Frequency 3000 2000 1000 Frequency 0 26.5 28.5 30.5 32.5 34.5 36.5 38.5 40.5 42.5 45.5 Bin For a rectangular probably function where the uncertainties are given by maximum bound within which all values are equally probable, we also can use the Excel spreadsheet to plot its data spread as illustrated below. For example, for a given mean of 100 with an upper bound limit (UL) of 104 and a lower bound limit (LL) of 96 (i.e. uncertainty of +4), the function =96+(104-96)*RAND() can be used to generate thousands of random figures bounded by 96 and 104, as shown in the following chart which has accumulated some 1800 data: 5

Table 3: Random data generated under rectangular distribution Series Data 1 96.077 2 103.419 3 100.317 4 96.077 ~ ~ 1797 101.021 1798 99.421 1799 99.567 1800 99.121 Figure 4: A chart showing the rectangular distribution data 106.000 104.000 102.000 100.000 98.000 96.000 94.000 0 500 1000 1500 2000 Conclusion The Monte Carlo method uses computer to generate huge random numbers of stated distribution which allows to estimate the population mean values of the input quantities for the calculation of its final output quantity. It is a method for a predictive uncertainty which is iteratively evaluating a deterministic model using sets of random numbers as inputs. This method is often used when the model is complex, nonlinear, or involves more than just a couple uncertainty components. A simulation can typically involve over 10,000 evaluations of the model, a task which in the past was only practical using super computers. Today, any desktop computer can do the job easily. 6

References [1] JCGM 101 Evaluation of measurement data Supplement 1 to the Guide to the expression of uncertainty in measurement Propagation of distributions using a Monte Carlo method (ISO/IEC Guide 98-3-1) [2] JCGM 100 Evaluation of measurement data Guide to the expression of uncertainty in measurement (ISO/IEC Guide 98-3) [3] Eurachem/CITAC Guide CG4 Quantifying uncertainty in analytical measurement (third edition) 7