Optimisation in the loop with the solver
Genetic Algorithms Coupled to FEM
A global optimisation framework using genetic algorithms, coupling Python directly to Abaqus to automate synthetic data generation and accelerate design convergence.
- Period
- 2023 — 2024
- Domain
- Design optimisation
- Focus
- Optimisation · Simulation · Mechanical Design
The problem
Design problems in mechanical engineering are frequently non-convex, constrained, and expensive to evaluate: every candidate design needs a finite element run. Gradient-based methods get stuck in the nearest local optimum, and manual iteration explores a laughably small fraction of the space.
There is also a second, quieter problem. Data-driven methods need data, and for a design that does not exist yet there is none — which makes simulation the only credible source.
Approach
I built a framework that treats the FEM solver as a black-box objective function and wraps a genetic algorithm around it.
population ──→ parametric geometry ──→ Abaqus job ──→ extract results
▲ │
└────── selection · crossover · mutation ◀── fitness ───┘
The engineering effort sits in the parts between the boxes:
- Full automation of the solver loop. Geometry generation, meshing, job submission, result extraction and failure handling all run without a human. Any manual step in the loop caps the number of evaluations at roughly “how much patience do I have today”, which is not a number you can optimise against.
- Constraint handling that respects manufacturability. An optimum that cannot be produced is not an optimum. The constraints encode what the process can actually make.
- Robustness to failed runs. Some candidate geometries will not mesh or will not converge. The framework treats that as information and carries on, rather than crashing overnight and losing the queue.
The second payoff
Every evaluation is a labelled datapoint: parameters in, simulated response out. The optimisation run therefore produces a synthetic dataset of the design space as a by-product.
That dataset is reusable. Surrogate models fitted to it answer new questions in milliseconds instead of solver-hours, and the sensitivity structure of the design space becomes something you can inspect directly rather than infer from a handful of runs.
Where this connects to the rest of my work
This is the same pattern as the industrial ML projects, with the physics moved to the other side: an expensive, trustworthy physical model, an automated loop around it, and statistics used to spend the expensive evaluations where they are worth the most.