How the thermometer works?