Manuscript Offprint
arXiv:2610.33133Physics Informed Neural Networks for Solving the Drift-Diffusion Equations
Luke Ragan
Department of Electrical & Computer Engineering,
Boston University
Boston, MA, USA
Enrico Bellotti
Department of Electrical & Computer Engineering,
Division of Materials Science & Engineering,
Boston University, Boston, MA, USA
Matteo G.C. Alasio
Dipartimento di Elettronica e Telecomunicazioni,
Politecnico di Torino,
Torino, TO, Italy
Luca Dal Negro
Department of Electrical & Computer Engineering,
Division of Materials Science & Engineering,
Physics Department, and Photonics Center
Boston University, Boston, MA, USA
ABSTRACT
The drift-diffusion equations are the fundamental building block for the modeling, design, and optimization of modern semiconductor devices. Solutions of the drift-diffusion equations rarely give way to analytical forms, and exhibit strong nonlinearity, with the solutions ranging over several orders of magnitude. These attributes have led to research into numerical solvers, and while many commercial Technology Computer Aided Design (TCAD) packages now exist, they may require long simulation times, exhibit sensitivity to initial guesses, and rely on mesh generation. Further, these solvers are not well suited for inverse problems where the design parameters of a device are retrieved from its desired functional characteristics. To address all these challenges, this work demonstrates the usage of Physics Informed Neural Networks (PINNs) for the solution of the drift-diffusion equations with errors comparable to traditional simulation software using advanced training techniques to solve problems beyond the well-behaved equilibrium regime. For this study, we specifically choose an abrupt PN-junction in both one and two dimensions that features extreme gradients of the carrier concentrations at the Ohmic contacts and an abrupt discontinuity in the doping profile. Using the proposed PINN architecture, we are able to retrieve accurate results for all observables under all bias conditions. Additionally, we apply the PINN solver towards the inverse problem of retrieving doping profiles directly from desired electric field distributions or electrostatic potentials under non-zero applied biases. Our work establishes a powerful PINNs-based approach for semiconductor device modeling with the ability to solve inverse problems under non-equilibrium conditions for microelectronics research and discovery.
Keywords Neural Networks · Drift-Diffusion · Semiconductor Modeling · Inverse Problems
1 Introduction
The use of semiconductor materials is ubiquitous throughout modern life, where they are essential for integrated circuits, optoelectronic systems, power management technologies, and many other areas in the field of microelectronics [1]. Accurately modeling the transport of charge carriers in semiconductors on the microscale is essential for predicting device performance, energy efficiency, and noise parameters [2]. Such modeling is used in computing, communications, sensing technologies, and more. [3–5]
The semiconductor device industry only continues to scale and push towards more complex device geometries [6]. As a result, modeling of semiconductors is essential, both for incorporating microscale effects and also to reduce prototyping and development costs. The governing set of equations for a large number of device geometries and scales are the drift-diffusion equations [7]. These equations are a set of coupled elliptic partial differential equations (PDEs) that describe the electrostatic potential and carrier transport throughout a device. The drift-diffusion model is utilized by the majority of commercial Technology Computer Aided Design (TCAD) software. The model consists of Poisson and continuity equations. Together with boundary conditions, they are able to determine a physical solution and predict both microscopic quantities, like the electrostatic potential and carrier densities, as well as macroscopic quantities, like the current at the terminals. Due to the inherent nonlinearity of these equations, analytical solutions are rarely possible and numerical methods are required [7–9].
Several large TCAD software packages, such as Synopsys TCAD Sentaurus [10], Silvaco Atlas [11], and COMSOL Multiphysics [12] rely on Finite Element Method (FEM) or Finite Volume Method (FVM) solvers. These tools are able to solve the drift-diffusion equations accurately for a large number of geometries and materials, represent the current state-of-the-art, and are used extensively in industry and academia for the design and optimization of semiconductor devices.
However, FEM and FVM methods are known to be dependent on initial guesses [9], mesh generation [13], and long run times. These problems are particularly clear when considering complex device geometries in higher dimensions. Importantly, these solvers are also not well-suited for inverse design problems, where device parameters are retrieved from desired performance characteristics, such as the spatial distribution of the electric field inside the device.
These challenges motivate the introduction of an alternative Physics Informed Neural Networks (PINNs) [14] computational approach that is capable of accurately solving both forward and inverse problems in the strongly coupled nonlinear problems that arise beyond the well-characterized equilibrium condition [15]. The PINN methodology utilizes neural networks and automatic differentiation to solve complex partial differential equations that arise in many engineering contexts [16–22]. By identifying the output of the neural network as the surrogate solution of the PDE, PINNs leverage automatic differentiation techniques to accurately calculate the residuals of the equations up to machine precision at collocation points distributed throughout the solution domain. The residuals of the PDE and its boundary conditions are incorporated into loss functions with suitable error norms and minimized using standard gradient-based optimization techniques [14]. By training the neural network to minimize these losses, PINNs retrieve solutions that accurately satisfy the differential constraints of the physical problem while minimizing the error norms of the residuals, effectively solving the original PDE subject to the boundary conditions. This method has been demonstrated in a variety of different fields ranging from fluid mechanics to nanophotonics to phonon transport [17, 19, 20, 22–24].
PINNs have several characteristics that set them apart from traditional TCAD solvers. To begin, PINN is a mesh-free method. While recent works have shown that PINN benefits from more regularly spaced samples, the solver is not restricted to keeping the same points throughout training or ensuring that a specific feature has a higher density of points. In fact, methods such as residual-based adaptive sampling (RAD) can be used to allow the solver itself to pick the points of the most interest instead of assigning them beforehand [25]. Second, PINNs are not sensitive to parameter shifts, noisy data, or initial guesses. The networks in PINNs are randomly initialized and then the expressivity of the network is able to find the correct solution through optimization. Third, PINNs feature unique advantages when scaling to higher dimensions. Lastly, by training on available data, PINNs can minimize additional loss terms embedding unknown PDE parameters, thus efficiently solving inverse problems on the same footing of forward problems. Importantly, PINNs have been shown to be effective at solving inverse problems under noisy conditions [19, 26, 27]. For the drift-diffusion equations, these unique features of PINNs open the way to efficient design of complex device structures and time-dependent problems beyond the reach of traditional simulation methods.
There have been several attempts to apply PINNs towards semiconductor device modeling in previous works. Petrosyan and Yepiskoposyan created a hybrid technique to couple PINN with traditional solvers to drastically speed up the convergence time [28]. Chankla et al. utilized PINNs with an additional training dataset for modeling SiC MOSFETs [29]. Cai et al. produced a one-dimensional PINN solver for a pn-junction [30], and Riganti et al. solved the drift-diffusion equations for an abrupt doping profile with extensions in 2D and inverse problems but was limited to equilibrium conditions [15].
In this paper, we demonstrate accurate solutions to both forward and inverse problems that arise far from the equilibrium condition and report marked advances in using PINNs for semiconductor device modeling. Through advances to the training process and PINNs architecture, we are able to solve the drift-diffusion equations for a pn-junction with an abrupt doping profile under any bias condition. Further, we show that our PINNs methodology can be extended to model two dimensional geometries and inverse problems.
This work is a significant step forward towards developing a general PINN-based solver that can be used for the automatic design of semiconductor devices and the discovery of new and more effective geometries in desired material platforms. Our solver overcomes limitations that plague both previous PINN frameworks and traditional solver methods.
2.1 The Poisson Drift-Diffusion Equations
We consider the steady-state drift-diffusion equations
Here Eq. 1 is the Poisson equation, Eqs. 2 and 3 are the continuity equations, and Eqs. 4 and 5 relate the current densities to the carrier concentrations and electrostatic potential. Here n and p are the electron and hole carrier densities respectively. R represents the recombination term. For the purposes of our results, the Shockley-Read-Hall recombination term will be used, is the electrostatic potential, and and are the electron and hole current densities.
From [7], the variables are rescaled by defining , where L is the characteristic length of the device, is the thermal voltage, and the normalized quasi-Fermi levels are , , , we rewrite the equations for a one-dimensional (1D) case as follows:
The normalized quantities used here are summarized in Table 1. The use of the variables , , and as the outputs
Table 1: Normalized quantities in the drift-diffusion equations.
| Quantity | Definition |
|---|---|
| Thermal voltage | |
| Reference density | |
| Intrinsic density | |
| Electron density | |
| Hole density | |
| Electron current density | |
| Hole current density | |
| Debye length | |
| Poisson coefficient | |
| Electron recombination coefficient | |
| Hole recombination coefficient | |
| Electron SRH rate | |
| Hole SRH rate |
of the neural network is referred to as the quasi-Fermi level formulation. In contrast with formulations with the log scaled carrier densities, the quasi-Fermi levels are bound within a smaller range and have a simpler functional shape, making the approximation through neural networks more accurate and efficient. However, while the quasi-Fermi level formulation offers significant advantages over log scaled carrier formulations, our network architecture additionally utilizes the Slotboom variables to improve the overall accuracy under forward bias. The Slotboom variables, which are designed to eliminate the nonlinearities and nearly diverging gradients in the quasi-Fermi levels, are defined from [31] as and in Eqn. 9.
In order to scale the Slotboom variables in the optimal range for PINN, we normalize them normalized by their boundary values to ensure they always range between in the interval. The normalized variables and are specified in Eq. 10
By utilizing the Slotboom variables, the charge carrier densities and current densities are able to be calculated with the following relations:
The normalized Slotboom variables take the values 0 and 1 at the two Ohmic contacts for any bias, which removes the bias-dependent scale of and (which span the range ) from the network outputs. Because the currents are linear in and , the continuity equations become linear second-order equations in the Slotboom variables for a given potential.
2.2 Boundary Conditions
Two types of boundaries appear in the devices considered here. At an Ohmic contact the semiconductor is assumed to be in local thermal equilibrium and electrically neutral. With the voltage applied to the contact, this fixes the potential and both quasi-Fermi levels,
where L denotes the value at s = 0 on the p-type region and R denotes the value at s = 1 on the n-type region. Here
is the built-in potential in units of (for the symmetric junctions considered here, ). In terms of the normalized Slotboom variables, Eq. (13) means at one contact and at the other. In higher dimensions, additional boundary conditions must be added on the other edges of the device. Insulating (Neumann) boundary conditions are imposed on every boundary that is not an Ohmic contact. These conditions force no current to leave the device (Eq. (15)) and the normal component of the electric field to vanish at the boundary (Eq. (16)),
where is the outward normal. In one dimension both ends of the device are Ohmic contacts and no Neumann (isolating) boundaries exist. The Ohmic conditions are imposed exactly by the construction of the network outputs (hard boundary conditions, Sec. 2.3.1), so they require no loss terms. The Neumann conditions in two dimensions are imposed as an additional penalty term within the total loss function by evaluating the boundary condition at points along the geometrical edge of the device (Sec. 2.4).
2.3 Network Architecture
Figure 1 shows the structure of the developed PINN solver. Each unknown ( and the two carrier variables, , or , ) is represented by its own fully connected network. Each network has 5 hidden layers of 32 units with sigmoid activations and a linear output, and takes the normalized position as input (s in 1D problems, x and y in 2D). The networks are coupled only through the residuals of the governing equations. A systematic study of 2–6 hidden layers and 8–128 units per layer showed that the networks are the smallest architecture that is accurate for all observables at all biases tested; shallow networks (2–3 layers) frequently failed to converge. All networks are trained with the Adam optimizer [32] ( ) in double precision, with a learning rate that decays from to on a cosine schedule over the full training. The baseline training uses 30 000 epochs; the errors saturate after 20 000–30 000 epochs and any training beyond this point produced diminishing returns.
Prediction
Loss Calculation
Optimization

Figure 1: Structure of the PINN solver. Three fully connected networks predict the electrostatic potential and the two carrier variables (the quasi-Fermi levels , or the normalized Slotboom variables , ) from the position; the Ohmic contact values are built into the outputs exactly (Sec. 2.3.1), so the loss contains no contact terms. Automatic differentiation of the outputs gives the residuals of the Poisson and continuity equations and, in two dimensions only, of the insulating (Neumann) boundary conditions, which form the loss terms , , and . In Stage 1 all networks minimize the total loss jointly; in Stage 2 (Gummel split) each network is updated only with the loss of its own equation and the boundary loss (Sec. 2.4.1).
2.3.1 Hard boundary conditions
In one dimension the Ohmic conditions are built into the outputs,
where is a stand-in for each of the unknowns, denotes the raw network output, and , are the contact values of Eq. (13). By adding this extra step to the output of the network, the boundary values are then satisfied to machine precision for any network weights. Besides removing the boundary losses and their weights, this construction provides a physically reasonable starting point: the initial potential already spans the full range between the contacts, so the carrier densities, which depend exponentially on , are of the correct order of magnitude from the first epoch.
In 2D the contacts are segments of the boundary, and the linear interpolation is replaced by a distance-function construction,
where is any of the three unknowns, and its values at the Anode and Cathode, and , smooth approximate distances to the two contact segments, constructed with R-functions [33]. The blending function is one on the Anode and zero on the Cathode, and vanishes on both contacts, so the contact values are again exact.
2.4 Training Procedure
The total loss is the sum of the mean square residuals of the governing equations at the collocation points (s is used in 1D, x and y in 2D) and of the insulating boundary conditions at the boundary points ,
with
Note that , will take the place of , in (15) when the Slotboom formulation is used, and in 1D there are no insulating boundaries so . All derivatives are computed via automatic differentiation, and the resulting loss functions are scaled to ensure that none of the equations are neglected. In particular, two forms of the continuity residual are used. The unscaled form uses the continuity equation as written:
Through the definition of and , the residuals in this form are effectively weighted by the carrier densities at each location. This means that the residuals considering the current density when that carrier is the majority receive much higher attention. To address this issue, the prefactor form divides each continuity residual by the local carrier density, for electrons and for holes (in the Slotboom formulation, by the current prefactors and ), which are proportional to and up to the bounded factors and ). The purpose of this operation is to enhance the residuals where electrons and holes are minority carriers. In the unscaled form, the residual of each continuity equation scales with the density of its own carrier, which in the minority region is smaller than in the majority region by up to , about 12 orders of magnitude in the 1D device. The minority-carrier residuals are then so tiny that they are effectively ignored by the loss, even though the minority-carrier currents determine the current through the junction. Dividing by or removes this disparity and weights all positions evenly, so that the minority-carrier regions contribute to the loss on an equal footing with the majority-carrier regions.
2.4.1 Two-stage training with the Gummel split
We consider two alternatives for training the networks. The first, which we use here for the forward-bias simulations, trains the networks with Adam in two stages. The motivation comes from the structure of the problem: the carrier densities depend exponentially on , so the continuity equations are only meaningful once the potential, and with it the depletion region and the carrier landscape, is approximately correct. In the first, joint stage (Stage 1 in Fig. 1) all three networks are trained on the total loss of Eq. (19). In this stage the Poisson residual dominates, and the training predominantly establishes the electrostatics; the continuity residual is used in whichever of its two forms is smaller at initialization (in practice the unscaled form for V), so that it does not overwhelm the Poisson term. Once the potential is close to its final shape, continuing to train all networks on the summed loss becomes inefficient: the three residuals differ by orders of magnitude, and the gradient of the total loss with respect to each network is dominated by whichever equation is currently largest.
After 10 000 epochs, training therefore switches to a Gummel split, named after the decoupled iteration of Gummel [34] that is standard in TCAD solvers, where Poisson's equation is solved for the potential with the carrier densities held fixed and each continuity equation is then solved for its carrier with the potential held fixed. In the PINN analogue
(Stage 2 in Fig. 1), each network is updated only by the gradient of its own equation and the boundary loss,
where , and are the parameters of the , electron and hole networks, with the continuity residuals now in the prefactor form, while all networks are still updated simultaneously at every step. Because each network sees only its own equation after the split, and Adam is invariant to a constant rescaling of the loss, the relative weighting of the loss terms no longer affects the updates; no loss weights need to be tuned. The split also prevents the electron and hole networks from being pulled by the Poisson residual, which they influence only through the carrier densities. We found this two-stage procedure essential: with joint training throughout, the continuity residuals stagnate, while after the split they decrease by several orders of magnitude.
2.4.2 Second-order preconditioning with SOAP
The Adam optimizer scales the update of each parameter by a running estimate of the magnitude of its own gradient. This diagonal scaling treats every weight independently, while the curvature of the PINN loss couples the weights within each layer. When the loss is a sum of terms whose gradients point in competing directions, as is the case for the Poisson and continuity residuals, a diagonal preconditioner cannot resolve the conflict, and progress on one equation comes at the expense of the others [35]. With Adam, this is the reason the training is split into two stages (Sec. 2.4.1).
Another approach to addressing the conflicting gradients in the optimizer is to account for the correlations in the parameters when updating the weights. In its most expensive form, a full second-order preconditioner could be used to rescale the gradient with the inverse square root of the full matrix of gradient correlations. In our application (as well as many others), however, this simply requires too much storage to be practical. The authors of [36] introduced Shampoo for this very reason. As a play on the preconditioner name, Shampoo works by keeping one small preconditioner for each dimension of the weight matrix. With the gradient of a weight matrix , it accumulates the two factors
whose Kronecker product approximates the full correlation matrix, and updates the weights as
Shampoo was shown to improve convergence [36], but it is also very sensitive to hyperparameters and requires more calculation. As a more well-conditioned alternative, SOAP (ShampoO with Adam in the Preconditioner's eigenbasis) [37] was proposed to account for competing gradient directions while not significantly impacting convergence.
SOAP keeps and as exponential moving averages, together with their eigenvector matrices and . The gradient is rotated into this basis, , the Adam moments are accumulated there, and the update is rotated back,
where is the learning rate and and are the bias-corrected first and second moments in the rotated basis. In this basis the curvature is close to axis-aligned, so the diagonal scaling of Adam approximates a full-matrix, Newton-like preconditioner. The bases are refreshed every 10 steps with one power iteration and a QR decomposition, and bias vectors are updated with standard Adam ( , ). Since the hidden layers are only , the additional cost of the eigendecompositions is negligible.
With SOAP, the three networks are trained jointly on the total loss for the entire training, without the Gummel split. The continuity and Poisson residuals are used in an equilibrated form, in which the sum of the terms of each residual,
(a)

(b)
(c)
(d)
Figure 2: One-dimensional pn-junction ( , ) at a forward bias of 0.8 V, solved with the normalized Slotboom variables and the two-stage training with the Gummel split (Sec. 2.4.1). (a) Band diagram with the conduction and valence band edges and the electron and hole quasi-Fermi levels, (b) electron and hole densities, (c) electric field and (d) electron, hole and total current densities. Solid lines: PINN; dashed lines: FEM. The relative errors, given in the boxes, are 0.26% for , 0.02% and 0.01% for and , 0.03% and 0.28% for the quasi-Fermi levels and 0.45% for the total current density. The steep minority-carrier boundary layers at both contacts (b) and the bend of the quasi-Fermi levels at the contacts (a) are resolved. The electric-field error (5.1%) is concentrated at the junction peak, where the smooth doping step of the PINN differs from the abrupt profile of the reference.
, is divided by the gradient-stopped sum of their magnitudes,
where denotes a stopped gradient, the mean over the collocation points and a floor. Each residual is then bounded by one in magnitude, so that the three equations enter the joint loss on an equal footing.
In our testing, we saw the best results with the split training under forward bias and with the SOAP training under reverse bias. The forward- and reverse-bias results in Sec. 3 are therefore obtained with these two procedures, respectively.
3 Results
3.1 One-dimensional pn-junction
The first test case is an abrupt silicon pn-junction of length with and the metallurgical junction at , at ( , , and , SRH lifetimes and ). In the PINN solver the abrupt doping is represented by a smooth step,
with (transition width of nm). The p-contact at is grounded and the bias is applied to the n-contact at , so that Eq. (13) gives the contact potentials and , with (0.711 V) from Eq. (14). Reference solutions were computed with both an in-house Finite Element Method (FEM) solver and Sentaurus TCAD for identical parameters with an abrupt junction. This problem is a demanding test for a PINN. Across the device the carrier densities vary by more than 12 orders of magnitude, and they do so in narrow regions: at the junction, the depletion region is a few tenths of a micrometer wide, and at the Ohmic contacts the minority densities collapse to their equilibrium values in boundary layers of a few nanometers. In addition, the doping changes sign over nm. A standard PINN such as that used in [15] and [30], with soft boundary conditions, the physical form of the residuals and a single summed loss, does not converge to the correct solution for this problem under forward bias: the loss is dominated by a few regions, and the steep gradients are either smeared or missed entirely.
We begin with the forward-bias regime, which has been the most difficult case for PINN solverse due to the extreme gradients at the boundaries. In particular, DDNet [15] was not able to solve the abrupt pn-junction under forward bias. Here, using the normalized Slotboom variables in conjunction with the two-stage training with the Gummel split (Sec. 2.4.1), the PINN converges to the correct solution: Figure 2 shows the solution at a forward bias of 0.8 V obtained with this procedure. The band diagram, the carrier densities, the electric field and the current densities all agree closely with the FEM reference. The relative errors with respect to the in-house FEM solver are 0.26% for , 0.02% and 0.01% for and , 0.03% and 0.28% for the quasi-Fermi levels, and 0.45% for the total current density. The steep boundary layers of the minority carriers at both contacts are resolved [Fig. 2(b)], as is the abrupt bend of the quasi-Fermi levels at the contacts [Fig. 2(a)]. The electric-field error (5.1%) is concentrated at the junction peak, where the smooth doping step differs from the abrupt profile of the reference; with a softer step ( ) this error grows to 18%, while the other observables are essentially unchanged.
Under reverse bias, we demonstrate results at -0.6 V in Fig. 3(a) and (b). In this regime the depletion region widens, the minority-carrier densities near the junction fall far below their equilibrium values, and about two-thirds of the current at -0.6 V is carried by thermal generation in the depletion region rather than by the diffusion of minority carriers. The solver must therefore resolve both the depletion region and the splitting of the quasi-Fermi levels across it. For these results we use the quasi-Fermi level formulation and the SOAP training method (Sec. 2.4.2), with all three networks trained jointly on the equilibrated residuals for 30 000 epochs. The relative errors with respect to FEM are 0.66% for , 2.4% for the electric field, 0.50% and 0.68% for and , 0.80% and 0.50% for the quasi-Fermi levels, and 0.73% and 0.35% for the electron and hole minority-carrier current densities, and the terminal current agrees with the FEM reference to within 0.9%.
For the I-V characteristic, the terminal current must be extracted from the solution. Where a carrier is the majority carrier, its current density is the product of a large density and a very small quasi-Fermi level gradient, so the pointwise majority current is poorly conditioned. We therefore evaluate in the quasi-neutral p-region and in the quasi-neutral n-region, where each is the minority carrier, and account for the net recombination between the two regions,
(a)

(b)
(c)
(d)
Figure 3: (a) Band diagram, with the conduction and valence band edges and the electron and hole quasi-Fermi levels, and (b) electron and hole densities of the one-dimensional pn-junction at a reverse bias of -0.6 V, solved with the quasi-Fermi level variables and the SOAP training (Sec. 2.4.2). Solid lines: PINN; dashed lines: FEM; the relative errors are given in the boxes. (c) Reverse-bias I-V characteristic between -1.0 and -0.1 V on a linear scale and (d) forward-bias I-V characteristic between 0.1 and 1.0 V on a logarithmic scale, with the same data on a linear scale in the inset; PINN terminal currents (circles) and FEM (squares and line), with the relative error of the terminal current over each curve given in the boxes. The reverse-bias currents are obtained with the SOAP training, where the runs at -0.8 to -1.0 V are initialized from the solution at the neighbouring bias, and the forward-bias currents with the two-stage training (Sec. 2.4.1). The FEM currents at -0.9 and -1.0 V are the median over the device, since the FEM solutions at these biases contain numerical current spikes.
which follows from integrating the continuity equations and holds for any doping profile. Figure 3(d) shows the resulting forward-bias I-V characteristic between 0.1 and 1.0 V. Between 0.2 and 0.8 V the terminal current agrees with the FEM reference to within 1%, over 9 orders of magnitude of current; the deviations are larger at 0.1 V (5.0%) and in high injection at 1.0 V (6.3%). The relative error over the whole forward-bias curve is 5.5%, dominated by the largest currents at 0.9 and 1.0 V. At reverse-bias [Fig. 3(c)], the terminal current agrees with the FEM reference to within 1.5% between -0.3 and -1.0 V, and to within 2.8% and 1.8% at -0.1 and -0.2 V. The relative error over the whole reverse-bias curve is 1.1%.
Being able to solve the same device under both forward and reverse bias is an important step for PINN-based device simulation. The two regimes pose very different challenges. Under forward bias, carriers are injected across the junction and the minority-carrier densities in the neutral regions rise by many orders of magnitude, while under reverse bias the carriers are swept out of an ever wider depletion region and the current is set by thermal generation rather than by injection. The character of the solution therefore changes across the bias range, and with it the balance between the
Poisson and continuity residuals in the loss. Importantly, a training procedure that converges in one regime does not necessarily converge in the other, which is why two training alternatives are used here. This strong dependence of the solution on the operating condition has been a major obstacle to applying PINNs to semiconductor devices, where the response to the applied bias is often the quantity of interest. Overcoming it opens the door to computing complete I-V characteristics with a single PINN solver, as shown below. Further, since the PINN is differentiable with respect to its inputs and parameters, it enables parametric and inverse studies across operating conditions, such as extracting device parameters from measured characteristics or designing doping profiles for a target response in both forward and reverse bias.
3.2 Two-dimensional pn-junction
Having demonstrated the accuracy of the PINN solver in the 1D case, we here extend the methodology to 2D device geometries. This is an important step since in realistic semiconductor devices the contacts often occupy only part of the surface, the junction has corners, and the current spreads laterally through the substrate. Therefore, a practical device solver must be able to handle multidimensional and complex geometries with mixed Ohmic and insulating boundaries. The mesh-free nature of PINNs makes this extension conceptually direct, since the networks simply take an additional input coordinate and the same losses are evaluated at collocation points distributed in the 2D plane.
The 2D silicon device considered here is a p-type substrate ( ) with an embedded n-type region ( ) of at the top surface, (Fig. 4). The Anode covers on the p-type surface and the cathode on the n-type surface and all other boundaries are insulating. Current therefore does not flow along a single axis. Under an applied bias it leaves the anode, crosses the substrate and enters the n-region through its bottom and side walls. The doping is a smooth version of the abrupt profile, , with and . The reference solutions were computed using an in-house FEM solver and compared with Sentaurus TCAD.
Compared with the 1D case, the 2D problem introduces mixed boundary conditions. The Debye length is 13 nm in a 10 m domain, the built-in potential is 32 , and the depletion region is a thin shell of 0.1 m around the n-region, with field crowding at its two corners. The contact conditions are imposed with the distance-function construction of Sec. 2.3.1 and the Neumann conditions as additional penalty terms. At equilibrium the quasi-Fermi level variables are used, since the normalized Slotboom variables are undefined at . For this problem, we leverage the extensive FEM resources for mesh generation to choose our collocation points [38]. By carefully selecting points in this way, the PINN solver is able to converge faster and satisfy sharp features in the domain.
Figure 4 compares the PINN solution at equilibrium with the FEM reference. The potential and both carrier densities are reproduced across the device, including the depletion shell around the n-region and its corners, with relative errors of 3.9% for , 2.6% for and 1.9% for , and quasi-Fermi levels that are flat to within V, as required at equilibrium. The remaining error is concentrated at the right edge of the n-region near the surface ( , ), where the PINN places the junction slightly off; elsewhere the absolute error is negligible. The exact imposition of the contact conditions proved decisive: with the same networks and soft contact losses, the error in was 18–41%, because the initial potential is far from the contact values and the carrier densities start out at throughout the device, where the continuity equations are trivially satisfied.
These results demonstrate that our new training method can be naturally extended to higher dimensional problems, a variety of length scales, and more complex device geometries. The demonstrated ability to accurately model 2D geometries is a stepping stone towards applying the PINN methodology towards the complex heterostructures that currently utilized in the semiconductor industry.

FEM: (V)
FEM:
FEM:
x (μm)
x (μm)
x (μm)
Figure 4: Two-dimensional pn-junction at equilibrium: a p-type substrate ( ) with an embedded n-type region ( , dashed outline) at the top surface, contacted by the Anode ( ) and the Cathode ( ) with all other boundaries insulating. The PINN uses the quasi-Fermi level variables, the distance-function construction for the Ohmic contacts (Sec. 2.3.1), the Neumann conditions as penalty terms, and collocation points taken from the FEM mesh. Columns: electrostatic potential (left), (center) and (right); rows: PINN (top) and FEM reference (bottom), on a common color scale per column. The relative errors, given in the boxes, are 3.9% for , 2.6% for and 1.9% for ; the depletion shell around the n-region and its corners are reproduced, and the remaining error is concentrated at the right edge of the n-region near the surface.
3.3 Inverse problems
In many situations a designer may be interested in finding a doping profile that gives a desired electric field or electrostatic potential that is chosen purely based on design requirements. With current FEM methods, however, this can be a very time consuming and error-prone task. PINN, on the other hand, excels at solving inverse problems such as this one. Within the PINN framework, the unknown doping profile is simply added as an extra network output and a loss term is added on the given data to guide the optimization towards retrieving the correct doping profile, i.e., the one that minimizes, in a suitable norm, the error of the surrogate solution with respect to the training dataset. For the sake of demonstration, in what follows we consider two inverse problems for the 1D junction case: recovering the doping profile from the electric field , and from the electrostatic potential , each given under forward biased conditions.
In the introduced inverse problems, the doping profile is no longer a prescribed input but an additional output of the PINN. A fourth network (3 hidden layers of 32 tanh units, linear output) represents the doping , which replaces the prescribed profile in the Poisson residual. Since the Ohmic boundary conditions depend on the doping at the contacts, they are written in terms of this output.
This calculation reduces to Eq. (13) for the true doping. The hard boundary construction of Sec. 2.3.1 uses these learned contact values, so that no information about the true doping enters the model. The data enter through an additional loss term, evaluated at points uniformly spaced in and interpolated from the FEM reference. For electric-field data and for potential data, respectively,
(31) where and is the measured field in normalized units. The normalization by the mean square of the field, or by the variance of the potential, makes the data term of order one for either data type. The total loss of Eq. (19) then becomes , with a data weight .
The continuity residuals are used in the prefactor form, and the Poisson residual is pointwise equilibrated, i.e. divided by the gradient-stopped sum of the magnitudes of its terms, so that it does not reward an underestimated doping. Both inverse problems are solved with the normalized Slotboom variables and, importantly, outside of equilibrium: the data are taken under forward bias, at 0.5 V for the electric field and at 0.4 V for the potential. Training under bias is considerably harder than at equilibrium, since the doping must then be recovered together with the injected carrier densities and the current through the device, which couples the data, Poisson and continuity terms through the unknown doping.
Figure 5 shows the recovered doping profiles, together with the training data from which they are obtained. With Adam, the relative error of the doping is 5.4% from the electric field at 0.5 V and 9.6% from the potential at 0.4 V. Both reconstructions are further improved by refining the training. For the electric-field data, the networks are polished with L-BFGS [39] on the same loss, with the loss weights held fixed, until convergence (about 13 500 iterations), which reduces the error to 3.9%. For the potential data, the networks are trained with SOAP (Sec. 2.4.2) and then for a further 60 000 epochs at a lower learning rate ( to ), which reduces the error to 8.0%. From the electric field, the PINN recovers flat plateaus at cm to within 0.4% and a sharp step at the junction [Fig. 5(a)]. From the potential, the remaining error comes mostly from an offset of the plateaus of about 4% [Fig. 5(b)]. In both cases the position of the junction is recovered to within 0.4 nm.
4 Conclusions
In this work we introduced a novel and powerful PINN architecture that accurately solves the drift-diffusion equations in the context of both forward and inverse problems. This is a problem that has been notoriously difficult to tackle using traditional neural networks, as it involves an abrupt pn-junction under both forward and reverse bias, with carrier densities spanning more than 12 orders of magnitude and boundary layers only a few nanometer-thick at the contacts. Our results demonstrate that the main obstacle is not the expressivity of the neural networks but the conditioning of the optimization. The carrier densities and current prefactors depend exponentially on the potential, so residuals written in their physical form weight different regions of the device by many orders of magnitude, and the total loss of the coupled equations is dominated by whichever equation is currently largest. Exactly imposed Ohmic contacts, normalized residuals, and a training procedure that resolves the competition between the equations, either by decoupling them through a Gummel split or by preconditioning the joint optimization with SOAP, remove most of this disparity. Using small networks of only 5 000 parameters each, our developed PINN the solver is capable of reproducing the FEM reference results with excellent accuracy, i.e., sub-percent errors in the potential, the carrier densities and the terminal current at both 0.8 V and -0.6 V, and follows the I-V characteristic over 9 orders of magnitude in forward bias and from -0.1 to -1.0 V in reverse bias, in under 20 minutes of training on a single GPU.
The developed PINN framework was also extended to include 2D junction geometries with mixed contact and insulating boundaries. Finally, we demonstrated the solution of inverse problems for retrieving the doping profiles based on desired field distributions at the junctions. Since the unknowns of the problem enter only through the PDE and boundary residuals, the doping profiles can be recovered efficiently from the electric field or the electrostatic potential simply by making it a trainable function at the network output. Following this established procedure [15], we were able to achieve errors of 3.9% and 8.0% under non-equilibrium bias conditions, a task for which conventional PINNs and TCAD solvers are not designed.
This work establishes PINN as a powerful simulation tool in the field of semiconductor modeling and inverse design. Our advanced architecture and collocation strategy address several of the limitations of previous attempts and pave the way to numerous applications of PINNs for the solution of forward and inverse simulations in heterostructure devices.
(a)

(b)
(c)

(d)

Figure 5: Doping profiles recovered by the inverse PINN (solid) compared with the true abrupt profile used in the FEM reference (dashed), (a) The electric field training data at a bias voltage of 0.5 V. (b) The electrostatic potential training data at a bias voltage of 0.4 V. (c) doping profile inversely retrieved from the electric field at 0.5 V and (d) doping profile inversely retrieved from the electrostatic potential at 0.4 V. The doping profiles have a relative errors of 3.89% and 8.02% for the electric field and electrostatic potential training respectively. For training on the electric field, Adam training refined with L-BFGS was used. Both plateaus are recovered to within 0.4% and the junction to within 0.2 nm. With the electrostatic potential, SOAP training followed by a continuation at a lower learning rate was used, and the junction was recovered to within 0.4 nm, and the remaining error comes from an offset of the plateaus of about 4%.
under realistic operation conditions far from equilibrium, which are essential to next generation microelectronics research and automated discovery.
5 Acknowledgments
L. D. N. acknowledges the support from the U.S. Army Research Office, RF-Center managed by Dr. T. Oder (Grant #W911NF-22-2-0158). The authors thank Anusha Krishnan and Roberto Riganti for insightful discussions. Numerical simulations were performed on the Shared Computing Cluster (SCC) at Boston University.
References
[1] S. M. Sze, Kwok Kwok Ng, and Yiming Li. Physics of semiconductor devices. Wiley, Hoboken, NJ, USA, fourth edition edition, 2021.
[2] David K. Ferry. Semiconductor Transport. CRC Press, Boca Raton, FL, USA, 2016.
[3] Jiahao Xie, Yansong Zhou, Muhammad Faizan, Zewei Li, Tianshu Li, Yuhao Fu, Xinjiang Wang, and Lijun Zhang. Designing semiconductor materials and devices in the post-Moore era by tackling computational challenges with data-driven strategies. Nature Computational Science, 4(5):322–333, May 2024. Publisher: Nature Publishing Group.
[4] Feiyang Zhao, Yongjie He, Bin Huang, Tianyi Zhang, and Hao Zhu. A Review of Diamond Materials and Applications in Power Semiconductor Devices. Materials, 17(14):3437, July 2024.
[5] G. Thennarasu, Swethashree Rajendran, Ashmitha Kalairaj, Hanumanth Singh Rathore, Rames C. Panda, and T. Senthilvelan. A comprehensive review on the application of semiconductor nanometal oxides photocatalyst for the treatment of wastewater. Clean Technologies and Environmental Policy, 27(2):495–516, February 2025.
[6] Jiachang Zhuang, Minmin Zhu, Haizhong Zhang, Weipeng Wang, and Xiaoqiang Lu. Gallium-based semiconductor integrated circuits: Past, present, and future for emerging optoelectronic devices. Advanced Functional Materials, 36(32):e27869, 2026.
[7] Peter A Markowich. The stationary semiconductor device equations. Springer Science & Business Media, New York City, USA, 1985.
[8] Peter A Markowich, Christian A Ringhofer, and Christian Schmeiser. Semiconductor equations. Springer Science & Business Media, New York City, USA, 2012.
[9] Randolph E Bank, Donald J Rose, and Wolfgang Fichtner. Numerical methods for semiconductor device simulation. SIAM Journal on Scientific and Statistical Computing, 4(3):416–435, 1983.
[10] Synopsys, Inc., Mountain View, CA. Sentaurus Device User Guide. Version W-2024.09-SP1, September 2024.
[11] SILVACO. SILVACO TCAD®, 2025.
[12] COMSOL AB. COMSOL Multiphysics® v. 6.0, Stockholm, Sweden, 2024.
[13] Da-Wei Wang, Qing Zhang, Hang Wan, and Wen-Sheng Zhao. Finite element approach based numerical framework for device simulator. IEEE Transactions on Computer-Aided Design of Integrated Circuits and Systems, 44(8):3197–3207, 2025.
[14] M. Raissi, P. Perdikaris, and G. E. Karniadakis. Physics-informed neural networks: A deep learning framework for solving forward and inverse problems involving nonlinear partial differential equations. Journal of Computational Physics, 378:686–707, February 2019.
[15] Roberto Riganti, Matteo G. C. Alasio, Enrico Bellotti, and Luca Dal Negro. DDNet: A Unified Physics-Informed Deep Learning Framework for Semiconductor Device Modeling, January 2026. arXiv:2509.08073 [physics].
[16] Maziar Raissi, Alireza Yazdani, and George Em Karniadakis. Hidden fluid mechanics: Learning velocity and pressure fields from flow visualizations. Science, 367(6481):1026–1030, February 2020. Publisher: American Association for the Advancement of Science.
[17] Yuyao Chen, Lu Lu, George Em Karniadakis, and Luca Dal Negro. Physics-informed neural networks for inverse problems in nano-optics and metamaterials. Optics Express, 28(8):11618–11633, April 2020.
[18] Zhao Chen, Yang Liu, and Hao Sun. Physics-informed learning of governing equations from scarce data. Nature Communications, 12(1):6136, October 2021.
[19] Yuyao Chen and Luca Dal Negro. Physics-informed neural networks for imaging and parameter retrieval of photonic nanostructures from near-field data. APL Photonics, 7(1):010802, January 2022.
[20] R. Riganti and L. Dal Negro. Auxiliary physics-informed neural networks for forward, inverse, and coupled radiative transfer problems. Applied Physics Letters, 123(17):171104, October 2023.
[21] Roberto Riganti, Yilin Zhu, Wei Cai, Salvatore Torquato, and Luca Dal Negro. Multiscale Physics-Informed Neural Networks for the Inverse Design of Hyperuniform Optical Materials. Advanced Optical Materials, 13(16):2403304, 2025. _eprint: https://advanced.onlinelibrary.wiley.com/doi/pdf/10.1002/adom.202403304.
[22] Roberto Riganti, Luke Ragan, and Luca Dal Negro. A multiscale auxiliary pinn framework for generalized phonon transport. Materials Today Physics, page 102159, 2026.
[23] Shengze Cai, Zhiping Mao, Zhicheng Wang, Minglang Yin, and George Em Karniadakis. Physics-informed neural networks (PINNs) for fluid mechanics: a review. Acta Mechanica Sinica, 37(12):1727–1738, 2021.
[24] Kangkang Chen, Xingjian Dong, Penglin Gao, Qian Chen, Zhike Peng, and Guang Meng. Physics-informed neural networks for topological metamaterial design and mechanical applications. International Journal of Mechanical Sciences, 301:110489, 2025.
[25] Chenxi Wu, Min Zhu, Qinyang Tan, Yadhu Kartha, and Lu Lu. A comprehensive study of non-adaptive and residual-based adaptive sampling for physics-informed neural networks. Computer Methods in Applied Mechanics and Engineering, 403:115671, January 2023.
[26] George Em Karniadakis, Ioannis G. Kevrekidis, Lu Lu, Paris Perdikaris, Sifan Wang, and Liu Yang. Physics-informed machine learning. Nature Reviews Physics, 3(6):422–440, June 2021.
[27] Khemraj Shukla, Patricio Clark Di Leoni, James Blackshire, Daniel Sparkman, and George Em Karniadakis. Physics-informed neural network for ultrasound nondestructive quantification of surface breaking cracks. Journal of Nondestructive Evaluation, 39(3):61, 2020.
[28] Alfred V. Petrosyan and Armen S. Yepiskoposyan. Hybrid PINN-TCAD framework for sub-percent p–n junction simulation with spillover error quantification. Journal of Computational Electronics, 25(1):12, 2026.
[29] Manopat Chankla, Bang-Ren Chen, Shivendra Kumar Singh, Yogesh Singh Chauhan, Wen-Jay Lee, Nan-Yow Chen, Songphol Kanjanachuchai, and Tian-Li Wu. Demonstration of accurate ID-VG characteristics modeling in SiC MOSFETs using separated artificial neural networks with small training dataset. Scientific Reports, 15(1):18941, May 2025.
[30] Zifei Cai, Anaoxue Huang, Yifeng Xiong, Dejiang Mu, Xiangshui Miao, and Xingsheng Wang. Multi-order Differential Neural Network for TCAD Simulation of the Semiconductor Devices. In Proceedings of the 61st ACM/IEEE Design Automation Conference, DAC '24, pages 1–6, New York, NY, USA, November 2024. Association for Computing Machinery.
[31] Jan W Slotboom. Computer-aided two-dimensional analysis of bipolar transistors. IEEE Transactions on Electron Devices, 20(8):669–679, 1973.
[32] Diederik P. Kingma and Jimmy Ba. Adam: A Method for Stochastic Optimization, January 2017. arXiv:1412.6980 [cs].
[33] Vadim Shapiro. Semi-analytic geometry with r-functions. ACTA numerica, 16:239–303, 2007.
[34] Hermann K Gummel. A self-consistent iterative scheme for one-dimensional steady state transistor calculations. IEEE Transactions on electron devices, 11(10):455–465, 1964.
[35] Sifan Wang, Ananyae Kumar Bhartari, Bowen Li, and Paris Perdikaris. Gradient alignment in physics-informed neural networks: A second-order optimization perspective. In Advances in Neural Information Processing Systems, 2025. arXiv:2502.00604.
[36] Vineet Gupta, Tomer Koren, and Yoram Singer. Shampoo: Preconditioned stochastic tensor optimization, February 2018. arXiv:1802.09568.
[37] Nikhil Vyas, Depen Morwani, Rosie Zhao, Mujin Kwun, Itai Shapira, David Brandfonbrener, Lucas Janson, and Sham Kakade. SOAP: Improving and stabilizing Shampoo using Adam, September 2024. arXiv:2409.11321.
[38] Ning Liu and Wenbin Yu. Gmsh. Technical report, Purdue University, 2014.
[39] Dong C. Liu and Jorge Nocedal. On the limited memory BFGS method for large scale optimization. Mathematical Programming, 45(1):503–528, 1989.