Sensor stream
Rotor speed0.0rpm
Power output0.00MW
Gearbox vibration0.00mm/s
Bearing temperature0°C
Operating hours0h
Model output
measuredexpected
Anomaly score0.00
Health index100%
Remaining useful life—
Normal operation
Measured vibration matches the model's prediction. No action needed.
Formation log
01 — Main sequence
Hydrogen fusion in the core pushes outward exactly as hard as gravity pulls inward. The star is stable, and will stay so for millions of years.
Mass remaining100%
Horizon rs29.5km
Radiative efficiency5.7%
Sonified tone220Hz
Hawking temperature6.2nK
Elapsed0yr
Fraction of lifetime0%
Losing the first 10% of its mass burns
27% of the lifetime; losing 90% burns 99.9%. Evaporation runs away at the
end because TH ∝ 1/M.
Radius12.00rs
Redshift factor g0.958
Apparent brightness84%
Tidal stretch1.0×
Our clock0.0
Clock on the body0.0
Model output — Schwarzschild solution
Mass10.0M☉
Event horizon rs29.5km
Spin a/M0.000
Horizon r+29.5km
Photon sphere (prograde)44.3km
Innermost stable orbit88.6km
Orbital period there4.6ms
Orbiting clock rate70.7%
Orbit statusStable
The Observer slider sets the orbit radius
r used by the two rows above — nothing is drawn for it, so the traced image stays
exactly what the equations produce.
Escape speed there0.50c
Radiative efficiency5.7%
Sonified tone220Hz
Hawking temperature6.2nK
Evaporation time2e70yr
The working hide
What is real here
The numbers are exact. Every value above is computed live from the Schwarzschild
solution, in SI units, from the mass you set — no lookup tables.
The image is traced, not drawn. For every pixel a light ray is followed backwards
through Schwarzschild spacetime by integrating the photon orbit equation
d²u/dφ² = −u + 1.5 rsu² with a Runge–Kutta
solver. The arcs over the top and under the bottom are the second and third times that
ray crosses the disk plane — nobody drew them. The shadow is simply where rays end
on the horizon, which is why it comes out at 2.6 rs by itself. The solver
was checked against the exact capture impact parameter 3√3/2 rs and
reproduces it to better than 0.1%, so the shadow keeps its correct size even when the
quality drops on a slower machine. Switch
Lensing off to integrate straight lines instead and watch the arcs vanish.
What spin does here. The Spin slider uses exact Kerr formulas for the
horizon, the photon sphere, the innermost stable orbit and the orbital frequency, so the
disk really does close in, speed up and rise in pitch as you spin the hole up. But the ray
tracing is still the Schwarzschild equation, so the image does not yet show the
sideways squash that frame dragging gives a real Kerr shadow. Past about a = 0.35 the
drawn inner edge of the disk stops moving, because the Kerr ISCO would fall inside the
Schwarzschild shadow and vanish — an artefact of mixing two geometries, not physics.
Treat every number as exact, and the shadow shape as the non‑rotating case.
What is still approximate. The disk's
radial brightness now follows the standard Shakura–Sunyaev thin‑disk profile
rather than an invented gradient, but it is still not a radiative‑transfer solution:
the fine filaments are synthetic noise standing in for turbulence, and the
colour is illustrative — at roughly 107 K a real disk emits X‑rays
your eye could not see. The step budget truncates rays that loop many times, so the very
highest‑order images are missing. Sizes are not to scale: a real star is around
105 rs across, so it cannot be drawn beside its own horizon, and
the collapse takes seconds here and milliseconds in reality.
On the Interstellar look
The shape arises for the same reason the film's did: the disk is viewed almost
edge‑on, and light from the far side is bent up over the hole and down under
it, closing into a ring around the shadow. Both images come out of the same integration.
About the sound. A vacuum carries no sound, so none of this is what you would
hear. It is sonification: the pitch is the orbital frequency at the innermost stable
orbit, which really is 220 Hz for a 10 M☉ hole and rises to 1361 Hz at
the Thorne spin limit. It is placed at the hole with HRTF panning and fed through
convolution reverb, and the listener follows your camera, so orbiting moves the sound
around your head. The supernova is a synthesised burst, not a measurement.
Gargantua left out Doppler beaming on purpose. Kip Thorne's equations gave one side
blindingly bright and the other nearly black; the filmmakers removed it because audiences
found the lopsided image confusing. Switch Beaming off to match the film, and on to
see what the physics actually predicts — an 81:1 brightness ratio.
Artificial intelligence & machine learning · live demonstration
Two ways to build a digital twin
A digital twin is a model of a real system that runs alongside it. This page
contains two working ones. The first learned its behaviour from sensor data. The second was
derived from equations and never saw data at all. Almost everything AI and ML do sits
between those two poles.
Press → or swipe to begin
Agenda
Nothing here is a screenshot.
Both models are executing in your browser as this sentence is read. Every number
is computed live, and every claim on the following slides can be falsified by touching a control.
- IWhat a model is — rules, learning and theory, and the five steps
every ML system follows.
- IITwin one: data‑driven. A wind turbine. Requires the physical asset,
instrumented and logged. Algorithm: least‑squares regression with residual scoring.
- IIITwin two: physics‑driven. A black hole. Requires no asset and no
data. Algorithm: Runge–Kutta integration of the geodesic equation.
- IVWhich to use, and what goes wrong — hybrid models, validation,
and the failure modes that matter in practice.
I
Foundations
What a model is
Three ways to obtain one, and the single pipeline they all share.
01 — Where AI fits
Software you write. Models that learn.
Conventional code executes the rule you gave it. A machine learning model is never
given the rule — it is shown examples and infers the rule itself. That single difference is
what makes it useful wherever the rule cannot be written down by hand.
Rule‑based
The engineer supplies the rule.
"If vibration exceeds 4 mm/s, raise an alarm." Deterministic, auditable, and blind to every
failure mode nobody anticipated.
Learned — machine learning
The data supplies the rule.
Observe a healthy machine long enough and the model learns what healthy looks like, then reports
when reality stops matching. Twin one.
Derived — first principles
Theory supplies the rule.
No training data whatsoever: a validated equation, solved numerically each frame.
Twin two.
02 — Taxonomy
Three paradigms. One is used here.
Machine learning is not one technique. The paradigm is decided by what the training
data actually contains, before any algorithm is chosen.
Supervised
Inputs and known correct outputs. Splits into
regression (predict a number) and classification (predict a category).
Our turbine model is supervised regression.
Unsupervised
Inputs only, no labels. Clustering, dimensionality
reduction and autoencoder‑based anomaly detection. Used when nobody has labelled which
historical readings were faults.
Reinforcement
No fixed dataset — an agent acts, receives a
reward, and updates a policy. Robot control, game playing, and the alignment stage of a
large language model.
03 — The pipeline
Five steps. Every model, every time.
Image recognition, a language model, the turbine behind this text — they
differ in scale and in the function being fitted, never in the shape of the loop.
01Acquire
Measurements arrive. Here: five
sensor channels, sampled continuously.
02Features
Select the informative inputs.
Vibration is governed by rotor speed, so that is the feature.
03Train
Fit parameters that map feature to
target on verified‑healthy history. This is the learning.
04Infer
Feed live input to the fitted model.
It returns the value it expects.
05Decide
Compare expected against actual.
The discrepancy — the residual — is the output that matters.
04 — Algorithm selection
The algorithm follows the data, not the fashion.
There is no universally best algorithm — a result formalised as the
no‑free‑lunch theorem. You choose by the shape of the data and the amount of it.
Linear regression
Continuous output, few inputs, a relationship
believed monotonic. Two coefficients, fully interpretable. Chosen for twin one.
Trees & ensembles
Decision trees, random forests, gradient
boosting. The default for tabular data with many mixed features.
Clustering & autoencoders
k‑means, DBSCAN,
autoencoders. Unlabelled, high‑dimensional signals — vibration spectra rather than a
single scalar.
Neural networks
CNNs for images, transformers for sequences and
language. Enormous capacity, and enormous data and compute requirements to match.
Five sensors do not justify a neural network. It would fit the noise and explain nothing.
II
Twin one — data‑driven
The twin that needs an asset
To build this model you must first own the machine, instrument it, and run it long
enough to log verified‑healthy history. No asset, no data. No data, no model.
05 — Step one: acquisition
It begins as nothing but numbers.
On the left, the physical wind turbine. On the right, its digital twin — the same machine expressed as software. Five channels stream continuously from one to the other.
Nothing here is intelligent yet. This is instrumentation, and it is the prerequisite the second half of this talk will do without.
Drag to orbit the view · click a glowing sensor to isolate it
06 — Steps two to four: the algorithm
Least squares. Two coefficients.
The feature is rotor speed ω; the target is gearbox vibration v. Fitting on healthy history by ordinary least squares gives one straight line:
v̂ = β0 + β1·ωβ0 = 0.55 mm/s · β1 = 0.085 mm/s per rpm
That is the entire trained model — two numbers. Move Wind and the dashed prediction tracks the solid measurement, because the model learned the input–output relationship, not a recording of the output.
Sweep Wind from 4 to 24 m/s and watch the two lines stay together
07 — Step five: residual scoring
Every reading is normal. The model disagrees.
A bearing is now degrading. Read the sensor card: vibration is still well inside any threshold an engineer would have set. But it exceeds the prediction for this rotor speed, and that gap is the detector:
r = v − v̂ a = max(0, r) / 3.2one‑sided: only excess vibration is a fault
smoothed by an exponential moving average, so one noisy sample cannot trip it
a > 0.22 → anomaly · a > 0.62 → failure predicted
There are still thresholds — but they sit on the residual, not on the raw signal. That is what lets the system catch a fault whose absolute value is unremarkable.
Wait ten seconds and watch a normal-looking reading become an alarm
08 — From detection to decision
Diagnosis, prognosis, prescription.
Detection is only the first tier. The twin also extrapolates the damage rate to a remaining useful life in days, and — because it is a model and not a log — it can be asked counterfactual questions the real machine cannot be asked.
What‑if: cut load 20% is answered in software. Wear accrues at 55% of the previous rate, remaining life rises, and no real gearbox had to be destroyed to establish it. This is prescriptive maintenance: the model recommends the action, not just the alarm.
Toggle What-if and compare remaining useful life
09 — The failure mode that matters
A model is never finished.
Press Retrain. The twin re‑fits its intercept to today's readings, and the anomaly disappears instantly — the fault has just been redefined as normal.
β0 ← β0 + rretraining on unverified data absorbs the fault into the baseline
Real deployments fail here far more often than they fail at the mathematics. Models also decay on their own as the asset ages — concept drift — so retraining is mandatory, and retraining on data nobody verified is how a monitoring system goes quietly blind.
Retrain while the fault runs, then read the drift warning
10 — The price of a learned model
Accurate only where it has been.
Everything just demonstrated depended on owning the turbine. That dependency has
consequences worth stating plainly before we remove it.
It needs the asset
Months of logged, verified-healthy operation
before the first useful prediction. A machine that does not exist yet cannot be modelled this
way.
It does not extrapolate
The fit is trustworthy inside the range of
wind speeds it was trained on and speculative outside it. Confidence does not fall off on its
own — you must bound it.
It cannot explain itself
Two coefficients happen to be readable. A
forest of five hundred trees is not, which is why interpretability is a design
requirement, not a nicety.
III
Twin two — physics‑driven
The twin that needs no asset
Nobody owns a black hole, nobody has instrumented one, and there is no training
data. A faithful twin is still possible — because for this system we have the governing
equation.
11 — A model you can run forward
No data. No training. Only the equation.
A star exhausts its fuel and gravity wins. Each stage is solved live from general relativity — nothing here was measured, fitted, or looked up.
Note what this buys you: the model existed before any observation. The first photograph of a black hole was taken in 2019; the equation behind this image was written in 1916, and predicted the shadow's size correctly a century early.
Press Play collapse, then scrub the stage slider
12 — The algorithm, twin two
Runge–Kutta, once per pixel.
The image is traced, not drawn. For every pixel on screen a light ray is followed backwards through curved spacetime by numerically integrating the photon orbit equation, with u = 1/r:
d²u/dφ² = −u + ⅓·3·rsu²solved by fourth‑order Runge–Kutta (RK4), fixed step budget
disc brightness follows the Shakura–Sunyaev thin‑disc profile
Nobody drew the arcs above and below the shadow — they are the second and third times the same ray crosses the disc plane. Switch Lensing off to integrate straight lines instead, and they vanish.
Toggle Lensing · toggle Beaming
13 — Querying a derived model
Change one number. Everything follows.
The readout is not a lookup table. Move Mass and the horizon, the photon sphere, the innermost stable orbit, the orbital period and the sonified pitch all recompute from closed‑form Schwarzschild and Kerr solutions.
rs = 2GM/c²photon sphere 1.5 rs · innermost stable orbit 3 rs · shadow 2.598 rs
Open The working to read the algebra as it executes. A derived model can always show its reasoning — precisely the property a learned model struggles to offer.
Drag Mass and Spin · expand The working
14 — Validation
How do you know a twin is right?
A learned model is validated against held‑out data it has never seen. A derived model has no data, so it is validated against results the theory computes exactly:
bc = (3√3 / 2) · rsexact critical impact parameter for photon capture
this solver reproduces it to better than 0.1%
Because the numerical solution matches the analytic one, the shadow keeps its correct size even when rendering quality is reduced on a slow machine. Every twin needs a ground truth — the only question is whether it comes from measurement or from theory.
Reduce quality by resizing the window; the shadow does not change size
IV
Synthesis
Choosing, combining, failing
Which twin to build, how the two are combined in practice, and what goes wrong.
15 — The two twins compared
The same goal. Opposite prerequisites.
Data‑driven — the turbinePhysics‑driven — the black hole
PrerequisiteThe asset must exist and be instrumentedA trusted governing equation
Learns fromLogged healthy historyNothing — it is derived
AlgorithmLeast‑squares regression, residual scoring, EMA smoothingRK4 integration of the geodesic equation; closed‑form Kerr solutions
ValidOnly inside the training rangeEverywhere the theory holds
Explains itselfPoorly — it is a fitted curveCompletely — every step is algebra
Fails whenThe asset changes, or the training data was already faultyThe theory is incomplete for the regime
Cost to buildMonths of clean, verified historyMinutes — if the physics is known
16 — Where the two halves meet
Simulation becomes training data.
The interesting engineering is not choosing between the two twins. It is using each
to cover the other's weakness — which is where most current research sits.
Surrogate models
Run the physics simulation thousands of times,
then train a fast model on its output. You get the accuracy of the equation at the speed
of a regression — a physics twin that runs in real time.
Physics‑informed ML
Add the governing equation to the loss
function, so the network is penalised for violating conservation laws. Far less training data is
then required, and the model cannot extrapolate into nonsense.
Synthetic data
No turbine has failed catastrophically in your logs,
so simulate the failure and train on that. This is how models learn rare events nobody
can afford to observe.
The 2019 black hole image was selected by matching real telescope data against simulated images.
17 — The same loop, elsewhere
Different sensors. Identical shape.
Nothing demonstrated here is specific to turbines or to gravity. Change what the
sensor measures and the same five steps reappear in an unrelated field.
Medicine
Input: a scan. Prediction: what healthy tissue should look
like. Decision: flag the residual for a radiologist — assistive, not autonomous.
Energy
Input: grid telemetry and weather. Prediction: demand at
18:00. Decision: how much to generate before it is needed.
Manufacturing
Input: spindle current and acoustics. Prediction: tool
wear. Decision: change the tool between batches rather than mid‑cut.
Language
Input: the tokens so far. Prediction: the next token.
Decision: emit it, and repeat. A large language model is this loop at enormous scale.
18 — Engineering responsibility
Where these systems break.
A demonstration that only shows the success case is advertising. These are the
failure modes an engineer is accountable for.
Overfitting
A model complex enough to memorise its training set scores
perfectly on it and fails on anything new. Held‑out validation data is the only
honest test.
Garbage in
Retraining on a degrading machine teaches the model that
degradation is normal — demonstrated live three slides ago. Training data must be
verified, not merely collected.
The wrong metric
Accuracy is meaningless when 99.9% of readings are
healthy. Precision, recall and the real cost of a false alarm against a
missed fault are what govern the threshold.
Unearned trust
A confident output is not a correct one. Every model
needs a stated valid range, a monitored error, and a human who owns the decision.
Conclusion
A model is a prediction with a reason.
Learned from data or derived from theory, both twins on this page do one thing:
they state what should happen next, and they can be interrogated about why. AI is not an oracle
and not a search engine — it is the component of a system that holds an expectation
and reports when the world disagrees with it.
It predicts
The output is an expectation, never a fact.
It is measured
The residual between expected and actual is the
product.
It decays
The asset ages and the world moves. An unmaintained model
silently stops being right.
It needs one of two things
An instrumented asset, or a trusted
equation. Never neither.