Table of Contents
Fetching ...

Differentiating through binarized topology changes: Second-order subpixel-smoothed projection

Giuseppe Romano, Rodrigo Arrieta, Steven G. Johnson

TL;DR

This work addresses the non-differentiability issue in density-based topology optimization during topology changes by introducing SSP2, a second-order, Hessian-regularized extension of the existing SSP1 method. SSP2 defines a distance $d_2(\boldsymbol{x}) = \frac{\eta - \tilde{\rho}(\boldsymbol{x})}{\sqrt{\|\nabla \tilde{\rho}(\boldsymbol{x})\|^2 + \hat{R}^2 \lVert\mathbf{H}(\boldsymbol{x})\rVert_F^2}}$ and a Hessian-augmented update for projection, yielding a twice-differentiable projected density during topology changes while remaining quasi-binary elsewhere. Across thermal and photonic problems, SSP2 demonstrates faster convergence in connectivity-dominant scenarios and comparable performance otherwise, enabling the use of optimization algorithms with stronger theoretical guarantees (e.g., interior-point methods). Importantly, SSP2 adds minimal computational overhead and can serve as a drop-in replacement for SSP1 in existing TopOpt workflows, broadening the practical toolkit for topology optimization.

Abstract

A key challenge in topology optimization (TopOpt) is that manufacturable structures, being inherently binary, are non-differentiable, creating a fundamental tension with gradient-based optimization. The subpixel-smoothed projection (SSP) method addresses this issue by smoothing sharp interfaces at the subpixel level through a first-order expansion of the filtered field. However, SSP does not guarantee differentiability under topology changes, such as the merging of two interfaces, and therefore violates the convergence guarantees of many popular gradient-based optimization algorithms. We overcome this limitation by regularizing SSP with the Hessian of the filtered field, resulting in a twice-differentiable projected density during such transitions, while still guaranteeing an almost-everywhere binary structure. We demonstrate the effectiveness of our second-order SSP (SSP2) methodology on both thermal and photonic problems, showing that SSP2 has faster convergence than SSP for connectivity-dominant cases -- where frequent topology changes occur -- while exhibiting comparable performance otherwise. Beyond improving convergence guarantees for CCSA optimizers, SSP2 enables the use of a broader class of optimization algorithms with stronger theoretical guarantees, such as interior-point methods. Since SSP2 adds minimal complexity relative to SSP or traditional projection schemes, it can be used as a drop-in replacement in existing TopOpt codes.

Differentiating through binarized topology changes: Second-order subpixel-smoothed projection

TL;DR

This work addresses the non-differentiability issue in density-based topology optimization during topology changes by introducing SSP2, a second-order, Hessian-regularized extension of the existing SSP1 method. SSP2 defines a distance and a Hessian-augmented update for projection, yielding a twice-differentiable projected density during topology changes while remaining quasi-binary elsewhere. Across thermal and photonic problems, SSP2 demonstrates faster convergence in connectivity-dominant scenarios and comparable performance otherwise, enabling the use of optimization algorithms with stronger theoretical guarantees (e.g., interior-point methods). Importantly, SSP2 adds minimal computational overhead and can serve as a drop-in replacement for SSP1 in existing TopOpt workflows, broadening the practical toolkit for topology optimization.

Abstract

A key challenge in topology optimization (TopOpt) is that manufacturable structures, being inherently binary, are non-differentiable, creating a fundamental tension with gradient-based optimization. The subpixel-smoothed projection (SSP) method addresses this issue by smoothing sharp interfaces at the subpixel level through a first-order expansion of the filtered field. However, SSP does not guarantee differentiability under topology changes, such as the merging of two interfaces, and therefore violates the convergence guarantees of many popular gradient-based optimization algorithms. We overcome this limitation by regularizing SSP with the Hessian of the filtered field, resulting in a twice-differentiable projected density during such transitions, while still guaranteeing an almost-everywhere binary structure. We demonstrate the effectiveness of our second-order SSP (SSP2) methodology on both thermal and photonic problems, showing that SSP2 has faster convergence than SSP for connectivity-dominant cases -- where frequent topology changes occur -- while exhibiting comparable performance otherwise. Beyond improving convergence guarantees for CCSA optimizers, SSP2 enables the use of a broader class of optimization algorithms with stronger theoretical guarantees, such as interior-point methods. Since SSP2 adds minimal complexity relative to SSP or traditional projection schemes, it can be used as a drop-in replacement in existing TopOpt codes.
Paper Structure (10 sections, 34 equations, 4 figures, 1 table)

This paper contains 10 sections, 34 equations, 4 figures, 1 table.

Figures (4)

  • Figure 1: (a) The projection for $\beta = \infty$ and far interfaces. (b) The projections for $\beta = \infty$ and $\alpha = \eta$. The insets show the (left) first and (right) second derivative of $\hat{\rho}_{2}$, (c) A comparison between $\hat{\rho}_{1}$ and $\hat{\rho}_{2}$ versus $\alpha$. At $\alpha=\eta=0.5$, $\hat{\rho}_{1}$ presents a discontinuity. The insets show the (left) first and (right) second derivative of $\hat{\rho}_{2}$. (d) The projections for $\beta=64$ and $\alpha = \eta$. The insets show the (left) first and (second) derivative of the SSP2 projection. In (a), (b) and (c), the $x$-axis is the normalized position $\hat{x} = x/\hat{R}$.
  • Figure 2: (a) The cumulative convergence ratio for unconstrained optimization, i.e., the number of converged cases over the total number of samples (100). A case is defined "converged" if the loss function falls below $10^{-7}$ within 150 steps. (b) Convergence for an example where SSP2 converges and SSP1 does not, and the corresponding optimized structures for (c) SSP1 and (d) SSP2. (e) The cumulative convergence ratio when lengthscale are activated, with the total number of samples of 40. (f) Convergence for an exemplary case spanning both the unconstrained and constrained phase. The constraint function is also shown. (e) The first guess used for constrained optimization for both projections, and (h) the optimized structure obtained by SSP2 (SSP1 gives a nearly identical structure). The inset shows the (top) imposed lengthscales (for both the void and solid phase), and the obtained one for solid (center) and void (phase) phase.
  • Figure 3: (a) Normalized cumulative convergence for a set of 100 optimizations of thermal transport in composite materials. Both SSP1 and SSP2 converge in all cases with comparable performance. (b) Example of convergence for both methods starting from the same random initial guess, and the corresponding optimized structures for the (c) SSP1 and (d) SSP2 cases.
  • Figure 4: (a) The number of samples achieving a loss function $<1$ within a given number of iterations ($x$-axis) (b) An example of convergence trajectory for both approaches, using the same initial guess and their corresponding optimized structure for (c) SSP1 and (d) SSP2.