Prof. Rosi
  • Home
  • Didattica
  • EdTech
  • Toolbox
  • Stories
  • Chi sono

Noise Lab

Every reading wobbles. Look how.

What is the noise of a temperature measurement? Look at it, repeat the experiment, average it. In Python, in your browser.
Look Repeat Average

Look ⇆

viewof noise = Inputs.range([0.1, 1], {value: 0.4, step: 0.05, label: "noise (°C)"})

How much each thermometer reading wobbles at random, in °C. The grey band in the graph is ± this value.

viewof memory = Inputs.range([0, 0.95], {value: 0, step: 0.05, label: "memory"})

How much each reading resembles the one before. 0: every reading is independent (white noise). Close to 1: the noise drifts slowly, like a room warming up.

viewof thermo_step = Inputs.range([0, 0.5], {value: 0, step: 0.05, label: "thermometer step (°C)"})

A digital thermometer rounds its readings. With 0.5 it can only show 21.0, 21.5, 22.0… Zero means no rounding.

Repeat ↓

Repeat

Same experiment, again and again. Change a number in the code. Press Run Code.

Average ↓

Average ⇆

viewof avg_memory = Inputs.range([0, 0.95], {value: 0, step: 0.05, label: "memory"})

The same memory as above, now for a thermometer in a bath at constant temperature. Averaging N readings should cut the error by √N, but only if the readings are independent.

NoteWords
  • noise: what is left of a reading after you remove the law (the residuals).
  • σ: how wide the noise is. About two readings in three fall within ±σ.
  • memory: how much a reading resembles the one before. 0 is white noise. Statisticians call it autocorrelation; r₁ is its value at one step.
  • histogram: how the values are spread, forgetting their order. It can look the same for any memory.
  • thermometer step: a digital thermometer rounds. The error is up to half a step, with σ ≈ step / √12.
  • repeat (Monte Carlo): redo a simulated experiment many times to see how the result scatters.
  • error of the average: σ/√N for white noise. Memory makes averaging less effective.
NoteAbout this page

Python runs inside your browser (Pyodide, WebAssembly): nothing you type is sent to a server. The first visit downloads tens of MB of Python files and page libraries from a public content delivery network (jsDelivr), which can see your IP address; later visits use the browser cache. The data are simulated with the same cooling model as the Mosaicus simulator.