# Chapter 2 · Calibration and measurement answers

**Constructed teaching experiment.** The six CSV readings are paired with three reference temperatures, each repeated twice. They are not readings from a real classroom instrument.

The mean readings are 20.5, 25.8 and 31.1 °C at references 20, 25 and 30 °C. Their errors are +0.5, +0.8 and +1.1 °C. The line through the endpoint means has slope $(31.1-20.5)/(30-20)=1.06$ reading degrees per reference degree and intercept $20.5-1.06(20)=-0.7$ °C. It also predicts the middle mean: $-0.7+1.06(25)=25.8$ °C. This exact fit was constructed for teaching; it does not establish that a real sensor is linear.

For an observed reading of 28.0 °C, the inverted calibration gives $(28-(-0.7))/1.06=27.07547\ldots$ °C, reported as about 27.075 °C. If the only uncertainty were a new reading with standard uncertainty 0.20 °C and the fitted parameters were exact, first-order propagation would give $0.20/1.06\approx0.189$ °C. Real use must also consider reference, coefficient, placement and drift uncertainty.

The five separate repeatability values 20.2, 20.4, 20.5, 20.6, 20.8 °C have mean 20.5 °C and sample standard deviation $\sqrt{0.05}\approx0.224$ °C. Their spread is a repeatability observation under one condition, not a total uncertainty budget.

Add +0.3 °C to a later session and the old calibration equation still runs, but its result shifts. Without a new reference check the old model cannot identify the drift from an unknown environment. Changing a unit label without converting the numeric value should fail a data-validation rule; a silent average would be dimensionally misleading.

Both the retained Python source and base-R source use the same CSV and independently assert the mean readings, slope, intercept and corrected reading. Their captured output is linked from the local companion page. The purpose of two languages is to expose shared assumptions, not to turn agreement between programs into proof of a real instrument's validity.
