Skip to content
Mohammad Awadallah
All posts

A small factory's digital twin starts with data, not 3D

Before any 3D model or polished dashboard, a digital twin needs trustworthy data: correct timestamps, clear units and the context of every batch. A practical order of work for a small plant.

4 min readAlso in:العربيةFrançais

When the owner of a small plant hears “digital twin”, they usually picture a 3D model of the factory spinning on a screen. That’s the least important part. The digital twin that actually helps you starts with a simpler question: do you trust the numbers you collect today?

What a digital twin is

The US National Academies, in a 2024 report, define it as a computational model coupled to its physical counterpart and updated continuously through data flowing in both directions. Manufacturing literature usually separates three levels:

  • Digital model: a simulation or spreadsheet with no automatic link to the plant. You type the numbers in.
  • Digital shadow: data flows automatically from the plant into the system, one way. You see what happens, but the system changes nothing.
  • Digital twin: the flow goes both ways. The system reads the state, computes, and sends a recommendation or command back to the process.

Most small plants gain a great deal from reaching a good digital shadow, and need nothing more at first. The road there runs through data, not graphics.

Step one: time

A reading without an accurate timestamp is close to useless, because you can’t tie it to what happened at the same moment.

  • Record timestamps in one format, with the offset from UTC. RFC 3339 notes that this offset is often useful information, and it is: when you combine data from different devices, or local time changes, it keeps you from mixing things up.
  • Separate when a measurement happened from when it was recorded. The W3C sensor standard (SOSA/SSN) distinguishes the two explicitly, because a sensor may measure now and transmit a minute later.
  • Synchronize device clocks. A device running five minutes slow silently makes every later analysis wrong.

Step two: units and a card for every sensor

A number without a unit isn’t data. For each sensor, keep a “card” with:

  • what it measures, and in which unit;
  • measurement range, accuracy and sampling rate;
  • exactly where it sits in the process;
  • the date of its last calibration, and what it was calibrated against.

SOSA/SSN itself defines properties such as accuracy, range and drift over time, because this information is part of the measurement, not an appendix to it. Calibration in particular is what makes your number comparable: NIST describes metrological traceability as a documented, unbroken chain of calibrations.

Step three: batch context

In batch processes, a reading on its own isn’t enough. You need to know which batch it belongs to, which stage, what inputs went in and in what quantities, who ran it, and what changed from the previous batch.

The ISA-88 batch-control standard was written for exactly this: shared models and terminology for batches, with a part dedicated to organizing batch production data in a way that supports traceability and completeness. You don’t need to implement the whole standard, but borrow the idea: every reading is tied to a batch and a stage.

Step four: storage without the complexity

You don’t need a big platform. Practical options:

  • Plain PostgreSQL: enough for a small plant. For large, time-ordered reading tables, BRIN indexes are designed for very large tables whose order follows the physical order of the data.
  • TimescaleDB: a PostgreSQL extension that partitions time-series data automatically, so queries stay fast as the data grows, and you keep the SQL you know.
  • InfluxDB: a dedicated time-series database, whose open-source edition is InfluxDB 3 Core.

Pick what your team can maintain. A simple database that is updated and backed up beats an advanced platform nobody understands.

Step five: flag strange readings, don’t delete them

This is the most important rule in the whole article. When a strange reading appears, the temptation is to “fix” it or delete it. Don’t.

  • Always keep the raw data as it is.
  • Add a quality flag next to the reading: pass, suspect, fail, missing. That’s what ocean-observing programs applying the US QARTOD scheme do: automated tests flag data, they don’t remove it.
  • “Suspect” doesn’t mean “wrong”. A strange reading may be a sensor fault — or a real event in the process that turns out to be the most important thing you learn all season. Delete it and you lose both possibilities.

Then: simulation

Once your data is trustworthy, you can build a model — physical or statistical — that simulates the process and predicts what will happen. But a model isn’t to be believed because it looks reasonable. Verification and validation standards such as ASME V&V 20 measure a simulation’s accuracy by comparing it to measured data, accounting for measurement uncertainty, and say nothing about its accuracy far from the points where it was tested. In other words: your model is only as good as your data, and only within the conditions you compared it in.

The takeaway

A digital twin isn’t a graphics project. It’s an order of work: correct time, then units and sensor cards, then batch context, then simple storage, then quality flags instead of deletions. Simulation and recommendations come after that — and, at the very end, if you want it, the 3D model. Start in the right order, and you’ll find that a digital shadow alone changes the way you run production.