Physics-Informed Neural Networks for Indoor Temperature
How warm is it in every corner of a room when you only have nine sensors? We trained a neural network to fill in the gaps, and on its own it invented temperature patterns that are physically impossible. Teaching it the law of how heat spreads fixed that.
- Group of 3, with Andrine Holen and Emily Ann Mercer. We each worked through every task, compared approaches and results, and then split the final write-up.
- Feb 2026
- Completed
- A
- Python · JAX · NumPy · matplotlib · pytest
Problem
To heat a building efficiently you need to know the temperature everywhere, but in practice you only have a few imprecise sensors and do not know the physical parameters. The task: reconstruct the temperature in a 10 × 5 m room over 24 hours from nine noisy sensors, and try to learn the unknown parameters at the same time.
Technical skills
- Finite-difference methods for partial differential equations (implicit Euler, Robin boundary conditions)
- Neural networks in JAX: forward pass, training loop, JIT compilation
- Automatic differentiation and vectorisation (
grad,vmap) - Physics-informed loss functions and parameter estimation
- Gradient-based optimisation with Adam
- Hyperparameter studies and visualising results with matplotlib
- Structured Python projects with configuration files and automated tests (pytest)
Approach
Numerical reference
An implicit finite-difference solver gives the 'true' temperature and generates synthetic sensor data.
Neural network
A small fully connected network in JAX learns temperature as a function of position and time, from sensor data only.
Physics-informed network
The same network, but the loss also penalises violations of the heat equation and boundary conditions, computed with automatic differentiation. The unknown physical parameters are learned alongside.
Experiments
Varying sensor density, noise, network size, training length, learning rate and loss weights.

Results



The full results, code and report are on GitHub.