One language for any solver
An xfea model is a description of a structure and of what happens to it, written in Python, with nothing in it that belongs to one solver: no input-file keywords, no element codes, no card formats. The same script describes the model whatever solver ends up solving it, and its results come back in the same form whatever solver produced them.
model = Model(name="cantilever")beam = model.add_part(Part(name="beam"))beam.base_geometry = Line((0, 0, 0), (2000, 0, 0))beam.mesh(settings=MeshingSettings(max=100), section=section, element_cls=BeamElement, orientation=[0, 1, 0])model.add_fix_bc(nodes=beam.find_closest_nodes_to_point((0, 0, 0)))
problem = model.add_problem(Problem(name="tip_load"))step = problem.add_step(StaticStep(name="load"))step.add_uniform_forcefield(nodes=beam.find_closest_nodes_to_point((2000, 0, 0)), z=-1000)step.add_field_outputs([disp := DisplacementFieldResults()])
problem.analyse_and_extract(path="output")print(disp.get_min_result("z").z) # the same line for every solverWhy one language
Section titled “Why one language”- Your AI works in one representation. It learns one API, checks one kind of model and reads one kind of result, instead of a dialect per solver. The reference it reads is generated from the code, so what it writes runs.
- The model is readable. A script says what the structure is, in an engineer’s terms: parts, sections, supports, loads, steps. Anyone can review it, change it and run it again.
- The solver is a choice, not a rewrite. Moving a model to another solver is a matter of which solver plugin writes its input, not of rewriting the model.
Where the solver comes in
Section titled “Where the solver comes in”Between the model and the solver sits the conversion: writing the solver’s input from the model. It is the only solver-specific step, and it is done by that solver’s plugin on xfea’s service:
flowchart TB A["Your script<br/>(the model)"] -->|"definition: no mesh"| B["Solver plugin<br/>on xfea's service"] B -->|"how to write the input"| C["Input file,<br/>written here"] C --> D["Your solver,<br/>on your machine"] D --> E["Results database,<br/>the same for every solver"]
- The model is split into its definition (parts, sections, materials, supports, loads, steps) and its tables (nodes, elements, sets). Only the definition is sent: kilobytes, whatever the model’s size.
- The plugin returns a plan: the solver’s input with places for the tables, which your machine fills in.
- Your solver runs on your machine, and its results are read into the results database, in xfea’s own form.
The mesh and the results never leave your machine. Subscribing to a solver’s plugin is what your xfea account is for: see What’s free, what needs an account.
What this means in practice
Section titled “What this means in practice”- What a model can describe is xfea’s API, not one solver’s feature list. Where a solver can’t do something the model asks for, its plugin says so, before the solve, rather than writing something else.
- What a solver would get wrong without saying so is checked before every solve: see Checking a model.
- Results are read the same way for every solver: see Results.
- Parts, geometry and meshing: the structure itself.
- Architecture: what runs where, in detail.
© 2026 Francesco Ranaudo · Text and pictures CC BY 4.0 · Code Elastic License 2.0 · how to reuse them