mdzahan@edu.aau.at
Uncertainty calculator

Details about: Uncertainty calculator

What is Uncertainty ?

Uncertainty in measurement is the quantification of the doubt about the measurement result.For example – we might say that a particular stick is 200cm ±1cm at a level of confidence of 95%.

Key factors of uncertainty

  • No measuring instrument is perfectly accurate. When we do any measurement, there is always some uncertainty as to the exact value.
  • The calculation and expression of uncertainty are important for good quality measurements.
  • Uncertainty can influence a pass or failure in a particular test and a calibration certificate is requested.

How it works

In the following way, the user can perform the uncertainty calculation.

import numpy as np
from unc import Unc
import math
a = Unc(3, 0.5)
b = Unc(2, 0.7)

print(‘\nUncertainty value with constant calculation:’)
print(“NOTE: By default the value in parenthesis represents the absolute uncertainty\n”)
input(“Enter any key to continue ………..”)
# ######## Constant calculation with addition ##################
# ########################### Addition Calculation ##################
print(‘Value and uncertainty is:’, a)
print(‘Now if we Add(+) pi=3.14 Constant right side of the calculation, example: Unc(3, 0.5) + Unc(math.pi)’)
c = a + Unc(math.pi)
print(c)

input(“Enter any key to continue ………..”)
print(‘\nNow if we Add(+) pi=3.14 Constant left side of the calculation, example: Unc(math.pi) + Unc(3, 0.5)’)
d = Unc(math.pi) + a
print(d)

#################################################################
input(“Enter any key to continue ………..\n”)
print(‘Now if we Subtract (-) pi=3.14 Constant right side of the calculation, example: Unc(3, 0.5) – Unc(math.pi)’)
# ######## Constant calculation with subtraction ##################
c = a – Unc(math.pi)
print(c)

print(‘Now if we Subtract (-) pi=3.14 Constant left side of the calculation, example: Unc(math.pi) – Unc(3, 0.5)’)
d = Unc(math.pi) – a
print(d)
input(“Enter any key to continue ………..\n”)
#################################################################

Key Information
Developer
DI Md Sarwar Zahan
Project owner
Alpscron
Released
April 2017
Last Update:
March 2018
Version
v2.0
Used libraries
numpy , sympy, math, cmath
Abilities
Real and Complex Numbers Calculation
Operations
+, -, *, /, %, Matrix, PDE, ODE
Category
Console
Language
Python