Skip to content

Sliced Tensor Operators for Large-Scale Topology Optimization

Pedro Zuidberg Dos Martires, Gustavo Assis da Silva

cs.CE

Abstract

Large-scale three-dimensional topology optimization is constrained by both the cost of repeatedly solving the governing finite-element equations and the memory required by these computations. Memory consumption can be controlled through specialized low-level implementations, but developing, optimizing, and extending such code requires substantial effort and hardware-specific expertise. High-level tensor programming frameworks, which support automatic differentiation, offer an attractive alternative: numerical operations can be expressed compactly, while their compilers generate highly optimized code for CPUs and GPUs. However, a direct tensor formulation creates intermediate arrays that can quickly exhaust the available memory. We address this limitation through memory-bounded tensor operators for matrix-free finite-element analysis and Galerkin multigrid. The fine-grid stiffness action is evaluated in overlapping spatial slices, and on coarse grids, the Galerkin operator is retained in a factorized representation consisting of fine-grid stiffness interpolation coefficients and precomputed local operators. This representation permits its action to be evaluated without materializing a spatially varying stiffness operator on every coarse grid, while preserving the exact Galerkin hierarchy. We implement these formulations in topax, a modular JAX library for two- and three-dimensional density-based topology optimization supporting CPUs and GPUs. On a single NVIDIA GH200, topax performs 50 design iterations for a problem with more than 809 million displacement degrees of freedom in approximately 24.524.5 minutes. Across the common GPU benchmark, it is up to 13.613.6 times faster than the fastest competing implementation and uses less than half the device memory for the largest problem.

Create a lesson