1 Introduction

Designing a nanomaterial with prescribed thermal properties is critical to many applications, such as heat management and thermoelectrics (Vineis et al. 2010; Cahill et al. 2003). However, heat-conduction optimization in nanostructures remains challenging: Fourier’s law breaks down (Chen 2021), heat transport becomes nonlocal, and standard topology-optimization methods (Sigmund and Maute 2013) for diffusive theories (Dede 2009; Haertel et al. 2015) are not readily applicable. An early study (Evgrafov et al. 2009) developed the adjoint phonon Boltzmann transport equation (BTE) to design a material with a prescribed difference of temperature between two given points; in Ref. Evgrafov et al. (2009), the local material density was related to the bulk phonon mean-free-path (MFP), a method that was proven successful for boundary conditions applied to influx phonon flux. However, such an approach is not suitable when shape optimization includes arbitrary adiabatic boundaries, a scenario that presents a challenge on its own: How to interpolate a material so that phonons are scattered back isotropically at adiabatic walls (assuming diffuse boundaries), while also recovering the no-interface limit for uniform densities? We tackle this challenge by introducing the “transmission interpolation method” (TIM). The key concept behind TIM is that instead of relating the local density to volume-based parameters, such as the MFP, TIM paremetrized the material density in terms of phonon interfacial transmission.

In our implementation, we combine a BTE solver (Sec. 1) with TIM (Sec. 2), and chained them into a reverse-mode automatic differentiation pipeline (Bradbury et al. 2018), which also includes density filtering and projection (Sigmund and Maute 2013) (Sec. 3). We apply our methodology to obtain new solutions to two exemplary problems: designing an anisotropic thermal-conductivity tensor in a periodic nanomaterial (Sec. 4) and, for thermoelectric applications (Vineis et al. 2010), minimizing thermal transport while simultaneously maintaining high electrical conductivity (Sec. 5). (To the latter end, we assume charge transport to be diffusive and thus implement an differentiable Fourier solver.) Several technical aspects, including the matrix-free solution of the BTE solver and the relationship between its forward and adjoint counterparts, are reported in the Appendices. The code developed for this work will be released in the OpenBTE package (Romano 2021a).

Nondiffusive thermal transport, investigated from both theoretical (Ziman 2001) and experimental (Lee et al. 2015; Hochbaum et al. 2008; Song and Chen 2004) standpoints, has opened up exciting engineering opportunities; however, it has also made modeling heat transport computationally challenging. One key departure from familiar Fourier diffusion is that phonons must be tracked in momentum as well as position space, dramatically increasing the number of unknowns (Ziman 2001). If forward modeling is challenging, inverse design is even more difficult. In addition to Ref. Evgrafov et al. (2009), mentioned above, there have only been a few studies aiming at gradient-based optimization of nanoscale thermal transport. For example, in a recent preprint (Chen et al. 2022), the adjoint BTE was used in conjunction with experiments to estimate phonon-related material properties. However, none of these works focus on systems with arbitrary adiabatic boundaries. In the simpler diffusive regime, density-based topology optimization has been routinely applied to macroscopic heat-transport problems (Gersborg-Hansen et al. 2006; Zhang and Liu 2008; Haertel et al. 2015; Imediegwu et al. 2022; Song and Youn 2006). The basic idea of density-based topology optimization (Sigmund and Maute 2013) is that each point in space, or each “pixel” in a discretized solver, is linked to a fictitious density \(\rho (\mathbf {r})\) which is continuously varied between 0 and 1, representing two physical materials at the extremes, to optimize some figure of merit such as thermal conductivity. Filtering and projection regularization steps (Sigmund and Maute 2013) ensure that the structure eventually converges to a physical material everywhere in the design domain, and a variety of methods are available to impose manufacturing constraints such as minimum lengthscales (Zhou et al. 2015; Lazarov et al. 2016). Adjoint-based sensitivity analysis allows such huge parameter spaces to be efficiently explored (Sigmund 2011), enabling the computational discovery of surprising non-intuitive geometries. For instance, in Ref. Gersborg-Hansen et al. (2006), a heat-conducting material was designed to generate the least amount of heat under volume constraints. In that work, which mirrored the search for minimum-compliance materials for mechanical problems (Sigmund 2001), the material density at each pixel could be directly related to the local bulk thermal conductivity. In contrast, such a local relationship does not hold for the BTE. However, the BTE supports the use of transmission coefficients associated with the interfaces between dissimilar materials (Chen 2005). In our work, therefore, we turn these coefficients into intermediate variables linking the material density to the phonon distributions using our TIM approach.

2 The 2D single-MFP BTE

We are interested in computing the effective thermal conductivity tensor \(\kappa\) of a periodic nanostructure. To this end, we consider a simulation domain composed of a square with side L, to which periodic boundary conditions are applied along both axes (see Fig. 1a). To calculate, for example, \(\kappa _{xx}\), we apply a temperature jump of \(\Delta T_{\mathrm {ext}}\) = 1 K across the x-axis, and average the x-component of heat flux,

$$\begin{aligned} \kappa _{xx} = -\frac{1}{\Delta T_{\mathrm {ext}}}\int _{-L/2}^{L/2}\mathbf {J}(L/2,y)\cdot \varvec{\hat{x}}dy. \end{aligned}$$
(1)

To calculate the heat flux, we note that, at the nanoscales, heat conduction deviates from the standard Fourier law because the mean-free-path (MFP) of heat carriers, i.e. phonons, becomes comparable with the material’s feature size. This phenomenon, commonly known as classical phonon size effects (Chen 2005), can be captured by the phonon Boltzmann transport equation (BTE) (Chen 2005; Peierls 1929; Romano 2021b). There are different flavors of the BTE, depending on the needed accuracy. In this work, we use the single-MFP version of the BTE, a textbook-case also known as the gray model (Chen 2005); within this approximation, a bulk material is simply parameterized by its thermal conductivity \(\kappa _{\mathrm {bulk}}\) and MFP \(\Lambda\). We consider two-dimensional (2D) transport, i.e. phonon directions are parameterized by the polar angle \(\phi\). With these assumptions, the gray BTE reads as

$$\begin{aligned}&\Lambda \varvec{\hat{s}}(\phi )\cdot \nabla \tilde{T}(x,y,\phi ) + \tilde{T}(x,y,\phi )\nonumber \\&\quad =\frac{1}{2\pi }\int _{-\pi }^{\pi } \tilde{T}(x,y,\phi ' )d\phi ', \end{aligned}$$
(2)

where \(\tilde{T}(x,y,\phi ) = \left[ T(x,y,\phi )-T_0\right] /\Delta T_{\mathrm {ext}}\) is a deviational pseudo phonon temperature, normalized by \(\Delta T_{\mathrm {ext}}\) (in short, “phonon temperatures” throughout the text), the unknown of our problem; \(T_0\) is a reference temperature. The vector \(\varvec{\hat{s}}(\phi )=\sin {\phi }\varvec{\hat{x}}+\cos {\phi }\varvec{\hat{y}}\) is the phonon direction, illustrated in Fig. 1a. Note that the BTE is often formulated in terms of distribution function or energy density (Chen 2005; Majumdar 1993; Murthy and Mathur 1998). The temperature formulation used here is simply obtained by a change of variables (Romano and Grossman 2015). Lastly, the angular-resolved heat flux is given by

$$\begin{aligned} \mathbf {J}(x,y,\phi )=\frac{2\kappa _{\mathrm {bulk}}}{\Lambda } \tilde{T}(x,y,\phi )\hat{\mathbf {s}}(\phi ), \end{aligned}$$
(3)

with the total heat flux being \(\mathbf {J}(x,y) = \left( 2\pi \right) ^{-1}\int _{-\pi }^{\pi } \mathbf {J}(x,y,\phi ) d\phi\). Although here we employ a simplified version of the BTE, the developed methodology can be readily applied to more sophisticated versions. Combining Eqs. (1)and (3), we define the normalized effective thermal conductivity tensor, \(\bar{\kappa }_{xx} = \kappa _{xx}/\kappa _{\mathrm {bulk}}\), as

$$\begin{aligned} \bar{\kappa }_{\text{xx}} = -\frac{1}{\Lambda \pi }\int _{-\pi }^{\pi } \int _{-L/2}^{L/2} \tilde{T}(L/2,y,\phi ) \varvec{\hat{s}}(\phi )\cdot \varvec{\hat{x}}dy d\phi . \end{aligned}$$
(4)

Similarly, \(\bar{\kappa }_{yy}\) is evaluated by applying a temperature gradient along the y-axis. Throughout this work we use \(\Lambda = L\), thus neither of these two values need to be specified in absolute values. (Note that this simplification does not hold for nongray materials, where L needs to be specified in physical units.) Analogously, thanks to linearity, we don’t need to provide explicit values for \(\kappa _{\mathrm {bulk}}\) and \(T_0\). Internal boundaries of the simulation domain are modeled as diffuse hard-walls, i.e. phonons approaching the surface are scattering back isotropically (Ziman 2001; Murthy and Mathur 2002). In Sec. 2, we will describe this boundary condition as the hard-wall limit of interpolation method used to account for phonon transport in arbitrary material distribution. Equation 2 is discretized using the finite-volume approach both in real- and angular-space. The resulting linear system reads

$$\begin{aligned} \sum _{\mu ' c'} G_{\mu c}^{\mu ' c'} \tilde{T}_{\mu ' c'} = P_{\mu c}, \end{aligned}$$
(5)

where \(\mu\) and c label angular and real-space, respectively. Equation 5 is solved using a matrix-free Krylov subspace method. The expressions for the terms \(G_{\mu c}^{\mu 'c'}\) and \(P_{\mu c}\), as well as details on the iterative solution of Eq. 5, are provided in Sec. B.

Lastly, we note that in this work a Fourier solver is also used, where the temperature is only described in real-space. We will refer to the corresponding normalized effective thermal conductivity as \(\bar{\kappa }^{\mathrm {F}}\). In this case, the linear system to solve is \(\sum _{c'}A_{cc'}\tilde{T}_{c'}=b_{c}\). The expressions for \(A_{cc'}\) and \(b_c\), as all as details on gradient calculations of the Fourier solver are reported in Sec. A.

3 The transmission interpolation method

Density-based topology optimization requires a differentiable transition between material properties (Sigmund and Maute 2013); that is, one must be able to deal with arbitrary material distributions described by a fictitious density \(\varvec{\rho }\in [0,1]^N\), where N is the number of “pixels” (design degrees of freedom) in the material (Bendsoe and Sigmund 1999). Following Fig. 1b, we begin by considering an interface between two pixels, with different densities, \(\rho _1\) and \(\rho _2\). The interface between them has normal \(\varvec{\hat{n}}\) pointing toward pixel 2. Furthermore, we define the phonon temperatures in those two pixels as \(\tilde{T}_1(\phi )\) and \(\tilde{T}_2(\phi )\). Note that while we have discretized the real space, in this section we use a continuous representation for \(\phi\). In our case, a material interpolation model must satisfy two limit cases: When \(\rho _1 = \rho _2\), there should be no extra phonon scattering across their interface; on the other side, when \(\rho _1 = 0\) and \(\rho _2 = 1\), phonons must scattered back isotropically toward region 1.

A possible material interpolation model is given in Ref. Evgrafov et al. (2009), where the MFP depends on the material density through \(\Lambda ^{-1}(\rho ) = \Lambda _a^{-1}\rho + (1-\rho ) \Lambda _b^{-1}\), with \(\Lambda _a\) and \(\Lambda _b\) associated to two different phases. This approach was successfully applied for boundary conditions on incoming phonon flux. However, it may be problematic for the adiabatic hard-wall limit, as explained in the following. Adopting the approach from Evgrafov et al. (2009), the heat flux at the interface between the two pixels is

$$\begin{aligned} \mathbf {J}(\mathbf {r})\cdot \varvec{\hat{n}}= & {} \frac{2\kappa }{\pi } \left[ \frac{\rho _1}{\Lambda _a} + \frac{(1-\rho _1)}{\Lambda _b} \right] \int _{\varvec{\hat{s}}(\phi )\cdot \varvec{\hat{n}}\ge 0}\tilde{T}_1(\phi ) \varvec{\hat{s}}(\phi )\cdot \varvec{\hat{n}}d\phi +\nonumber \\+ & {} \frac{2\kappa }{\pi }\left[ \frac{\rho _2}{\Lambda _a} + \frac{(1-\rho _2)}{\Lambda _b} \right] \int _{\varvec{\hat{s}}(\phi )\cdot \varvec{\hat{n}}<0}\tilde{T}_2(\phi ) \varvec{\hat{s}}(\phi )\cdot \varvec{\hat{n}}d\phi . \end{aligned}$$
(6)

For adiabatic boundaries, we may assign \(\Lambda _a\) to the solid phase and a fictitious \(\Lambda _b = \infty\) to the void one; in this case, the second part of Eq. 6 will be zero because \(\rho _2\) = 0 but the first part (which has \(\rho _1 = 1\)) will be different than zero. Consequently, such an approach would lead to a nonzero net thermal current, while we wish to have an adiabatic surface. Note that this conclusion applies to generic adiabatic surfaces within the context of the BTE and is not tied to our choice of diffuse scattering.

To lift these limitations, we attack the problem from a different angle: We parameterize the material density via a phonon transmission coefficient t. In doing so, we borrow a methodology developed for thermal transport across dissimilar materials, where the transmission coefficient is used to impose the distributions leaving the interface (Singh et al. 2011). Specifically, we introduce the boundary conditions

$$\begin{aligned} \tilde{T}_1(\phi )=t\tilde{T}_2(\phi ) + (1-t)\tilde{T}^B_{12}, \,\,\,\,\, \mathrm {for} \,\,\phi : \varvec{\hat{s}}(\phi )\cdot \varvec{\hat{n}}< 0 \nonumber \\ \tilde{T}_2(\phi )=t\tilde{T}_1(\phi ) + (1-t)\tilde{T}^B_{21},\,\,\,\,\, \mathrm {for} \,\,\phi : \varvec{\hat{s}}(\phi )\cdot \varvec{\hat{n}}\ge 0 \end{aligned}$$
(7)

where \(\tilde{T}^B_{ij}\)  is the boundary temperature at the interface between pixels i and j, thermalizing phonons traveling into pixel i. Its expression is given by

$$\begin{aligned} \tilde{T}^B_{12} = \frac{1}{2}\int _{\varvec{\hat{s}}(\phi )\cdot \varvec{\hat{n}}\ge 0}\tilde{T}_1 (\phi )\varvec{\hat{s}}(\phi )\cdot \varvec{\hat{n}}d\phi \\ \tilde{T}^B_{21} = -\frac{1}{2}\int _{\varvec{\hat{s}}(\phi )\cdot \varvec{\hat{n}}< 0}\tilde{T}_2 (\phi )\varvec{\hat{s}}(\phi )\cdot \varvec{\hat{n}}d\phi , \end{aligned}$$
(8)

where we used \(\int _{\varvec{\hat{s}}(\phi )\cdot \varvec{\hat{n}}\ge 0}\varvec{\hat{s}}(\phi )\cdot \varvec{\hat{n}}d\phi = -\int _{\varvec{\hat{s}}(\phi )\cdot \varvec{\hat{n}}< 0}\varvec{\hat{s}}(\phi )\cdot \varvec{\hat{n}}d\phi= 2\). The term t in Eq. 7 is a transmission coefficient, which we define as

$$\begin{aligned} t = 2\frac{\rho _1\rho _2}{\rho _1+\rho _2}. \end{aligned}$$
(9)
Fig. 1
figure 1

a The simulation domain: a square centered in (0,0) and with side L. b An example of interface between two regions with different densities, where the impinging, transmitted and isotropically reflected phonon temperatures are also shown

It is straightforward to show that if either \(\rho _1\) or \(\rho _2\) is zero, then the RHS of Eq. 7 reduces to the hard-wall case. On the other side, if \(\rho _1 = \rho _2\), there will be no interface. To summarize, our parametrization does not relate the material density to a bulk-like property (such as the MFP from Ref. Evgrafov et al. (2009)), but rather to the amount of incoming flux. To distinguish this approach from traditional material interpolation methods, we name it the “Transmission Interpolation Method” (TIM). In passing, we note that transmission coefficients of the form \(t^\gamma\), with \(\gamma > 1\) would also be a suitable interpolation approach. However, investigating this more general case is outside the scope of our work. Details on the angular discretization of TIM is reported in Sec. B.

4 The optimization pipeline

In this section, we outline the method for computing \(\nabla _{\varvec{\rho }} \bar{\kappa }\), which will be used in our optimization algorithm. We begin by noting that density-based topology optimization presents two major challenges: The emergence of rapidly oscillating “checkerboard” patterns that fail to converge with increasing spatial resolution; and gray (\(0< \rho < 1\)) pixels, to which no physical material can be associated (Bendsoe and Sigmund 2003). These two issues are commonly resolved using filtering and thresholding, respectively (Sigmund and Maute 2013). As shown in Fig. 2, given a design density \(\varvec{\rho }\) (for convenience, from now on, we will work with a discretized domain), we first filter it, \(\tilde{\varvec{\rho }} = \mathbf {w}* \varvec{\rho }\), where in this case, \(\mathbf {w}\) is a conic filter with radius R,

$$\begin{aligned} w_i = {\left\{ \begin{array}{ll} \frac{1}{a}\left( 1-\frac{\mid \mathbf {c}_i\mid }{R}\right) ,&{} \mid \mathbf {r} \mid <R\\ 0, &{} \text {otherwise}. \end{array}\right. } \end{aligned}$$
(10)

In Eq. 10, a is a normalization factor (\(= \pi R^2/3\) in the continuum limit), \(\mathbf {c}_i\) is the centroid of the grid point i, and R is the radius of our filter. In this work, \(R = L/10\). The thresholding, \(\bar{\varvec{\rho }} = f_p(\tilde{\varvec{\rho }})\), is then carried out using the following function (Wang et al. 2011)

$$\begin{aligned} \bar{\varvec{\rho }}=\frac{\tanh {\beta \eta }+\tanh (\beta (\tilde{\varvec{\rho }}-\eta ))}{\tanh {\beta \eta }+\tanh (\beta (1-\eta ))}, \end{aligned}$$
(11)

where \(\eta\) and \(\beta\) are threshold parameters. The resulting field, referred here as “projected” is, therefore, used directly by the BTE solver; in this work, we use \(\eta =0.5\); the term \(\beta\), on the other side, is increased during the optimization procedure (Hammond et al. 2021), in order to guarantee a good degree of topology variability (especially early on in the optimization process) while ensuring a final binary structure.

In this work, we start with \(\beta = 2\) and double it every 20 iterations, until convergence is reached.

Once the relationship \(\bar{\varvec{\rho }}(\varvec{\rho })\) is implemented, we can use the chain rule

$$\begin{aligned} \frac{d \bar{\kappa }}{d \rho _p} = \sum _{\mu cp'}\frac{\partial \bar{\kappa }}{\partial \tilde{T}_{\mu c}}\frac{\partial \tilde{T}_{\mu c}}{\partial \bar{\rho }_{p'}}\frac{\partial \bar{\rho }_{p'} }{\partial \rho _p }+\sum _{p'} \frac{\partial \bar{\kappa }}{\partial \bar{\rho }_{p'}}\frac{\partial \bar{\rho }_{p'}}{\partial \rho _p}, \end{aligned}$$
(12)

which is evaluated using reverse-mode automatic differentiation, implemented in JAX (Bradbury et al. 2018). Specifically, for \(\partial \bar{\kappa }/\partial \bar{\rho }_p\) we use the adjoint method (Strang 2007), which allows to compute such a gradient by solving the linear system

$$\begin{aligned} \sum _{\mu 'c'} G_{\mu ' c' }^{\mu c}\tilde{T}_{\mu 'c'}^{\mathrm {adj}} = P^{\mathrm {adj}}_{\mu c}, \end{aligned}$$
(13)

with \(P^{\mathrm {adj}}_{\mu c}\) defined in Sec. B. In practice, we use the relationship

$$\begin{aligned} \tilde{T}^{\mathrm {adj}}_{\mu c} = - \tilde{T}_{-\mu c}, \end{aligned}$$
(14)

derived in Sec. B. Therefore, the adjoint solution is computed by post-processing the solution of Eq. 5, achieving a significant boost in computational efficiency.

Furthermore, as \(\nabla _{\bar{\varvec{\rho }}}\bar{\kappa }\) is available at each iteration while solving the forward problem, we adopt an early termination criteria, based on \(\bar{\kappa }\) and \(\mid \nabla _{\bar{\varvec{\rho }}}\bar{\kappa }\mid\). This approach extends Ref. Amir et al. (2010), where early termination strategies were based on the error on the objective function alone. The sensitivity of \(\bar{\kappa }\) with respect to the projected density is provided through the custom vector-Jacobian-product \(\mathrm {vJp}(a) = a \partial \bar{\kappa }/\partial \rho _p\). Lastly, we note that for the Fourier solver, the forward and adjoint solutions are related \(\tilde{T}_c^{\mathrm {adj}} = - \tilde{T}_c\), as derived in Sec. A. Similarly to the BTE case, we use this relationship to avoid solving the adjoint problem.

Fig. 2
figure 2

The design field \(\varvec{\rho }\) (in the left panel) is the optimization parameter. The filtered field \(\tilde{\varvec{\rho }}\), in the middle panel, is computed after the convolution with a conic filter, with Kernel defined in Eq. 10. The projected filter \(\bar{\varvec{\rho }}\), in the right panel, obtained with Eq. 11, is the input to the BTE

5 Case I: tailoring the effective thermal conductivity tensor

In this section, we show an example of how topology optimization may be employed to design a periodic material with a prescribed effective thermal conductivity tensor, \(\tilde{\kappa }\), and with a porosity larger than \(\tilde{\varphi }\). To this end, we define the objective function

$$\begin{aligned} g(\varvec{\rho }) =\mid \bar{\kappa }(\varvec{\rho }) - \tilde{\kappa }\mid _{\mathrm {Fro}} = \sqrt{\Delta \kappa _{xx}(\varvec{\rho })^2 +\Delta \kappa _{yy}(\varvec{\rho })^2 }, \end{aligned}$$
(15)

where \(||.||_{\mathrm {Fro}}\) is the Frobenius norm, and \(\Delta \kappa _{ii}(\varvec{\rho }) = \bar{\kappa }_{ii}(\varvec{\rho })-\tilde{\kappa }_{ii}\). The effective thermal conductivity tensor,

$$\begin{aligned} \bar{\kappa }(\varvec{\rho }) = \begin{pmatrix} \bar{\kappa }_{xx}(\varvec{\rho }) &{} 0 \\ 0 &{} \bar{\kappa }_{yy}(\varvec{\rho }) \end{pmatrix} \end{aligned},$$
(16)

is evaluated by solving Eq. 2, for each perturbation direction, after filtering and projecting. The sensitivity of the objective function is

$$\begin{aligned} \nabla _{\varvec{\rho }}g(\varvec{\rho }) = g(\varvec{\rho })^{-1}\left[ \Delta \kappa _{xx}(\varvec{\rho })\nabla _{\bar{\varvec{\rho }}}\bar{\kappa }_{xx}(\varvec{\rho }) +\Delta \kappa _{yy}(\varvec{\rho })\nabla _{\varvec{\rho }}\bar{\kappa }_{yy}(\varvec{\rho })\right] , \end{aligned}$$
(17)

where the terms \(\nabla _{\varvec{\rho }}\bar{\kappa }_{ii}(\varvec{\rho })\) are computed using Eq. 12. The above discussion allows us to lay out the optimization algorithm

$$\begin{aligned}&\min _{\varvec{\rho }}g(\varvec{\rho })\nonumber \\&\quad 0 \le \varvec{\rho }\le 1 \nonumber \\&\quad \mathrm {s.t.} \sum _n \bar{\rho }_n \le (1- \tilde{\varphi }) N, \end{aligned}$$
(18)

where N is the number of pixels. In this section, the chosen porosity is \(\tilde{\varphi } = 0.25\). As the optimizer, we use an open-source implementation (Johnson 2014) of the method of moving asymptotes (MMA) (Svanberg 2002), which converges globally (i.e. it guarantees to find a local minimum from every starting point).

As a first example, we choose \(\tilde{\kappa }_{xx}=\tilde{\kappa }_{yy} = 0.15\). To ensure mesh convergence on a particular local minimum, we use the following algorithm:

  1. 1.

    Optimize a structure at a coarse resolution using a random configuration as the initial structure.

  2. 2.

    Upsample the optimal structure by doubling the resolution.

  3. 3.

    Optimize a structure using the configuration created in step 2 as the first guess. Note that the filter’s radius does not change in physical units, but doubles in pixel units.

  4. 4.

    Repeat from step 2.

Figure 3 illustrates the optimized structures for grid sizes \(N=10\times 10, 20\times 20,40\times 40\) and \(80\times 80\). For both the Fourier and BTE cases, a shape convergence is achieved. For the rest of this study we adopt a grid of \(60\times 60\), using a random configuration as a first guess. A striking differences between the two solvers is that for the BTE case the pattern is coarser. In fact, phonon size effects are known to be more effective than macroscopic reduction with the same geometric constraints (Sharvin 1965).

We now turn to the design an anisotropic material. Thermal anisotropy may be induced by boundary engineering, even though the base material is isotropic. Symmetry-breaking boundaries are effective at all scales, although it has been shown numerically that nanostructuring may enhance anisotropy with respect to the macroscopic counterpart (Romano and Kolpak 2017). In this example, we choose \(\bar{\kappa }_{xx} = 0.3\) and \(\bar{\kappa }_{yy} = 0.1\), with the resulting anisotropy \(\bar{\kappa }_{xx}/\bar{\kappa }_{yy}= 3\).

Fig. 3
figure 3

The optimized structures using the Fourier solver, for grid size a \(20\times 20\), b \(40\times 40\), c \(60\times 60\) and d \(80\times 80\). Similarly, the final structures for the BTE case are illustrated in (e), (f), (g) and (h). The dotted square represent the unit cell, whose width is \(L=\Lambda\). The filter’s radius is \(R=L/10\)

Fig. 4
figure 4

a The optimized structure after solving Eq. 18, e The evolution of the effective thermal conductivity tensor. The dotted lines are the desired value of the two components, d the evolution of the porosity. The dotted line is the lower bound imposed by the inequality constraint. Normalized magnitude of thermal flux when the gradient is applied along the x-axis (b) and y-axis (c)

Convergence is reached within 100 iterations. The final structure, shown in Fig. 4a, is made by two types of pores, which block heat along y more effectively than along x. This effect is exemplified by the magnitude of thermal flux shown in Fig. 4b and c, for \(\bar{\kappa }_{xx}\) and \(\bar{\kappa }_{yy}\), respectively. Note that the final values obtained with Fourier’s law are \(\bar{\kappa }^F_{xx}\approx\) 0.61 and \(\bar{\kappa }^F_{yy}\approx\) 0.46, with anisotropy 1.33, well below the prescribed value.

6 Case II: maximixing phonon scattering

In thermoelectric applications it is desirable to minimize thermal transport while not degrading the electrical conductivity (Rowe 2018) (\(\sigma\)). In fact, the thermoelectric figure-of-merit is given by \(ZT=T S^2\sigma /\kappa\), where S is the Seebeck coefficient. In highly doped semiconducting nanostructures, these conditions can be met simultaneously due to the short phonon MFP compared to that of the electrons (Vineis et al. 2010; Qiu et al. 2015). If the MFPs of the electrons are much shorter than the material’s characteristic length, we may assume diffusive electronic transport. Consequently, minimizing the thermal conductivity while maintaining high diffusive transport is beneficial to ZT. Furthermore, in order to understand phonon scattering, most studies focus on the value of the effective thermal conductivity compared to that obtained with Fourier’s law (Tang et al. 2010; Lee et al. 2017). In passing, we note that macroscopic geometrical effects, often referred to as “porosity factor” (Verdier et al. 2017), in some cases have analytical solutions. For example, in aligned porous systems with circular pores and porosity \(\varphi\), it has the analytical solution \(\bar{\kappa }^{\mathrm {F}}=(1-\varphi )/(1+\varphi )\) (Hasselman and Johnson 1987). We choose as baseline a porous material with staggered pores of circular shape (Romano and Grossman 2014; Song and Chen 2004; Anufriev and Nomura 2020), as shown in Fig. 5a. The chosen porosity is \(\varphi =0.5\), to which it corresponds the isotropic tensors \(\bar{\kappa }^{F}\approx 0.31\) and \(\bar{\kappa }\approx 0.049\). The goal of our optimization is, therefore, to achieve \(\bar{\kappa } < 0.049\) under the constraint \(\bar{\kappa }^{F} \ge 0.31\); furthermore, we require \(\bar{\kappa }\) to be isotropic. We use this baseline configuration as a first guess for our optimization algorithm, solving the problem:

$$\begin{aligned}&\min _{\varvec{\rho }} g(\varvec{\rho }) \end{aligned}$$
(19)
$$\begin{aligned}&\quad 0 \le \varvec{\rho }\le 1 \nonumber \\&\mathrm {s.t.}\,\,\, \bar{\kappa }^F_{xx}(\varvec{\rho }) \ge 0.31 \end{aligned}$$
(20)
$$\begin{aligned}&\mathrm {s.t.}\,\,\, \bar{\kappa }^F_{yy}(\varvec{\rho }) \ge 0.31, \end{aligned}$$
(21)

where

$$\begin{aligned}&g(\varvec{\rho }) = \frac{1}{\sqrt{2}} \sqrt{\left( \bar{\kappa }_{xx}-\bar{\kappa }_{yy}\right) ^2 + \bar{\kappa }_{xx}^2 + \bar{\kappa }_{yy}^2}\nonumber \\&\quad =\sqrt{\bar{\kappa }_{xx}^2+\bar{\kappa }_{yy}^2-\bar{\kappa }_{xx}\bar{\kappa }_{yy}}, \end{aligned}$$
(22)

is the cost function to be minimized. We run this optimization problem with \(\gamma = 3\) (see Sec. A), (smaller values would mostly lead to stagnation). Convergence is reached in 200 iterations, as shown in Fig. 5e. Remarkably, the optimized structure, shown in Fig. 5b, has an isotropic tensor of \(\bar{\kappa }\approx 0.011\), roughly 4.25 times smaller than that of the baseline; yet, \(\bar{\kappa }^{F}\) is right above the imposed constrain. The final porosity is 0.63. We point out the presence of small pores that are one or two pixels in size; to realize a structure that is more amenable from a manufacturing standpoint, we fill these small regions with solid phase, while making sure that the performance is not degraded (both \(\bar{\kappa }\) and \(\bar{\kappa }^{F}\) are within 1% of those of the unpolished structure). The polished configuration is shown in Fig. 5d. In passing, we note that it is possible to impose minimum-linewidth and minimum-linespacing conditions by adding differentiable inequality constraints to the optimization algorithm (Hammond et al. 2021; Zhou et al. 2015), and in the future we plan to optimize the design for specific manufacturing processes in this way. Lastly, we recall that diffusive transport is scale-free, thus in principle we can begin from the staggered configuration and scale it down until we reach the same \(\bar{\kappa }\) obtained from the optimization. However, such a configuration would be much more challenging to be manufactured (it would have several smaller pores) than the one depicted in Fig. 5.

The optimized structure can be analyzed either from the void or the solid regions’ point of view. In the former case, we have staggered pores with smaller void regions in between. More interestingly, from the solid regions’ perspective we note a regular pattern of islands interconnected via three thin bridges on four opposite sides. As shown in Fig. 5c and as a consequence of energy conservation, heat flux peaks over these connections. The emergence of such a topology can be analyzed in terms of transport across a single orifice of width a. This problem was first investigated by Maxwell (Maxwell 1873) in the diffusive regime, showing that the thermal resistance is proportional to 1/a; on the other side, Sharvin (Sharvin 1965) predicted that in the ballistic regime, i.e. for \(\Lambda<< a\) (such as in our case), the resistance goes as \(\Lambda /a\). Thus, it is clear that thin channels are a promising platform for decoupling diffusive and nondiffusive transport. Both the abovementioned approximations assume infinite leads. A very recent study (Spence and Moore 2022), however, investigates heat transport across a single Si-based orifice using the BTE within a Monte-Carlo framework, revealing a significant role of the geometry of the orifice and leads (i.e. the structures attached to the two ends of the channel) on the overall thermal resistance. Our optimization approach, therefore, automatically identifies a structure featuring orifices, while concurrently optimizing the geometries of the leads.

Fig. 5
figure 5

The a initial, b optimized and d polished structure in relation to the optimization problem described by Eq. 19. e The evolution of \(\bar\kappa\) and \({\bar\kappa}^{\mathrm {F}}\). c The normalized magnitude of flux when a temperature gradient is applied along the x-axis

7 Conclusions

In this work, we develop a model, termed the Transmission Interpolation Model (TIM), that is able to smoothly interpolate material properties in the context of nondiffusive heat transport. The key concept behind TIM is that instead of linking a volume-based quantity to the material density, e.g. the bulk thermal conductivity, it parametrizes an interfacial transmission coefficient. Using this approach, TIM recovers the adiabatic hard-wall and no-interface limits. We first apply our methodology to tailoring the effective thermal conductivity tensor of a nanomaterial, with potential application in thermal management and routing. Then, we maximize classical size effects while keeping the diffusive transport above a certain threshold, achieving a fourfold improvement with respect to commonly studied staggered configurations. The latter result may have an impact on thermoelectric materials, as explained in the previous section.

While we have employed a single-MFP model, the developed methodology, along with the interpolation material models, can be readily applied to more sophisticated versions of the BTE. Possible future directions include using the recently developed anisotropic MFP-BTE (Romano 2021b); such an approach would allow modeling a real material using first-principles calculations while taking into account the interplay of phonon-focusing effects and, for example, the possible channels arising during optimization. Another possible extension includes optimizing thermal transport in 2D materials described by the full-scattering operator (Chiloyan et al. 2021; Romano 2020).