Skip to content
Fabio Serra Pereira

← Map

Digital Shadow

2025 · Poli-USP · bachelor’s thesis

What switches on and off, as a Petri net. What flows, by equation and neural network.

Real data · anonymous company

  • Petri nets
  • Machine data
  • Learning
lights up: predict

The process

From pyrolysis gasoline to polymer.

The process, redrawnFrom left to right: two distillation columns, two tanks that take turns, the reactor, the pelletizer, bagging, the warehouse and the customer. A dashed reserve warehouse also supplies the customer.columncolumntanksreactorpelletsbaggingwarehousecustomerreserve The process, redrawnFrom top to bottom: two distillation columns, two tanks that take turns, the reactor, the pelletizer, bagging, the warehouse and the customer. A dashed reserve warehouse also supplies the customer.columncolumntanksreactorpelletsbaggingwarehousecustomerreserve
Redrawing of the process. A Brazilian company, kept anonymous.

The Petri net

Closed, opening, open, closing.

Petri net of a valveFour places in a diamond: closed, opening, open and closing. The token moves clockwise from one place to the next through a transition.closedopeningopenclosingPetri net of a valveFour places in a diamond: closed, opening, open and closing. The token moves clockwise from one place to the next through a transition.closedopeningopenclosing
The valveA valve on a pipe. The lever turns with the token: upright, the valve is closed; flat, it is open and the flow passes.

steps to operation

  • column 14
  • column 29
  • reactor10
Redrawn. Every valve, pump and tank has its own net.

The forecast

Together, they err less.

The four curves, sketchedNo axes or values. The curve of both together sticks to the measured one; the neural network follows the shape, but lower; the equation follows the measured curve and drops three times.

11 months to learn. 1 to test. Forecast for the next hour.

Mean squared error of massLog scale. Column 1: equation 5.5, neural network 0.5, together 0.0003. Column 2: equation 8.6, neural network 0.5, together 0.34.0.00010.0010.010.1110column 1column 2equationneural networktogetherequationneural networktogether5.50.50.00038.60.50.34Mean squared error of massLog scale. Column 1: equation 5.5, neural network 0.5, together 0.0003. Column 2: equation 8.6, neural network 0.5, together 0.34.0.00010.011column 1column 2equationneural networktogetherequationneural networktogether5.50.50.00038.60.50.34
  • measured
  • equation
  • neural network
  • together
Mean squared error of mass, one hour ahead. Log scale. Curves redrawn, without process values.

Still open

  • It is a digital shadow: it follows the process without acting on it.
  • It is the basis for predictive control and a digital twin.
  • It forecasts the next hour, not the next days.

Tools

  • hybrid Petri nets
  • Snoopy
  • hourly process data
  • linear regression
  • neural network (MLP)
  • Python 3.11
  • scikit-learn
  • SciPy
  • Excel

Document

Development of the digital model of an industrial process based on the Discrete-Events and Hybrid Systems concepts · bachelor’s thesis · Mechatronics Engineering, Poli-USP · 2025