Ошибка выявленная неточностью подсчетов называется

From Wikipedia, the free encyclopedia

From Wikipedia, the free encyclopedia

«Systematic bias» redirects here. For the sociological and organizational phenomenon, see Systemic bias.

Observational error (or measurement error) is the difference between a measured value of a quantity and its true value.[1] In statistics, an error is not necessarily a «mistake». Variability is an inherent part of the results of measurements and of the measurement process.

Measurement errors can be divided into two components: random and systematic.[2]
Random errors are errors in measurement that lead to measurable values being inconsistent when repeated measurements of a constant attribute or quantity are taken. Systematic errors are errors that are not determined by chance but are introduced by repeatable processes inherent to the system.[3] Systematic error may also refer to an error with a non-zero mean, the effect of which is not reduced when observations are averaged.[citation needed]

Measurement errors can be summarized in terms of accuracy and precision.
Measurement error should not be confused with measurement uncertainty.

Science and experiments[edit]

When either randomness or uncertainty modeled by probability theory is attributed to such errors, they are «errors» in the sense in which that term is used in statistics; see errors and residuals in statistics.

Every time we repeat a measurement with a sensitive instrument, we obtain slightly different results. The common statistical model used is that the error has two additive parts:

  1. Systematic error which always occurs, with the same value, when we use the instrument in the same way and in the same case.
  2. Random error which may vary from observation to another.

Systematic error is sometimes called statistical bias. It may often be reduced with standardized procedures. Part of the learning process in the various sciences is learning how to use standard instruments and protocols so as to minimize systematic error.

Random error (or random variation) is due to factors that cannot or will not be controlled. One possible reason to forgo controlling for these random errors is that it may be too expensive to control them each time the experiment is conducted or the measurements are made. Other reasons may be that whatever we are trying to measure is changing in time (see dynamic models), or is fundamentally probabilistic (as is the case in quantum mechanics — see Measurement in quantum mechanics). Random error often occurs when instruments are pushed to the extremes of their operating limits. For example, it is common for digital balances to exhibit random error in their least significant digit. Three measurements of a single object might read something like 0.9111g, 0.9110g, and 0.9112g.

Characterization[edit]

Measurement errors can be divided into two components: random error and systematic error.[2]

Random error is always present in a measurement. It is caused by inherently unpredictable fluctuations in the readings of a measurement apparatus or in the experimenter’s interpretation of the instrumental reading. Random errors show up as different results for ostensibly the same repeated measurement. They can be estimated by comparing multiple measurements and reduced by averaging multiple measurements.

Systematic error is predictable and typically constant or proportional to the true value. If the cause of the systematic error can be identified, then it usually can be eliminated. Systematic errors are caused by imperfect calibration of measurement instruments or imperfect methods of observation, or interference of the environment with the measurement process, and always affect the results of an experiment in a predictable direction. Incorrect zeroing of an instrument leading to a zero error is an example of systematic error in instrumentation.

The Performance Test Standard PTC 19.1-2005 “Test Uncertainty”, published by the American Society of Mechanical Engineers (ASME), discusses systematic and random errors in considerable detail. In fact, it conceptualizes its basic uncertainty categories in these terms.

Random error can be caused by unpredictable fluctuations in the readings of a measurement apparatus, or in the experimenter’s interpretation of the instrumental reading; these fluctuations may be in part due to interference of the environment with the measurement process. The concept of random error is closely related to the concept of precision. The higher the precision of a measurement instrument, the smaller the variability (standard deviation) of the fluctuations in its readings.

Sources[edit]

Sources of systematic error[edit]

Imperfect calibration[edit]

Sources of systematic error may be imperfect calibration of measurement instruments (zero error), changes in the environment which interfere with the measurement process and sometimes imperfect methods of observation can be either zero error or percentage error. If you consider an experimenter taking a reading of the time period of a pendulum swinging past a fiducial marker: If their stop-watch or timer starts with 1 second on the clock then all of their results will be off by 1 second (zero error). If the experimenter repeats this experiment twenty times (starting at 1 second each time), then there will be a percentage error in the calculated average of their results; the final result will be slightly larger than the true period.

Distance measured by radar will be systematically overestimated if the slight slowing down of the waves in air is not accounted for. Incorrect zeroing of an instrument leading to a zero error is an example of systematic error in instrumentation.

Systematic errors may also be present in the result of an estimate based upon a mathematical model or physical law. For instance, the estimated oscillation frequency of a pendulum will be systematically in error if slight movement of the support is not accounted for.

Quantity[edit]

Systematic errors can be either constant, or related (e.g. proportional or a percentage) to the actual value of the measured quantity, or even to the value of a different quantity (the reading of a ruler can be affected by environmental temperature). When it is constant, it is simply due to incorrect zeroing of the instrument. When it is not constant, it can change its sign. For instance, if a thermometer is affected by a proportional systematic error equal to 2% of the actual temperature, and the actual temperature is 200°, 0°, or −100°, the measured temperature will be 204° (systematic error = +4°), 0° (null systematic error) or −102° (systematic error = −2°), respectively. Thus the temperature will be overestimated when it will be above zero and underestimated when it will be below zero.

Drift[edit]

Systematic errors which change during an experiment (drift) are easier to detect. Measurements indicate trends with time rather than varying randomly about a mean. Drift is evident if a measurement of a constant quantity is repeated several times and the measurements drift one way during the experiment. If the next measurement is higher than the previous measurement as may occur if an instrument becomes warmer during the experiment then the measured quantity is variable and it is possible to detect a drift by checking the zero reading during the experiment as well as at the start of the experiment (indeed, the zero reading is a measurement of a constant quantity). If the zero reading is consistently above or below zero, a systematic error is present. If this cannot be eliminated, potentially by resetting the instrument immediately before the experiment then it needs to be allowed by subtracting its (possibly time-varying) value from the readings, and by taking it into account while assessing the accuracy of the measurement.

If no pattern in a series of repeated measurements is evident, the presence of fixed systematic errors can only be found if the measurements are checked, either by measuring a known quantity or by comparing the readings with readings made using a different apparatus, known to be more accurate. For example, if you think of the timing of a pendulum using an accurate stopwatch several times you are given readings randomly distributed about the mean. Hopings systematic error is present if the stopwatch is checked against the ‘speaking clock’ of the telephone system and found to be running slow or fast. Clearly, the pendulum timings need to be corrected according to how fast or slow the stopwatch was found to be running.

Measuring instruments such as ammeters and voltmeters need to be checked periodically against known standards.

Systematic errors can also be detected by measuring already known quantities. For example, a spectrometer fitted with a diffraction grating may be checked by using it to measure the wavelength of the D-lines of the sodium electromagnetic spectrum which are at 600 nm and 589.6 nm. The measurements may be used to determine the number of lines per millimetre of the diffraction grating, which can then be used to measure the wavelength of any other spectral line.

Constant systematic errors are very difficult to deal with as their effects are only observable if they can be removed. Such errors cannot be removed by repeating measurements or averaging large numbers of results. A common method to remove systematic error is through calibration of the measurement instrument.

Sources of random error[edit]

The random or stochastic error in a measurement is the error that is random from one measurement to the next. Stochastic errors tend to be normally distributed when the stochastic error is the sum of many independent random errors because of the central limit theorem. Stochastic errors added to a regression equation account for the variation in Y that cannot be explained by the included Xs.

Surveys[edit]

The term «observational error» is also sometimes used to refer to response errors and some other types of non-sampling error.[1] In survey-type situations, these errors can be mistakes in the collection of data, including both the incorrect recording of a response and the correct recording of a respondent’s inaccurate response. These sources of non-sampling error are discussed in Salant and Dillman (1994) and Bland and Altman (1996).[4][5]

These errors can be random or systematic. Random errors are caused by unintended mistakes by respondents, interviewers and/or coders. Systematic error can occur if there is a systematic reaction of the respondents to the method used to formulate the survey question. Thus, the exact formulation of a survey question is crucial, since it affects the level of measurement error.[6] Different tools are available for the researchers to help them decide about this exact formulation of their questions, for instance estimating the quality of a question using MTMM experiments. This information about the quality can also be used in order to correct for measurement error.[7][8]

Effect on regression analysis[edit]

If the dependent variable in a regression is measured with error, regression analysis and associated hypothesis testing are unaffected, except that the R2 will be lower than it would be with perfect measurement.

However, if one or more independent variables is measured with error, then the regression coefficients and standard hypothesis tests are invalid.[9]: p. 187  This is known as attenuation bias.[10]

See also[edit]

  • Bias (statistics)
  • Cognitive bias
  • Correction for measurement error (for Pearson correlations)
  • Errors and residuals in statistics
  • Error
  • Replication (statistics)
  • Statistical theory
  • Metrology
  • Regression dilution
  • Test method
  • Propagation of uncertainty
  • Instrument error
  • Measurement uncertainty
  • Errors-in-variables models
  • Systemic bias

References[edit]

  1. ^ a b Dodge, Y. (2003) The Oxford Dictionary of Statistical Terms, OUP. ISBN 978-0-19-920613-1
  2. ^ a b John Robert Taylor (1999). An Introduction to Error Analysis: The Study of Uncertainties in Physical Measurements. University Science Books. p. 94, §4.1. ISBN 978-0-935702-75-0.
  3. ^ «Systematic error». Merriam-webster.com. Retrieved 2016-09-10.
  4. ^ Salant, P.; Dillman, D. A. (1994). How to conduct your survey. New York: John Wiley & Sons. ISBN 0-471-01273-4.
  5. ^ Bland, J. Martin; Altman, Douglas G. (1996). «Statistics Notes: Measurement Error». BMJ. 313 (7059): 744. doi:10.1136/bmj.313.7059.744. PMC 2352101. PMID 8819450.
  6. ^ Saris, W. E.; Gallhofer, I. N. (2014). Design, Evaluation and Analysis of Questionnaires for Survey Research (Second ed.). Hoboken: Wiley. ISBN 978-1-118-63461-5.
  7. ^ DeCastellarnau, A. and Saris, W. E. (2014). A simple procedure to correct for measurement errors in survey research. European Social Survey Education Net (ESS EduNet). Available at: http://essedunet.nsd.uib.no/cms/topics/measurement Archived 2019-09-15 at the Wayback Machine
  8. ^ Saris, W. E.; Revilla, M. (2015). «Correction for measurement errors in survey research: necessary and possible» (PDF). Social Indicators Research. 127 (3): 1005–1020. doi:10.1007/s11205-015-1002-x. hdl:10230/28341. S2CID 146550566.
  9. ^ Hayashi, Fumio (2000). Econometrics. Princeton University Press. ISBN 978-0-691-01018-2.
  10. ^ Angrist, Joshua David; Pischke, Jörn-Steffen (2015). Mastering ‘metrics : the path from cause to effect. Princeton, New Jersey. p. 221. ISBN 978-0-691-15283-7. OCLC 877846199. The bias generated by this sort of measurement error in regressors is called attenuation bias.

Further reading[edit]

  • Cochran, W. G. (1968). «Errors of Measurement in Statistics». Technometrics. 10 (4): 637–666. doi:10.2307/1267450. JSTOR 1267450.

From Wikipedia, the free encyclopedia

«Systematic bias» redirects here. For the sociological and organizational phenomenon, see Systemic bias.

Observational error (or measurement error) is the difference between a measured value of a quantity and its true value.[1] In statistics, an error is not necessarily a «mistake». Variability is an inherent part of the results of measurements and of the measurement process.

Measurement errors can be divided into two components: random and systematic.[2]
Random errors are errors in measurement that lead to measurable values being inconsistent when repeated measurements of a constant attribute or quantity are taken. Systematic errors are errors that are not determined by chance but are introduced by repeatable processes inherent to the system.[3] Systematic error may also refer to an error with a non-zero mean, the effect of which is not reduced when observations are averaged.[citation needed]

Measurement errors can be summarized in terms of accuracy and precision.
Measurement error should not be confused with measurement uncertainty.

Science and experiments[edit]

When either randomness or uncertainty modeled by probability theory is attributed to such errors, they are «errors» in the sense in which that term is used in statistics; see errors and residuals in statistics.

Every time we repeat a measurement with a sensitive instrument, we obtain slightly different results. The common statistical model used is that the error has two additive parts:

  1. Systematic error which always occurs, with the same value, when we use the instrument in the same way and in the same case.
  2. Random error which may vary from observation to another.

Systematic error is sometimes called statistical bias. It may often be reduced with standardized procedures. Part of the learning process in the various sciences is learning how to use standard instruments and protocols so as to minimize systematic error.

Random error (or random variation) is due to factors that cannot or will not be controlled. One possible reason to forgo controlling for these random errors is that it may be too expensive to control them each time the experiment is conducted or the measurements are made. Other reasons may be that whatever we are trying to measure is changing in time (see dynamic models), or is fundamentally probabilistic (as is the case in quantum mechanics — see Measurement in quantum mechanics). Random error often occurs when instruments are pushed to the extremes of their operating limits. For example, it is common for digital balances to exhibit random error in their least significant digit. Three measurements of a single object might read something like 0.9111g, 0.9110g, and 0.9112g.

Characterization[edit]

Measurement errors can be divided into two components: random error and systematic error.[2]

Random error is always present in a measurement. It is caused by inherently unpredictable fluctuations in the readings of a measurement apparatus or in the experimenter’s interpretation of the instrumental reading. Random errors show up as different results for ostensibly the same repeated measurement. They can be estimated by comparing multiple measurements and reduced by averaging multiple measurements.

Systematic error is predictable and typically constant or proportional to the true value. If the cause of the systematic error can be identified, then it usually can be eliminated. Systematic errors are caused by imperfect calibration of measurement instruments or imperfect methods of observation, or interference of the environment with the measurement process, and always affect the results of an experiment in a predictable direction. Incorrect zeroing of an instrument leading to a zero error is an example of systematic error in instrumentation.

The Performance Test Standard PTC 19.1-2005 “Test Uncertainty”, published by the American Society of Mechanical Engineers (ASME), discusses systematic and random errors in considerable detail. In fact, it conceptualizes its basic uncertainty categories in these terms.

Random error can be caused by unpredictable fluctuations in the readings of a measurement apparatus, or in the experimenter’s interpretation of the instrumental reading; these fluctuations may be in part due to interference of the environment with the measurement process. The concept of random error is closely related to the concept of precision. The higher the precision of a measurement instrument, the smaller the variability (standard deviation) of the fluctuations in its readings.

Sources[edit]

Sources of systematic error[edit]

Imperfect calibration[edit]

Sources of systematic error may be imperfect calibration of measurement instruments (zero error), changes in the environment which interfere with the measurement process and sometimes imperfect methods of observation can be either zero error or percentage error. If you consider an experimenter taking a reading of the time period of a pendulum swinging past a fiducial marker: If their stop-watch or timer starts with 1 second on the clock then all of their results will be off by 1 second (zero error). If the experimenter repeats this experiment twenty times (starting at 1 second each time), then there will be a percentage error in the calculated average of their results; the final result will be slightly larger than the true period.

Distance measured by radar will be systematically overestimated if the slight slowing down of the waves in air is not accounted for. Incorrect zeroing of an instrument leading to a zero error is an example of systematic error in instrumentation.

Systematic errors may also be present in the result of an estimate based upon a mathematical model or physical law. For instance, the estimated oscillation frequency of a pendulum will be systematically in error if slight movement of the support is not accounted for.

Quantity[edit]

Systematic errors can be either constant, or related (e.g. proportional or a percentage) to the actual value of the measured quantity, or even to the value of a different quantity (the reading of a ruler can be affected by environmental temperature). When it is constant, it is simply due to incorrect zeroing of the instrument. When it is not constant, it can change its sign. For instance, if a thermometer is affected by a proportional systematic error equal to 2% of the actual temperature, and the actual temperature is 200°, 0°, or −100°, the measured temperature will be 204° (systematic error = +4°), 0° (null systematic error) or −102° (systematic error = −2°), respectively. Thus the temperature will be overestimated when it will be above zero and underestimated when it will be below zero.

Drift[edit]

Systematic errors which change during an experiment (drift) are easier to detect. Measurements indicate trends with time rather than varying randomly about a mean. Drift is evident if a measurement of a constant quantity is repeated several times and the measurements drift one way during the experiment. If the next measurement is higher than the previous measurement as may occur if an instrument becomes warmer during the experiment then the measured quantity is variable and it is possible to detect a drift by checking the zero reading during the experiment as well as at the start of the experiment (indeed, the zero reading is a measurement of a constant quantity). If the zero reading is consistently above or below zero, a systematic error is present. If this cannot be eliminated, potentially by resetting the instrument immediately before the experiment then it needs to be allowed by subtracting its (possibly time-varying) value from the readings, and by taking it into account while assessing the accuracy of the measurement.

If no pattern in a series of repeated measurements is evident, the presence of fixed systematic errors can only be found if the measurements are checked, either by measuring a known quantity or by comparing the readings with readings made using a different apparatus, known to be more accurate. For example, if you think of the timing of a pendulum using an accurate stopwatch several times you are given readings randomly distributed about the mean. Hopings systematic error is present if the stopwatch is checked against the ‘speaking clock’ of the telephone system and found to be running slow or fast. Clearly, the pendulum timings need to be corrected according to how fast or slow the stopwatch was found to be running.

Measuring instruments such as ammeters and voltmeters need to be checked periodically against known standards.

Systematic errors can also be detected by measuring already known quantities. For example, a spectrometer fitted with a diffraction grating may be checked by using it to measure the wavelength of the D-lines of the sodium electromagnetic spectrum which are at 600 nm and 589.6 nm. The measurements may be used to determine the number of lines per millimetre of the diffraction grating, which can then be used to measure the wavelength of any other spectral line.

Constant systematic errors are very difficult to deal with as their effects are only observable if they can be removed. Such errors cannot be removed by repeating measurements or averaging large numbers of results. A common method to remove systematic error is through calibration of the measurement instrument.

Sources of random error[edit]

The random or stochastic error in a measurement is the error that is random from one measurement to the next. Stochastic errors tend to be normally distributed when the stochastic error is the sum of many independent random errors because of the central limit theorem. Stochastic errors added to a regression equation account for the variation in Y that cannot be explained by the included Xs.

Surveys[edit]

The term «observational error» is also sometimes used to refer to response errors and some other types of non-sampling error.[1] In survey-type situations, these errors can be mistakes in the collection of data, including both the incorrect recording of a response and the correct recording of a respondent’s inaccurate response. These sources of non-sampling error are discussed in Salant and Dillman (1994) and Bland and Altman (1996).[4][5]

These errors can be random or systematic. Random errors are caused by unintended mistakes by respondents, interviewers and/or coders. Systematic error can occur if there is a systematic reaction of the respondents to the method used to formulate the survey question. Thus, the exact formulation of a survey question is crucial, since it affects the level of measurement error.[6] Different tools are available for the researchers to help them decide about this exact formulation of their questions, for instance estimating the quality of a question using MTMM experiments. This information about the quality can also be used in order to correct for measurement error.[7][8]

Effect on regression analysis[edit]

If the dependent variable in a regression is measured with error, regression analysis and associated hypothesis testing are unaffected, except that the R2 will be lower than it would be with perfect measurement.

However, if one or more independent variables is measured with error, then the regression coefficients and standard hypothesis tests are invalid.[9]: p. 187  This is known as attenuation bias.[10]

See also[edit]

  • Bias (statistics)
  • Cognitive bias
  • Correction for measurement error (for Pearson correlations)
  • Errors and residuals in statistics
  • Error
  • Replication (statistics)
  • Statistical theory
  • Metrology
  • Regression dilution
  • Test method
  • Propagation of uncertainty
  • Instrument error
  • Measurement uncertainty
  • Errors-in-variables models
  • Systemic bias

References[edit]

  1. ^ a b Dodge, Y. (2003) The Oxford Dictionary of Statistical Terms, OUP. ISBN 978-0-19-920613-1
  2. ^ a b John Robert Taylor (1999). An Introduction to Error Analysis: The Study of Uncertainties in Physical Measurements. University Science Books. p. 94, §4.1. ISBN 978-0-935702-75-0.
  3. ^ «Systematic error». Merriam-webster.com. Retrieved 2016-09-10.
  4. ^ Salant, P.; Dillman, D. A. (1994). How to conduct your survey. New York: John Wiley & Sons. ISBN 0-471-01273-4.
  5. ^ Bland, J. Martin; Altman, Douglas G. (1996). «Statistics Notes: Measurement Error». BMJ. 313 (7059): 744. doi:10.1136/bmj.313.7059.744. PMC 2352101. PMID 8819450.
  6. ^ Saris, W. E.; Gallhofer, I. N. (2014). Design, Evaluation and Analysis of Questionnaires for Survey Research (Second ed.). Hoboken: Wiley. ISBN 978-1-118-63461-5.
  7. ^ DeCastellarnau, A. and Saris, W. E. (2014). A simple procedure to correct for measurement errors in survey research. European Social Survey Education Net (ESS EduNet). Available at: http://essedunet.nsd.uib.no/cms/topics/measurement Archived 2019-09-15 at the Wayback Machine
  8. ^ Saris, W. E.; Revilla, M. (2015). «Correction for measurement errors in survey research: necessary and possible» (PDF). Social Indicators Research. 127 (3): 1005–1020. doi:10.1007/s11205-015-1002-x. hdl:10230/28341. S2CID 146550566.
  9. ^ Hayashi, Fumio (2000). Econometrics. Princeton University Press. ISBN 978-0-691-01018-2.
  10. ^ Angrist, Joshua David; Pischke, Jörn-Steffen (2015). Mastering ‘metrics : the path from cause to effect. Princeton, New Jersey. p. 221. ISBN 978-0-691-15283-7. OCLC 877846199. The bias generated by this sort of measurement error in regressors is called attenuation bias.

Further reading[edit]

  • Cochran, W. G. (1968). «Errors of Measurement in Statistics». Technometrics. 10 (4): 637–666. doi:10.2307/1267450. JSTOR 1267450.

Материал из MachineLearning.

Перейти к: навигация, поиск

Содержание

  • 1 Введение
    • 1.1 Постановка вопроса. Виды погрешностей
  • 2 Виды мер точности
  • 3 Предельные погрешности
  • 4 Погрешности округлений при представлении чисел в компьютере
  • 5 Погрешности арифметических операций
  • 6 Погрешности вычисления функций
  • 7 Числовые примеры
  • 8 Список литературы
  • 9 См. также

Введение

Постановка вопроса. Виды погрешностей

Процесс исследования исходного объекта методом математического моделирования и вычислительного эксперимента неизбежно носит приближенный характер, так как на каждом этапе вносятся погрешности. Построение математической модели связано с упрощением исходного явления, недостаточно точным заданием коэффициентов уравнения и других входных данных. По отношению к численному методу, реализующему данную математическую модель, указанные погрешности являются неустранимыми, поскольку они неизбежны в рамках данной модели.

При переходе от математической модели к численному методу возникают погрешности, называемые погрешностями метода. Они связаны с тем, что всякий численный метод воспроизводит исходную математическую модель приближенно. Наиболее типичными погрешностями метода являются погрешность дискретизации и погрешность округления.
При построении численного метода в качестве аналога исходной математической задачи обычно рассматривается её дискретная модель. Разность решений дискретизированной задачи и исходной называется погрешностью дискретизации. Обычно дискретная модель зависит от некоторого параметра (или их множества) дискретизации, при стремлении которого к нулю должна стремиться к нулю и погрешность дискретизации.
Дискретная модель представляет собой систему большого числа алгебраических уравнений. Для её решения используется тот или иной численный алгоритм. Входные данные этой системы, а именно коэффициенты и правые части, задаются в ЭВМ не точно, а с округлением. В процессе работы алгоритма погрешности округления обычно накапливаются, и в результате, решение, полученное на ЭВМ, будет отличаться от точного решения дискретизированной задачи. Результирующая погрешность называется погрешностью округления (вычислительной погрешностью). Величина этой погрешности определяется двумя факторами: точностью представления вещественных чисел в ЭВМ и чувствительностью данного алгоритма к погрешностям округления.

Итак, следует различать погрешности модели, дискретизации и округления. В вопросе преобладания какой-либо погрешности ответ неоднозначен. В общем случае нужно стремиться, чтобы все погрешности имели один и тот же порядок. Например, нецелесообразно пользоваться разностными схемами, имеющими точность 10−6, если коэффициенты исходных уравнений задаются с точностью 10−2.

Виды мер точности

Мерой точности вычислений являются абсолютные и относительные погрешности. Абсолютная погрешность определяется формулой

Delta(tilde a)=|tilde a-a|,

где tilde a – приближение к точному значению a.
Относительная погрешность определяется формулой

delta(tilde a)=frac{|tilde a-a|}{a}.

Относительная погрешность часто выражается в процентах. Абсолютная и относительная погрешности тесно связаны с понятием верных значащих цифр. Значащими цифрами числа называют все цифры в его записи, начиная с первой ненулевой цифры слева. Например, число 0,000129 имеет три значащих цифры. Значащая цифра называется верной, если абсолютная погрешность числа не превышает половины веса разряда, соответствующего этой цифре. Например, tilde a=9348, абсолютная погрешность Delta(tilde a)=15. Записывая число в виде

9348=9cdot10^3+3cdot10^2+4cdot10^1+8cdot10^0,

имеем 0,5cdot10^1<Delta(tilde a)<0,5cdot10^2, следовательно, число имеет две верных значащих цифр (9 и 3).

В общем случае абсолютная погрешность должна удовлетворять следующему неравенству:

Delta(tilde a)<0,5cdot10^{m-n+1} ,

где m — порядок (вес) старшей цифры, n — количество верных значащих цифр.
В рассматриваемом примере Delta(tilde a)le0,5cdot10^{3-2+1}le0,5cdot10^2=50.

Относительная погрешность связана с количеством верных цифр приближенного числа соотношением:

delta(tilde a)lefrac{Delta(tilde a)}{alpha_m}10^mlefrac{10^{m-n+1}}{alpha_m10^m}lefrac{1}{alpha_m10^{n-1}},

где alpha_m — старшая значащая цифра числа.

Для двоичного представления чисел имеем delta(tilde a)le2^{-n}.

Тот факт, что число tilde a является приближенным значением числа a с абсолютной погрешностью Delta(tilde a), записывают в виде

a=tilde apmDelta(tilde a),

причем числа tilde a и Delta(tilde a) записываются с одинаковым количеством знаков после запятой, например, a=2,347pm0,002 или a=2,347pm2cdot10^{-3}.

Запись вида

a=tilde a(1pmdelta(tilde a))

означает, что число tilde a является приближенным значение числа a с относительной погрешностью delta(tilde a).

Так как точное решение задачи как правило неизвестно, то погрешности приходится оценивать через исходные данные и особенности алгоритма. Если оценка может быть вычислена до решения задачи, то она называется априорной. Если оценка вычисляется после получения приближенного решения задачи, то она называется апостериорной.

Очень часто степень точности решения задачи характеризуется некоторыми косвенными вспомогательными величинами. Например точность решения системы алгебраических уравнений

AX=F

характеризуется невязкой

R=F-Atilde X,

где tilde X — приближенное решение системы.
Причём невязка достаточно сложным образом связана с погрешностью решения Delta(X)=tilde X-X, причём если невязка мала, то погрешность может быть значительной.

Предельные погрешности

Пусть искомая величина a является функцией параметров t_1, ldots , t_n in Omega, qquad a* — приближенное значение a. Тогда предельной абсолютной погрешностью называется величина

D(a^*) = suplimits_{(t_1, ldots ,t_n) in Omega } left|{a(t_1, ldots ,t_n) - a^*}right| ,

Предельной относительной погрешностью называется величина D(a*)/| a*|.

Пусть  left|{t_j - t_j^*}right| le Delta (t_j^* ), qquad j = 1 div n — приближенное значение a^* = a(t_1^*, ldots ,t_n^* ). Предполагаем, что a — непрерывно дифференцируемая функция своих аргументов. Тогда, по формуле Лагранжа,

a(t_1, ldots ,t_n) - a^* = sumlimits_{j = 1}^n gamma_j (alpha )(t_j - t_j^*),

где gamma_j (alpha ) = a^{prime}_{t_j}(t_1^* + alpha (t_1 - t_1^*), ldots ,t_n^* + alpha (t_n - t_n^*)), qquad 0 le alpha le 1 .

Отсюда

left|{a(t_1, ldots ,t_n) - a^*}right| le D_1 (a^*) = sumlimits_{j = 1}^n b_j Delta (t_j^*),

где b_j = suplimits_Omega left|{a^{prime}_{t_j}(t_1, ldots ,t_n)}right|.

Можно показать, что при малых rho = sqrt{{(Delta (t_1^* ))}^2 + ldots + {(Delta (t_n^* ))}^2 } эта оценка не может быть существенно улучшена. На практике иногда пользуются грубой (линейной) оценкой

left|{a(t_1, ldots ,t_n) - a^*}right| le D_2 (a^*),

где D_2 (a^*) = sumlimits_{j = 1} left|{gamma_j (0)}right| Delta (t^*) .

Несложно показать, что:

  1. Delta ( pm t_1^* pm , ldots , pm t_n^*) = Delta (t_1^* ) + ldots + Delta (t_n^* ) — предельная погрешность суммы или разности равна сумме предельных погрешностей.
  2. delta (t_1^* cdots t_m^* cdot d_1^{* - 1} cdots d_m^{* - 1} ) = delta (t_1^* ) + ldots + delta (t_m^*) + delta (d_1^*) + ldots + delta (d_n^*) — предельная относительная погрешность произведения или частного приближенного равна сумме предельных относительных погрешностей.

Погрешности округлений при представлении чисел в компьютере

Одним из основных источников вычислительных погрешностей является приближенное представление чисел в компьютере, обусловленное конечностью разрядной сетки (см. Международный стандарт представления чисел с плавающей точкой в ЭВМ). Число a, не представимое в компьютере, подвергается округлению, т. е. заменяется близким числом tilde a, представимым в компьютере точно.
Найдем границу относительной погрешности представления числа с плавающей точкой. Допустим, что применяется простейшее округление – отбрасывание всех разрядов числа, выходящих за пределы разрядной сетки. Система счисления – двоичная. Пусть надо записать число, представляющее бесконечную двоичную дробь

a=underbrace{pm2^p}_{order}underbrace{left(frac{a_1}{2}+frac{a_2}{2^2}+dots+frac{a_t}{2^t}+frac{a_{t+1}}{2^{t+1}}+dotsright)}_{mantissa},

где a_j={0\1, qquad (j=1,2,...) — цифры мантиссы.
Пусть под запись мантиссы отводится t двоичных разрядов. Отбрасывая лишние разряды, получим округлённое число

tilde a=pm2^pleft(frac{a_1}{2}+frac{a_2}{2^2}+dots+frac{a_t}{2^t}right).

Абсолютная погрешность округления в этом случае равна

a-tilde a=pm2^pleft(frac{a_{t+1}}{2^{t+1}}+frac{a_{t+2}}{2^{t+2}}+dotsright).

Наибольшая погрешность будет в случае a_{t+1}=1, qquad a_{t+2}=1,, тогда

|a-tilde a|lepm2^pfrac{1}{2^{t+1}}underbrace{left(1+frac{1}{2}+frac{1}{2^2}+dotsright)}_{=2}=2^{p-t}.

Т.к. |M|ge0,5, где M — мантисса числа a, то всегда a_1=1. Тогда |a|ge2^pcdot2^{-1}=2^{p-1} и относительная погрешность равна frac{|a-tilde a|}{|a|}le2^{-t+1}. Практически применяют более точные методы округления и погрешность представления чисел равна

( 1 )

frac{|a-tilde a|}{|a|}le2^{-t},

т.е. точность представления чисел определяется разрядностью мантиссы t.
Тогда приближенно представленное в компьютере число можно записать в виде tilde a=a(1pmepsilon), где |epsilon|le2^{-t}«машинный эпсилон» – относительная погрешность представления чисел.

Погрешности арифметических операций

При вычислениях с плавающей точкой операция округления может потребоваться после выполнения любой из арифметических операций. Так умножение или деление двух чисел сводится к умножению или делению мантисс. Так как в общем случае количество разрядов мантисс произведений и частных больше допустимой разрядности мантиссы, то требуется округление мантиссы результатов. При сложении или вычитании чисел с плавающей точкой операнды должны быть предварительно приведены к одному порядку, что осуществляется сдвигом вправо мантиссы числа, имеющего меньший порядок, и увеличением в соответствующее число раз порядка этого числа. Сдвиг мантиссы вправо может привести к потере младших разрядов мантиссы, т.е. появляется погрешность округления.

Округленное в системе с плавающей точкой число, соответствующее точному числу x, обозначается через fl(x) (от англ. floating – плавающий). Выполнение каждой арифметической операции вносит относительную погрешность, не большую, чем погрешность представления чисел с плавающей точкой (1). Верна следующая запись:

fl(abox b)=abox b(1pmepsilon),

где box — любая из арифметических операций, |epsilon|le2^{-t}.

Рассмотрим трансформированные погрешности арифметических операций. Арифметические операции проводятся над приближенными числами, ошибка арифметических операций не учитывается (эту ошибку легко учесть, прибавив ошибку округления соответствующей операции к вычисленной ошибке).

Рассмотрим сложение и вычитание приближенных чисел. Абсолютная погрешность алгебраической суммы нескольких приближенных чисел равна сумме абсолютных погрешностей слагаемых.

Если сумма точных чисел равна

S=a_1+a_2+dots+a_n,

сумма приближенных чисел равна

tilde S=a_1+Delta(a_1)+a_2+Delta(a_2)+dots+a_n+Delta(a_n),

где Delta(a_i), qquad i=1,2,...,n— абсолютные погрешности представления чисел.

Тогда абсолютная погрешность суммы равна

Delta(S)=Delta(a_1)+Delta(a_2)+dots+Delta(a_n).

Относительная погрешность суммы нескольких чисел равна

( 2 )

delta(S)=frac{Delta(S)}{S}=frac{a_1}{S}left(frac{Delta(a_1)}{a_1}right)+frac{a_2}{S}left(frac{Delta(a_2)}{a_2}right)+dots=frac{a_1delta(a_1)+a_2delta(a_2)+dots}{S},

где delta(a_i), qquad i=1,2,...,n — относительные погрешности представления чисел.

Из (2) следует, что относительная погрешность суммы нескольких чисел одного и того же знака заключена между наименьшей и наибольшей из относительных погрешностей слагаемых:

min quad delta(a_k)ledelta(S)le max quad delta(a_k), qquad k=1,2,...,n, quad a_k>0.

При сложении чисел разного знака или вычитании чисел одного знака относительная погрешность может быть очень большой (если числа близки между собой). Так как даже при малых Delta(a_i) величина S может быть очень малой. Поэтому вычислительные алгоритмы необходимо строить таким образом, чтобы избегать вычитания близких чисел.

Необходимо отметить, что погрешности вычислений зависят от порядка вычислений. Далее будет рассмотрен пример сложения трех чисел.

S=x_1+x_2+x_3,
tilde S_1=(x_1+x_2)(1+delta_1),

( 3 )

tilde S=(tilde S_1+x_3)(1+delta_2)=(x_1+x_2)(1+delta_1)(1+delta_2)+x_3(1+delta_2).

При другой последовательности действий погрешность будет другой:

tilde S_1=(x_3+x_2)(1+delta_1),
tilde S=(x_3+x_2)(1+delta_1)(1+delta_2)+x_1(1+delta_2).

Из (3) видно, что результат выполнения некоторого алгоритма, искаженный погрешностями округлений, совпадает с результатом выполнения того же алгоритма, но с неточными исходными данными. Т.е. можно применять обратный анализ: свести влияние погрешностей округления к возмущению исходных данных. Тогда вместо (3) будет следующая запись:

tilde S=tilde x_1+tilde x_2+tilde x_3,

где tilde x_1=x_1(1+delta_1)(1+delta_2), quad tilde x_2=x_2(1+delta_1)(1+delta_2), quad tilde x_3=x_3(1+delta_2).

При умножении и делении приближенных чисел складываются и вычитаются их относительные погрешности.

S=a_1cdot a_2,
tilde S=a_1cdot a_2(1+delta(a_1))(1+delta(a_2))a_1cdot a_2(1+delta(a_1)+delta(a_2)),

с точностью величин второго порядка малости относительно delta.

Тогда delta(S)=delta(a_1)+delta(a_2).

Если S=frac{a_1}{a_2}, то Delta(S)=frac{a_1(1+delta_1)}{a_2(1+delta_2)}-frac{a_1}{a_2}=frac{a_1(delta_1-delta_2)}{a_2(1+delta_2)}approx frac{a_1}{a_2}(delta_1-delta_2), qquad delta(S)  delta_1-delta_2.

При большом числе n арифметических операций можно пользоваться приближенной статистической оценкой погрешности арифметических операций, учитывающей частичную компенсацию погрешностей разных знаков:

delta_Sigma approx delta_{fl} quad sqrt{n},

где delta_Sigma – суммарная погрешность, |delta_{fl}|leepsilon – погрешность выполнения операций с плавающей точкой, epsilon – погрешность представления чисел с плавающей точкой.

Погрешности вычисления функций

Рассмотрим трансформированную погрешность вычисления значений функций.

Абсолютная трансформированная погрешность дифференцируемой функции y=f(x), вызываемая достаточно малой погрешностью аргумента Delta(x), оценивается величиной Delta(y)=|f'(x)|Delta(x).

Если f(x)>0, то delta(y)=frac{|f'(x)|}{f(x)}Delta(x)=left|(ln(f(x)))'right|cdotDelta(x).

Абсолютная погрешность дифференцируемой функции многих аргументов y=f(x_1, x_2, ..., x_n), вызываемая достаточно малыми погрешностями Delta(x_1), Delta(x_2), ..., Delta(x_n) аргументов x_1, x_2, ...,x_n оценивается величиной:

Delta(y)=sumlimits_{i=1}^nleft|frac{partial f}{partial x_i}right|Delta(x_i).

Если f(x_1,x_2,...,x_n)>0, то delta(y)=sumlimits_{i=1}^nfrac{1}{f}cdotleft|frac{partial f}{partial x_i}right|cdotDelta(x_i)=sumlimits_{i=1}^{n}left|frac{partial l_n(f)}{partial x_i}right|Delta(x_i).

Практически важно определить допустимую погрешность аргументов и допустимую погрешность функции (обратная задача). Эта задача имеет однозначное решение только для функций одной переменной y=f(x), если f(x) дифференцируема и f'(x)not=0:

Delta(x)=frac{1}{|f'(x)|}Delta(y).

Для функций многих переменных задача не имеет однозначного решения, необходимо ввести дополнительные ограничения. Например, если функция y=f(x_1,x_2,...,x_n) наиболее критична к погрешности Delta(x_i), то:

Delta(x_i)=frac{Delta(y)}{left|frac{partial f}{partial x_i}right|}qquad (погрешностью других аргументов пренебрегаем).

Если вклад погрешностей всех аргументов примерно одинаков, то применяют принцип равных влияний:

Delta(x_i)=frac{Delta(y)}{nleft|frac{partial f}{partial x_i}right|},qquad i=overline{1,n}.

Числовые примеры

Специфику машинных вычислений можно пояснить на нескольких элементарных примерах.

ПРИМЕР 1. Вычислить все корни уравнения

x^4 - 4x^3 + 8x^2 - 16x + 15.underbrace{99999999}_8 = {(x - 2)}^4 - 10^{- 8} = 0.

Точное решение задачи легко найти:

(x - 2)^2  =  pm 10^{- 4},
x_1= 2,01;  x_2= 1,99;  x_{3,4}= 2 pm 0,01i.

Если компьютер работает при delta _M > 10^{ - 8}, то свободный член в исходном уравнении будет округлен до 16,0 и, с точки зрения представления чисел с плавающей точкой, будет решаться уравнение (x-2)^4= 0, т.е. x_{1,2,3,4} = 2, что, очевидно, неверно. В данном случае малые погрешности в задании свободного члена approx10^{-8} привели, независимо от метода решения, к погрешности в решении approx10^{-2}.

ПРИМЕР 2. Решается задача Коши для обыкновенного дифференциального уравнения 2-го порядка:

u''(t) = u(t), qquad u(0) = 1, qquad u'(0) = - 1.

Общее решение имеет вид:

u(t) = 0,5[u(0) + u'(0)]e^t  + 0,5[u(0) - u'(0)]e^{- t}.

При заданных начальных данных точное решение задачи: u(x) = e^{-t}, однако малая погрешность delta в их задании приведет к появлению члена delta e^t, который при больших значениях аргумента может существенно исказить решение.

ПРИМЕР 3. Пусть необходимо найти решение обыкновенного дифференциального уравнения:

stackrel{cdot}{u} = 10u,qquad u = u(t),\ u(t_0) = u_0,qquad t in [0,1].

Его решение: u(t) = u_0e^{10(t - t_0 )}, однако значение u(t_0) известно лишь приближенно: u(t_0) approx u_0^*, и на самом деле u^*(t) = u_0^*e^{10(t - t_0)}.

Соответственно, разность u* - u будет:

u^* - u = (u_0^* - u_0)e^{10(t - t_0)}.

Предположим, что необходимо гарантировать некоторую заданную точность вычислений epsilon > 0 всюду на отрезке t in [0,1]. Тогда должно выполняться условие:

|{u^*(t) - u(t)}| le varepsilon.

Очевидно, что:

maxlimits_{t in [0,1]} |{u^*(t) - u(t)}| = |{u*(1) - u(1)}| = |{u_0^* - u_0}|e^{10(1 - t_0)}.

Отсюда можно получить требования к точности задания начальных данных delta: qquad|u_0^* - u_0| < delta, qquad delta le varepsilon e^{ - 10} при t_0= 0.

Таким образом, требование к заданию точности начальных данных оказываются в e^{10} раз выше необходимой точности результата решения задачи. Это требование, скорее всего, окажется нереальным.

Решение оказывается очень чувствительным к заданию начальных данных. Такого рода задачи называются плохо обусловленными.

ПРИМЕР 4. Решением системы линейных алгебраических уравнений (СЛАУ):

left{ begin{array}{l} u + 10v = 11, \ 100u + 1001v = 1101; \ end{array} right.

является пара чисел {1, quad 1}.

Изменив правую часть системы на 0,01, получим возмущенную систему:

left{ begin{array}{l} u + 10v = 11.01, \ 100u + 1001v = 1101; \ end{array} right.

с решением {11.01, quad 0.00}, сильно отличающимся от решения невозмущенной системы. Эта система также плохо обусловлена.

ПРИМЕР 5. Рассмотрим методический пример вычислений на модельном компьютере, обеспечивающем точность delta_M = 0,0005. Проанализируем причину происхождения ошибки, например, при вычитании двух чисел, взятых с точностью до третьей цифры после десятичной точки u = 1,001,quad v = 1,002, разность которых составляет Delta = |v_M - u_M| = 0,001.

В памяти машины эти же числа представляются в виде:

u_M = u(1 + delta_M^u), quad v_M = v(1 + delta_M^v), причем  mid delta_M^umid le delta_M и mid delta_M^vmid le delta_M.

Тогда:

u_M - u approx udelta_M^u, quad v_M - v approx vdelta_M^v.

Относительная ошибка при вычислении разности u_M - v_M будет равна:

 delta = frac{(u_M - v_M) - (u - v)}{(u - v)} = frac{(u_M - u) - (v_M - v)}{(u - v)} = frac{delta_M^u - delta_M^v}{(u - v)}.

Очевидно, что  delta = left|{frac{delta_M^u - delta_M^v}{Delta }} right| le frac{2delta_M}{0,001} approx 2000delta_M = 1, т.е. все значащие цифры могут оказаться неверными.

ПРИМЕР 6. Рассмотрим рекуррентное соотношение u_{i+1} = qu_i, quad i ge 0, quad u_0 = a,quad q > 0, quad u_i > 0.

Пусть при выполнении реальных вычислений с конечной длиной мантиссы на i-м шаге возникла погрешность округления, и вычисления проводятся с возмущенным значением u_i^M = u_i + delta_i, тогда вместо u_{i+1} получим u_{i + 1}^M = q(u_i + delta_i) = u_{i + 1} + qdelta_i, т.е. delta_{i + 1} = qdelta_i,quad i = 0,1,ldots .

Следовательно, если |q| > 1, то в процессе вычислений погрешность, связанная с возникшей ошибкой округления, будет возрастать (алгоритм неустойчив). В случае mid qmid le 1 погрешность не возрастает и численный алгоритм устойчив.

Список литературы

  • А.А.Самарский, А.В.Гулин.  Численные методы. Москва «Наука», 1989.
  • http://www.mgopu.ru/PVU/2.1/nummethods/Chapter1.htm
  • http://www.intuit.ru/department/calculate/calcmathbase/1/4.html

См. также

  • Практикум ММП ВМК, 4й курс, осень 2008

Понравилась статья? Поделить с друзьями:
  • Ошибка воспроизведения аудио на андроид
  • Ошибка выражение должно быть допустимым для изменения левосторонним значением
  • Ошибка загрузки вк 2023
  • Ошибка ворлд оф танк точка входа не найдена
  • Ошибка выполнения запроса попробуйте позже