By the Versatile Technical Team. Adapted from a seminar given to foundry engineers on sand control and machine learning.

Somebody in your plant has already been asked why you are not using AI. The usual first step follows: export the defect workbook, paste it into a chatbot, and ask what is causing the scrap.

An answer comes back. It is fluent, it cites your own numbers, and it often matches a hunch somebody already had. That is exactly the problem.

What follows is not an argument against machine learning in a foundry. It is an account of what happens to foundry data on the way to that answer, and of where the technique genuinely belongs.

Six ways a defect sheet breaks a chatbot

None of these announce themselves. Every one of them returns a confident, plausible, well-written answer.

1. It averages away the fault

Your file holds one row per test, per shift, per grade, per line. A monthly mean gets taken. Two lines were running different grades: one collapsed, one did not. The mean moves a little. The line that hurt you moved a lot, and that movement has just been flattened.

2. It joins on the wrong clock

Sand is tested at the muller at 06:40. The casting it made is poured at 09:15 and scrapped at inspection the following day. Join those on a date column and Tuesday’s sand gets correlated with Monday’s defects. The arithmetic is faultless and the conclusion is meaningless.

3. It mistakes a shared cause for a cause

Fines rise as permeability falls, because the muller is declining. Both are symptoms of the same thing. Regress defects on permeability, find a strong correlation, and you will be handed a symptom to chase while the actual cause carries on declining.

4. It cannot see your sampling bias

Extra tests get run when the sand looks wrong. That is good practice, and it means bad sand is over-represented in the file relative to what was actually poured. A model learns from a sample created by your own worry.

5. It trusts your defect codes

Twenty or more codes, applied by different inspectors across shifts. One shift’s inclusion is another’s hole. Causes then get ranked for a category that is partly a record of who happened to be looking.

6. It will never tell you that it cannot tell

Ask for a root cause and a root cause will be produced. The confidence sits in the prose, not in the evidence. No residual is shown, no closure check is offered, and no balance is allowed to fail.

What a confident wrong answer costs

The failure is not noticed on the day. It gets noticed after the money has been spent.

Week one. The answer arrives: permeability is your driver. Sourced from your own numbers, and it matches what somebody already suspected.

Week two. New sand addition goes up. Bond addition changes. A screen change is argued for. Real money, and real changes to a system that was already drifting.

Week four. Permeability improves. Scrap does not. The muller was the cause and it is still declining. Two variables have now moved, so nothing can be attributed to either.

Week six. You have spent on bond, disturbed a system that was stable, lost six weeks of drift you could have caught, and burned the credibility of the next person who proposes an analysis.

One physics question would have stopped this in week one. Does the water balance across the muller close? If mass in does not equal mass out plus losses, the mixer is your suspect and permeability is downstream of it. That question is answerable from data the plant already has, and asking it costs nothing.

Why more data does not fix it

This part is arithmetic rather than opinion, and no choice of algorithm improves it.

A mid-size plant runs perhaps twenty heats a day. That is roughly seven thousand rows in a full year of running. Split those across dozens of parts and grades and you are left with a few hundred rows per grade.

Deep learning needs enough examples to learn the answer from scratch, because it assumes nothing. In a sand system, the shape it would be learning is already known physics that you would be paying it to rediscover badly.

Physics needs a handful of coefficients instead. Mass and energy must balance on every reading, labelled or not, so the model is corrected for free by every batch you already run.

The gap that no amount of analysis recovers

There is a more fundamental issue, and it is measured rather than argued.

An AFS Basic Concepts Committee (4-E) study across five foundries found that with muller-discharge moisture and temperature held constant, compactability was still lost in transit, while green strength stayed flat. Seal the sand in an airtight bag and it still falls, so nothing has evaporated. Water is migrating into the interior platelets of the clay, and that absorption continues for roughly two and a half hours after the batch leaves the muller.

Your controller is not broken. It is holding the right number at a point in the plant that is not where the mould is made.

Four quantities decide the mould, and none of them is normally measured:

  • Transit time. How long this batch sat between muller and moulding head. It varies with stoppages, silo level and job change, and it is rarely logged against the batch.
  • Clay activation. How much bentonite is live rather than dead. Methylene blue runs once a shift, in the lab, on one sample, hours late.
  • Thermal history. The sand-to-metal ratio and cooling actually seen by this batch. Temperature is measured; history is not.
  • Sampling gap. One sample per cycle is read. Every batch is consumed by the moulding machine, sampled or not.

These are not recovered by analysing the variables you did measure. The honest statement of the problem is not that foundries have no data. It is that the quantities determining the mould are the ones nobody has an instrument on.

What does work: physics first, learning second

Physics supplies the structure. Your own sand supplies the coefficients that make it your system. Machine learning sits on top as a thin, shallow, replaceable layer.

Physics supplies the water balance across the muller, clay absorption as a rate rather than an event, the thermal balance on the return loop, and gas evolution against permeability. Your sand supplies mixing efficiency, the absorption time constant, dead clay accumulation and cooler effectiveness.

This matters to a metallurgist for a specific reason. A model stated in your own physics can be argued with. Its coefficients carry units, its balances either close or they do not, and when it is wrong you are told which term was wrong.

Demand the balance before the prediction

Think of it in cash-book terms. Whatever mass enters a stage must leave it, as product plus returns plus losses. If the money in does not equal the money out plus what is in the drawer, a mistake has been made, and the accounts do not get published.

A model whose water balance across the muller does not close should not be permitted to estimate compactability at the moulding head, and it should certainly not be permitted to advise a dose.

If a vendor cannot show you a closure residual, you are being sold a black box with a confidence interval painted on it.

What to take back to the sand plant

  1. Your controller is not the problem. The right number is held at the muller. The mould is made from sand that has aged since, and the drop is physics, not a fault.
  2. The gap is unmeasured state, not missing data. Transit time, clay activation and thermal history are not recovered by more analysis of the measured variables.
  3. Learning alone starves here. A few thousand rows a year, split across dozens of grades.
  4. Physics is free supervision. Mass and energy balance on every reading, labelled or not.
  5. Ask for the balance before the prediction.

Use the tool for what it is good at: drafting the report, explaining a standard, writing the query, arguing with your reasoning. Not for deciding what to change in a system whose mechanism it cannot see and whose data it will silently mis-join.


Two of the unmeasured quantities above can be instrumented today. V-CAT tests the sand arriving at the moulding machine rather than the sand leaving the muller. BLACKBOX runs the bench tests that normally wait for a lab slot, on the floor and without an operator.

Have a question about your sand?

Tell us what you are testing, and we will point you to the right method, guide, or instrument.