1 Introduction

The stochastic drift–diffusion–Poisson system makes it possible to model charge transport in random environments. Thus, it goes beyond the deterministic description provided by the well-known drift–diffusion–Poisson system that has been used to simulate charge transport through semiconductor devices, ion channels, and nanopores. In this work, the stochastic drift–diffusion–Poisson system models a nanowire field-effect biosensor. This concrete model system serves two purposes. First, it is a much more complex model system than a semiconductor transistor and highlights the challenges of developing comprehensive models and efficient numerical methods. It includes many other applications as special cases, in particular nanoscale transistors such as FinFETs. Second, it is a useful device with important applications whose fabrication has been demonstrated [1, 2].

The model for field-effect sensors includes an association–dissociation process between target and receptor molecules at the surface of the device [3, 4]. The partial charges of the target molecules modulate the charge transport in the semiconductor [5,6,7,8] (see schematic diagram in Fig. 1).

In field-effect transistors (FET), the statistical variability associated with discrete random dopants, which dominates contemporary multi-gate metal-oxide semiconductor field-effect transistors (MOSFET), has become a major threat to scaling and integration [9, 10]. In fact, the fluctuation due to random discrete atoms in the source and drain regions has been a challenging problem. In this work, three-dimensional simulations are used to simulate the effects of random dopant fluctuations on the device performance.

Fig. 1
figure 1

A cross section of a (nanoscale) field-effect sensor indicating the different materials and boundary conditions. The charged target molecules bind to receptors on the surface in an association–dissociation process. The random dopants (red) are located in the semiconducting transducer. Semiconductor devices such as FinFETs are a simpler special case, where the upper boundary is located right at the top oxide layer (Color figure online)

There are various sources of randomness. The distribution of the receptor molecules at the surface is random and determined at fabrication time. Diffusion in the liquid and association and dissociation at the surface receptors are stochastic processes and occur at the time of usage. The random distribution of the dopant atoms in the semiconductor is again determined at fabrication time and leads to important device variation, while charge transport obviously occurs at the time of usage.

The simulation capability developed here is general enough to include many situations where charge transport occurs in a random environment. These effects due to the random location of dopants are of increasing importance, as the devices have been shrunk into the nanometer scale and billions of them are required to work together despite the unavoidable process variations. In the case of field-effect sensors, understanding noise and fluctuations is essential to calculate detection limits and signal-to-noise ratios.

In this work, the simulation results are based on a system of stochastic PDE. An important feature of the model used here is that the random coefficients in the stochastic equations are computed from additional physical models, so that there are essentially no free parameters or coefficient functions whose values are unknown or have to be estimated. The system of stochastic PDEs representing a full transport model and the additional models for the random coefficients together constitute the most comprehensive model for this general type of devices developed and implemented so far.

The main numerical challenge is a large number of stochastic dimensions. Each dopant and each receptor for target molecules result in some stochastic dimensions. Therefore, the number of stochastic dimensions is at least in the dozens but can be in the hundreds or thousands for larger devices. We address the numerical challenge by using a state-of-the-art method, namely a multi-level Monte–Carlo method (MLMC), and improve on it by determining the discretization parameters in the numerical approach such that the computational work is minimized for a prescribed total error. In this way, the various sources of error are balanced optimally. In [11], these ideas were implemented only for a simpler and two-dimensional model.

In [12], we have developed an optimal multi-level randomized quasi-Monte–Carlo method to solve the stochastic system of equations. The main idea in [12] is to replace the random points by quasi-random sequences, which have better uniformity, in the multi-level setting; in fact, using rank-1 lattice rules [13] leads to more efficient computations. In [12], a FinFET is considered as the numerical example, while a biosensor that poses additional complications is simulated in three-dimensional space in the present work. In the biosensor, both the random binding of target molecules to the receptors and the random distribution of dopants in the semiconductor are modeled.

The rest of this paper is organized as follows. In Sect. 2, the model equations are presented. The numerical method is discussed in detail Sect. 3, and the optimal method is developed in Sect. 4. Numerical results are shown in Sect. 5. Finally, conclusions are drawn in Sect. 6.

2 The model equations

2.1 The stochastic drift–diffusion–Poisson system

The bounded, convex, and three-dimensional domain \(D \subset \mathbb {R}^3\) is divided into four subdomains \(D_\mathrm {Si}\), \(D_\mathrm {ox}\), \(D_\mathrm {liq}\), and \(D_\mathrm {mol}\) named after their materials (silicon, silicon oxide, liquid, and molecule). A cross section of the domain is shown in Fig. 1 along with the subdomains. Because of the different material properties, different equations hold in the various subdomains.

The basic equation for the electrostatic potential is the Poisson equation

$$\begin{aligned} -\nabla \cdot (A(x)\nabla V(x,\omega ))=\rho (x,\omega ) \quad \forall x\in D \quad \forall \omega \in \varOmega \end{aligned}$$
(1)

solved on the whole domain D, where \(x \in D\), \(\omega \in \varOmega \), \(( \varOmega , \mathbb {A}, \mathbb {P})\) is a probability space, \(\varOmega \) the sample space, \(\mathbb {A}\) the \(\sigma \)-algebra of all possible events, and \(\mathbb {P}\) the probability measure. Furthermore, V is the electrostatic potential, A is the permittivity, and \(\rho \) is the charge density. The charge density \(\rho \) is split into \(\rho = \rho _\mathrm{i}+\rho _\mathrm{f}\), where \(\rho _i\) is the concentration of immobile (fixed) charges. \(\rho _\mathrm{f}\) denotes free or mobile charges according to a Boltzmann distribution, leading to the Poisson–Boltzmann equation in the liquid.

For every \(\omega \in \varOmega \), solving a homogenization problem at the interface \(\Gamma \) between \(D_\mathrm {ox}\) and \(D_\mathrm {liq}\) [5] leads to the two interface conditions

$$\begin{aligned} V (0+,y,\omega )-V (0-,y,\omega )&= \alpha (y,\omega )&\quad \text {on}\,\, \Gamma , \end{aligned}$$
(2a)
$$\begin{aligned} A(0+)\partial _x V (0+,y,\omega )-A(0-)\partial _x V (0-,y,\omega )&= \gamma (y,\omega )&\quad \text {on}\,\, \Gamma . \end{aligned}$$
(2b)

In \(D_\mathrm {Si}\), the charge concentration is

$$\begin{aligned} \rho (x,\omega )=q(p(x,\omega )-n(x,\omega )+C_\mathrm {dop}(x,\omega )), \end{aligned}$$

where \(C_\mathrm {dop}\) is the doping concentration and n and p are the concentrations of electrons and holes. In \(D_\mathrm {Si}\), the drift–diffusion–Poisson system

$$\begin{aligned} -\nabla \cdot (A\nabla V)&= q(p(x,\omega )-n(x,\omega )+C_\mathrm {dop}(x,\omega )), \end{aligned}$$
(3a)
$$\begin{aligned} \nabla \cdot J_\mathrm{n}&=qR(n,p), \end{aligned}$$
(3b)
$$\begin{aligned} \nabla \cdot J_\mathrm{p}&=-qR(n,p), \end{aligned}$$
(3c)
$$\begin{aligned} J_\mathrm{n}&=q(D_\mathrm{n}\nabla n-\mu _\mathrm{n}n\nabla V), \end{aligned}$$
(3d)
$$\begin{aligned} J_\mathrm{p}&=q(-D_\mathrm{p}\nabla \mathrm{p}-\mu _\mathrm{p}p\nabla V) \end{aligned}$$
(3e)

models charge transport for every \(x\in D\) and \(\omega \in \varOmega \). \(J_\mathrm{n}\) and \(J_\mathrm{p}\) are current densities, \(\mu _\mathrm{n}\) and \(\mu _\mathrm{p}\) are electron and hole mobilities, and \(D_\mathrm{n}\) and \(D_\mathrm{p}\) are the diffusion coefficients, for which the Einstein relations \(D_\mathrm{p} = U_\mathrm{T} \mu _\mathrm{p}\) and \(D_\mathrm{n} = U_\mathrm{T} \mu _\mathrm{n}\) hold, where \(U_\mathrm{T}:= K_BT/q\) is the thermal voltage. Furthermore, R is the generation-recombination rate, whose precise form is not important in the following; the popular Shockley–Read–Hall recombination rate, given by

$$\begin{aligned} R(n,p) := \frac{n p-n_i^2}{\tau _\mathrm{n}(p+n_i)+\tau _\mathrm{p}(n+n_i)}, \end{aligned}$$

is used in the following, where \(\tau _\mathrm{n}\) and \(\tau _\mathrm{p}\) are the lifetimes of the free carriers.

Moreover, we change the concentrations n and p to Slotboom variables u and v, which are defined by the equations

$$\begin{aligned} p:=n_\mathrm{i}\exp {\left( -\frac{qV}{K_\mathrm{B}T}\right) }v \quad \text {and} \quad n=:n_\mathrm{i}\exp {\left( \frac{qV}{K_\mathrm{B}T}\right) }u \end{aligned}$$
(4)

and where \(n_{\mathrm{i}}\) is the intrinsic carrier density of the semiconductor, \(K_\mathrm{B}\) is the Boltzmann constant, and T is the temperature.

Using Slotboom variables, the drift–diffusion equations (3) take the form

$$\begin{aligned} U_\mathrm{T}\nabla \cdot (\mu _\mathrm{p} e^{-V/U_\mathrm{T}}\nabla u)&=\frac{uv-1}{\tau _\mathrm{p}(e^{V/U_\mathrm{T}}u+1)+\tau _\mathrm{n}(e^{-V/U_\mathrm{T}}v+1)}, \end{aligned}$$
(5a)
$$\begin{aligned} U_\mathrm{T}\nabla \cdot (\mu _\mathrm{n} e^{V/U_\mathrm{T}}\nabla v)&=\frac{uv-1}{\tau _\mathrm{p}(e^{V/U_\mathrm{T}}u+1)+\tau _\mathrm{n}(e^{-V/U_\mathrm{T}}v+1)}. \end{aligned}$$
(5b)

The boundary \(\partial D\) is partitioned into Dirichlet and Neumann boundaries. For the Dirichlet part, the boundary conditions are

$$\begin{aligned}&V(x,\omega )|_{\partial D_\mathrm{D}}=V_\mathrm{D}(x), \quad u(x,\omega )|_{\partial D_{\mathrm {Si}, \mathrm{D}}}=u_\mathrm{D}(x),\quad \text {and} \nonumber \\&v(x,\omega )|_{\partial D_{\mathrm {Si}, \mathrm{D}}}=v_D(x). \end{aligned}$$
(6)

At the source, drain, and back-gate contacts, the Dirichlet boundary conditions are the source voltage \(V_\mathrm{S}\), the drain voltage \(V_\mathrm{D}\), and gate voltage \(V_\mathrm{G}\), respectively. The Ohmic contacts are charge neutral, and hence the electrostatic potential and the charge-carrier concentrations on the boundary \(\partial D_{\mathrm {Si},\mathrm{D}}\) can be determined as follows. We define

$$\begin{aligned} V_1:=U+V_{\mathrm {bi}}, \end{aligned}$$
(7)

where \(V_\mathrm {bi}:=U_\mathrm{T}\ln \left( n_\mathrm{D}/n_\mathrm{i} \right) \) is the built-in potential and U denotes the applied potential. Due to charge neutrality, the values \(u_\mathrm{D}\) and \(v_\mathrm{D}\) on the boundary are then given by

$$\begin{aligned} u_\mathrm{D}&:=n_\mathrm{i}^{-1}e^{-V_1/U_\mathrm{T}}n_\mathrm{D},\\ v_\mathrm{D}&:=n_\mathrm{i}^{-1}e^{V_1/U_\mathrm{T}}p_\mathrm{D}, \end{aligned}$$

and

$$\begin{aligned} n_\mathrm{D}&:=\frac{1}{2} \left( C_{\text {dop}}+\sqrt{C_{\text {dop}}^2+4n_\mathrm{i}^2}\right) ,\\ p_\mathrm{D}&:=\frac{1}{2} \left( - C_{\text {dop}}+\sqrt{C_{\text {dop}}^2+4n_\mathrm{i}^2}\right) . \end{aligned}$$

Zero Neumann conditions are used on the Neumann part of the boundary. The boundary conditions for the different parts of the sensor are depicted in Fig. 1.

In the subdomain \(D_\mathrm {ox}\), the Poisson equation with a zero right-hand side is used since there are no charge carriers, and in the subdomain \(D_\mathrm {liq}\), the nonlinear Poisson–Boltzmann equation is used to include screening.

In summary, \(\forall \omega \in \varOmega \), the model equations are the stochastic boundary-value problem

$$\begin{aligned}&-\nabla \cdot (A(x)\nabla V(x,\omega ))\nonumber \\&\quad = q C_{\text {dop}}(x,\omega ) \nonumber \\&\qquad -\, q n_\mathrm{i}(\mathrm {e}^{-(\Phi _2-V(x,\omega ))/U_\mathrm{T}}u(x,\omega ) \nonumber \\&\qquad - \mathrm {e}^{(\Phi _1-V(x,\omega ))/U_\mathrm{T}}v(x,\omega )) \quad \text {in }\;D_\mathrm {Si}, \end{aligned}$$
(8a)
$$\begin{aligned}&\qquad -\,\nabla \cdot (A(x)\nabla V(x,\omega )) = 0 \quad \text {in }\;D_\mathrm {ox}, \end{aligned}$$
(8b)
$$\begin{aligned}&\qquad -\,\nabla \cdot (A(x)\nabla V(x,\omega )) = \rho _\mathrm {mol}(x,\omega ) \quad \text {in }\;D_\mathrm {mol},\end{aligned}$$
(8c)
$$\begin{aligned}&\qquad -\,\nabla \cdot (A(x)\nabla V(x,\omega )) = -2\eta \sinh (\beta (V(x,\omega )\nonumber \\&\qquad -\Phi (x,\omega ))) \quad \text {in }\;D_\mathrm {liq},\end{aligned}$$
(8d)
$$\begin{aligned}&V(0+,y,\omega ) - V(0-,y,\omega ) = \alpha (y,\omega ) \quad \text {on }\;\Gamma ,\end{aligned}$$
(8e)
$$\begin{aligned}&A(0+)\partial _x V(0+,y,\omega )-A(0-)\partial _x V(0-,y,\omega ) \nonumber \\&\qquad = \gamma (y,\omega )\quad \text {on }\;\Gamma , \end{aligned}$$
(8f)
$$\begin{aligned}&U_\mathrm{T}\nabla \cdot (\mu _\mathrm{n} e^{-(\Phi _2(x,\omega )-V(x,\omega ))/U_\mathrm{T}}\nabla v(x,\omega ))\nonumber \\&\quad =\frac{u(x,\omega )v(x,\omega )-1}{\tau _\mathrm{n}(e^{(\Phi _1(x,\omega )-V(x,\omega ))/U_\mathrm{T}}u(x,\omega )+1)+\tau _\mathrm{p}(e^{-(\Phi _2(x,\omega )-V(x,\omega ))/U_\mathrm{T}}v(x,\omega )+1)}\quad \text {in }\;D_\mathrm {Si}, \end{aligned}$$
(8g)
$$\begin{aligned}&U_\mathrm{T}\nabla \cdot (\mu _\mathrm{p} e^{(\Phi _1(x,\omega )-V(x,\omega ))/U_\mathrm{T}}\nabla u(x,\omega ))\nonumber \\&\quad =\frac{u(x,\omega )v(x,\omega )-1}{\tau _\mathrm{n}(e^{(\Phi _1(x,\omega )-V(x,\omega ))/U_\mathrm{T}}u(x,\omega )+1)+\tau _\mathrm{p}(e^{-(\Phi _2(x,\omega )-V(x,\omega ))/U_\mathrm{T}}v(x,\omega )+1)} \quad \text {in }\;D_\mathrm {Si}, \end{aligned}$$
(8h)
$$\begin{aligned}&\alpha (y,\omega ) = M_{\alpha }(V(y,\omega )) \quad \text {in}\; \Gamma , \end{aligned}$$
(8i)
$$\begin{aligned}&\gamma (y,\omega ) =M_{\gamma }(V(y,\omega )) \quad \text {in }\;\Gamma , \end{aligned}$$
(8j)
$$\begin{aligned}&V(x,\omega ) = V_\mathrm{D}(x) \quad \text {on }\;\partial D_\mathrm{D}, \end{aligned}$$
(8k)
$$\begin{aligned}&\mathbf {n} \cdot \nabla V(x,\omega ) =0 \quad \text {on}\; \partial D_\mathrm{N}, \end{aligned}$$
(8l)
$$\begin{aligned}&u(x,\omega ) = u_D(x),\quad v(x,\omega ) = v_D(x) \quad \text {on }\;\partial D_{\mathrm{D},\mathrm {Si}}, \end{aligned}$$
(8m)
$$\begin{aligned}&\mathbf {n} \cdot \nabla u(x,\omega )=0,\quad \mathbf {n} \cdot \nabla v(x,\omega )=0 \quad \text {on }\;\partial D_{\mathrm{N},\mathrm {Si}}, \end{aligned}$$
(8n)

where \(\eta \) is the ionic concentration and \(\beta :=1/U_\mathrm{T}\). Under certain assumptions, there exists a unique weak solution to the model constructed in Sect. 2. For the definition of the weak solution as well as for existence and uniqueness theorems, the reader is referred to [11, 14].

In real-world applications, all the coefficients in the model equations (8) are indeed stochastic. In the following, the models for the stochastic coefficients are discussed.

2.2 Random dopants

To complete the description of the model equations, we describe here how the dopants are distributed in space. The source of randomness inside the transducer is the random motion of dopant atoms through the semiconductor during the fabrication steps of implantation and annealing, resulting in their random locations.

Various models such as nearest-grid-point (NGP), cloud-in-cell (CIC) [15], and the Sano method [16] may be used to describe randomly placed dopants in semiconducting devices. In the simplest model, the charge concentration due to N ionized atoms is given by

$$\begin{aligned} \xi _1(x):=C_{ j}\sum _{j=1}^{N}\delta (x-x_j), \end{aligned}$$
(9)

where \(C_j\) is the charge of the jth dopant atom, N is the number of dopant atoms, \(x_j\) is the position of jth dopant, and \(\delta \) is the Dirac delta distribution.

In [17], Gaussian distributions for the individual dopant atoms were placed at random positions. In [18], the standard deviation \(\sigma \) of the Gaussian or normal distributions was used to adjust the size of the dopant atoms yielding the charge concentration

$$\begin{aligned} \xi _2(x) := \sum _j \frac{C_j}{\left( 2\pi \sigma ^2\right) ^{3/2}} \exp \left( - \frac{(x-x_j)^2}{2\sigma ^2} \right) . \end{aligned}$$
(10)

Here, \(\sigma :=0.25\,\mathrm {nm}\) is used to represent a dopant; the results are not very sensitive to the value of \(\sigma \).

To make the results comparable between continuous and discrete doping models, the total doping must match. In other words, the integrals over a continuous doping concentration \(C_\mathrm {dop}\) and over a discrete doping concentration must agree, i.e.,

$$\begin{aligned} \int _{D_\mathrm {Si}} C_\mathrm {dop}(x) \mathrm {d} x = \int _{D_\mathrm {Si}} \xi _1(x) \mathrm {d} x = \int _{D_\mathrm {Si}} \xi _2(x) \mathrm {d} x. \end{aligned}$$

2.3 Association and dissociation processes of biomolecules

In field-effect sensors, the charge concentration in the boundary layer is changed as target molecules bind to receptor molecules, and therefore the current through the semiconducting transducer is modulated. The binding of target molecules to the probe molecules is indicated in Fig. 1. In DNA sensors, the binding and unbinding events are the hybridization and dehybridization of single-stranded DNA oligomers to be detected with immobilized single-stranded DNA oligomers of known sequence. The electrical current through the nanowire is measured and provides quantitative information, while the sensor is selective due to the specific binding to the receptor molecules. In the simulations, chemical equilibrium as a balance between association and dissociation is assumed.

The association and dissociation processes of target molecules at the surface can be described by the reaction equations

$$\begin{aligned} \varvec{\mathrm {T}}+ \varvec{\mathrm {P}}&\overset{r_\mathrm{a}}{\rightleftarrows }\varvec{\mathrm {PT}}, \end{aligned}$$
(11a)
$$\begin{aligned} \varvec{\mathrm {PT}}&\overset{r_\mathrm{d}}{\rightleftarrows }\varvec{\mathrm {P}}+\varvec{\mathrm {T}}. \end{aligned}$$
(11b)

Here, \(\varvec{\mathrm {T}}\) denotes a target molecule, \(\varvec{\mathrm {P}}\) denotes a receptor molecule, \(\varvec{\mathrm {PT}}\) denotes a probe-target complex at the sensor surface, and \(r_\mathrm{a}\) and \(r_\mathrm{d}\) are the reaction constants of the association and dissociation processes, respectively. Equation (11a) describes the binding of target molecules \(\varvec{\mathrm {T}}\) to probe molecules \(\varvec{\mathrm {P}}\). Analogously, Eq. (11b) describes the dissociation process.

In [3], we coupled a random-walk-based model for diffusive transport to the association–dissociation processes at the sensor surface in order to optimize the sensor design. It was found in [3] that the number \(\varvec{\mathrm {PT}}\) of probe-target complexes satisfies the stochastic ordinary differential equation

$$\begin{aligned} \mathrm {d}\varvec{\mathrm {P}}\varvec{\mathrm {T}}_t&= (r_\mathrm{\mathrm{a}}\varvec{\mathrm {T}}(\varvec{\mathrm {P}}-\varvec{\mathrm {P}}\varvec{\mathrm {T}}_t)-r_\mathrm{d}\varvec{\mathrm {P}}\varvec{\mathrm {T}})\mathrm {d}t\nonumber \\&\quad +\,\sqrt{r_\mathrm{a}\varvec{\mathrm {T}}(\varvec{\mathrm {P}}-\varvec{\mathrm {P}}\varvec{\mathrm {T}}_t)}\mathrm {d}B_1-\sqrt{r_\mathrm{d} \varvec{\mathrm {P}}\varvec{\mathrm {T}}_t}\mathrm {d}B_2, \end{aligned}$$
(12a)
$$\begin{aligned} \varvec{\mathrm {PT}}_0&= 0, \end{aligned}$$
(12b)

where \(\mathrm {d}B_\mathrm{i}\) indicates a Wiener process. The initial condition means that there is no probe-target complex present at the surface in the beginning. The reaction parameters are taken from [3]. The simulation was performed for a receptor density of \(3\times 10^{12}\,\mathrm {cm^{-2}}\) and 40 target molecules in the liquid for a nanowire with \(80\,\mathrm {nm}\) diameter. The surface was partitioned into three different regions, called edge, middle, and corner regions as illustrated in Fig. 2. In addition, the average probe-target concentration at the surface is called the overall concentration. Table 1 gives the equilibrium values of \(\varvec{\mathrm {PT}}\) in these regions and Fig. 3 shows the probability density distributions; these values are used in the numerical experiments.

Fig. 2
figure 2

A cross section of the field-effect sensor indicating the three different regions of the surface

Table 1 The expected values and variances of the probe-target concentration \(\varvec{\mathrm {PT}}\) at the nanowire sensor surface [4]
Fig. 3
figure 3

Histograms of the \(\varvec{\mathrm {PT}}\)-complex density in equilibrium at the corners (top left), in the middle (top right), at the edges (bottom left), and overall (bottom right). The green lines show a Gaussian distribution with the parameters in Table 1 (Color figure online)

3 Multi-level Monte–Carlo finite-element method (MLMC-FEM)

In this section, the multi-level Galerkin finite-element method, whose optimal variant will be developed in Sect. 4, is described.

We partition the domain D into quasi-uniform tetrahedra and construct a regular mesh \(\tau _{h_0}\), which is the coarsest one. Here \(h_0\) denotes the maximum diameter of the tetrahedra in the mesh. Then, the mesh is regularly refined using a geometric sequence of maximum diameters. Thus, a nested family \(\{ \tau _{h_\ell } \}_{\ell =0}^\infty \) of regular tetrahedra is constructed. We define

$$\begin{aligned} h_\ell :=\max _{K\in \tau _{h_\ell }}\{ \text {diam}(K)\}, \end{aligned}$$
(13)

where

$$\begin{aligned} h_\ell =r^{-\ell } h_0, \qquad r>1, \end{aligned}$$
(14)

holds for the \(\ell \)th refined mesh according to construction.

To avoid deteriorating mesh quality during refinement, its shape regularity of meshes is essential. The regular meshes are \(\kappa \)-shape regular. This means that there exists a constant \(\kappa \in \mathbb {R}\) independent of \(\ell \) such that

$$\begin{aligned} \frac{h_\mathrm{K}}{\rho _\mathrm{K}} \le \kappa \qquad \forall K \in \tau _{h_\ell } \end{aligned}$$

holds, where \(\rho _\mathrm{K}\) is the radius of the largest ball that can be inscribed into \(K \in \tau _{h_\ell }\).

The Hilbert spaces

$$\begin{aligned} X:=H_g^1(D) \quad \text {and}\quad X_0:=H_0^1(D) \end{aligned}$$

are used as solution and test spaces, where g is the Dirichlet boundary value. For a mesh \(\tau _h\), we define the finite-element space \(X_{h_\ell } \subset X\) as

$$\begin{aligned} X_{h_\ell } := P^k(D,\tau _{h_\ell }) := \{u\in X \mid u \vert _K\in P^k(K) \;\; \forall K\in \tau _{h_\ell } \}, \end{aligned}$$

where \(P^k(K) := {\text {span}}\{ x^{\alpha } \mid |\alpha | \le k\}\) is the space of polynomials of total degree k. We use \( X_{h_\ell }:=P^1(\tau _{h_\ell })\) here.

To define the weak formulations and the Galerkin approximations of the model equations (8), we consider the abstract boundary-value problem

$$\begin{aligned}&-\nabla \cdot (A^*(x)\nabla w(x,\omega ))+h(x,w(x,\omega ))= f(x,\omega ) \quad \forall x \in D \setminus \Gamma , \end{aligned}$$
(15a)
$$\begin{aligned}&w(x,\omega )=w_\mathrm{D}(x) \quad \forall x \in \partial D_\mathrm{D}, \end{aligned}$$
(15b)
$$\begin{aligned}&\mathbf {n}\cdot \nabla w(x,\omega )=0 \quad \forall x \in \partial D_\mathrm{N}, \end{aligned}$$
(15c)
$$\begin{aligned}&w (0+,y,\omega )-w (0-,y,\omega ) = \alpha (y,\omega ) \quad \forall x \in \Gamma , \end{aligned}$$
(15d)
$$\begin{aligned}&A^*(0+)\partial _x w (0+,y,\omega )-A^*(0-)\partial _x w (0-,y,\omega ) = \gamma (y,\omega ) \quad \forall x \in \Gamma \end{aligned}$$
(15e)

for all \(\omega \in \varOmega \), which includes all the elliptic problems that constitute the system (8) of equations: (15a) includes (8a)–(8d) if \(A^*\) is replaced by the permittivity A, and it includes (8g)–(8h) if \(A^*\) is replaced, respectively, by \(\mu _\mathrm{n}e^{-(\Phi _2-V)/U_\mathrm{T}}\) and \(\mu _\mathrm{p}e^{(\Phi _1-V)/U_\mathrm{T}}\).

We define the Galerkin approximation of the solution of (15) as follows.

Definition 1

(Galerkin approximation) Let \(X_{h_\ell }\subset X\) be the discrete solution space and let \(X_{0h_\ell }\subset X_0\) be discrete test space. The Galerkin approximation of Eq. (15) is the set of functions \(w_{h_\ell }(x,\omega )\in L^2(\varOmega ;X_{h_\ell })\) that satisfies

$$\begin{aligned} B(w_{h_\ell },\phi _{h_\ell })=F(\phi _{h_\ell }) \quad \forall \phi _{h_\ell } \in L^2(\varOmega ; X_{0h_\ell }), \end{aligned}$$
(16)

where \(B:L^2(\varOmega ;X_{h_\ell }) \times L^2(\varOmega ;X_{0h_\ell })\rightarrow \mathbb {R}\) and \(F:L^2(\varOmega ; X_{0h_\ell })\rightarrow \mathbb {R}\) are defined by

$$\begin{aligned} B(w_{h_\ell },\phi _{h_\ell }):= & {} \mathbb {E}\left[ \int _D A^*\nabla w_{h_\ell }\cdot \nabla \phi _{h_\ell }\mathrm {d}x\right] \\&+\,\mathbb {E}\left[ \int _D h\left( w_{h_\ell }\right) \phi _{h_\ell } \mathrm {d}x \right] \end{aligned}$$

and

$$\begin{aligned} F(\phi _{h_\ell }) := \mathbb {E}\left[ \int _D f \phi _{h_\ell } \mathrm {d}x\right] + \mathbb {E}\left[ \int _\Gamma \gamma \phi _{h_\ell } \mathrm {d}x \right] . \end{aligned}$$
Fig. 4
figure 4

Statistical and discretization errors for different mesh sizes. The coefficients \(\alpha \) and \(\beta \) behave according to (20)

Equation (15) will be solved later for fixed \(\omega \in \varOmega \) using Scharfetter–Gummel iteration for solving (8). The iteration continues until the condition

$$\begin{aligned} \max \{ \Vert V_{k+1}-V_k \Vert _{L^\infty }, \Vert u_{k+1}-u_k \Vert _{L^\infty }, \Vert v_{k+1}-v_k \Vert _{L^\infty }\} < \delta \end{aligned}$$
(17)

is satisfied, where \(\delta \in \mathbb {R}\) is a given error tolerance, and \(V_k,u_k\) and \(v_k\) are the approximations of the solutions of system (8) in the kth iteration.

Now the multi-level Monte–Carlo (MLMC) approximation can be introduced. Instead of calculating the expected value \(\mathbb {E}[u]\) by \(\mathbb {E}[u_h]\) on a constant triangulation \(\tau _h\), the multi-level Monte–Carlo method calculates the expected value \(\mathbb {E}[u]\) using several \(\mathbb {E}[u_{h_{\ell }}]\), \(\ell \in \{0,1,\ldots ,L\}\), calculated on a nested family \(\{\tau _{h_{\ell }} \}_{{\ell }=0}^{\infty }\) with \(h_\ell =r^{-\ell }h_0\). Obviously \(h_0>h_1> \cdots >h_L\) holds, where \(h_0\) denotes the mesh size of the coarsest level 0 and \(r>1\) is independent of the level \(\ell \).

On each level \(\ell \), the standard Monte–Carlo estimator is used to calculate \(\mathbb {E}[u_h]\). The expected value of the solution on level L can be written as the telescoping sum

$$\begin{aligned} \mathbb {E}[u_{h_L}] = \mathbb {E}[u_{h_0}] + \sum _{\ell =1}^{L}{\mathbb {E}}[u_{h_\ell }-u_{h_{\ell -1}}], \end{aligned}$$
(18)

involving the solutions \(u_{h_\ell }\) calculated using the mesh \(\tau _{h_\ell }\).

On each level \(\ell \), the standard Monte–Carlo estimator uses \(M_\ell \) samples to approximate \({\mathbb {E}}[u_{h_\ell }-u_{h_{\ell -1}}]\). Hence the multi-level Monte–Carlo estimator for \({\mathbb {E}}[u]\) is defined as

$$\begin{aligned} {{\mathrm{E_\mathrm {MLMC}}}}[u] :=\hat{u}_{h_L} :=\frac{1}{M_0} \sum _{i=1}^{M_0} u_{h_0}^{(i)} + \sum _{\ell =1}^{L}\frac{1}{M_\ell } \sum _{i=1}^{M_\ell }\left( u_{h_\ell }^{(i)}-u_{h_{\ell -1}}^{(i)}\right) , \end{aligned}$$
(19)

where the solutions \(u_{h_\ell }^{(i)}\) and \(u_{h_{\ell -1}}^{(i)}\) correspond to the same sample \(\omega \in \varOmega \) with number i, but are calculated on different meshes, namely on \(\tau _{h_\ell }\) and \(\tau _{h_{\ell -1}}\), respectively. It can be shown [11, Theorem 5] that if the convergence orders of the finite-element approximation and of the variance are assumed to be \(\alpha \) and \(\beta \), respectively, i.e., if the inequalities

$$\begin{aligned} \Vert \mathbb {E}[u - u_{h_\ell }]\Vert _{L^2(\varOmega ;X)}&\le C_1 h_\ell ^\alpha&\exists C_1\in \mathbb {R}^+, \end{aligned}$$
(20a)
$$\begin{aligned} \sigma ^2[u_{h_\ell } - u_{h_{\ell -1}}]&\le C_0 h_{\ell -1}^\beta&\exists C_0\in \mathbb {R}^+, \end{aligned}$$
(20b)
$$\begin{aligned} \sigma ^2[u_{h_0}]&\le C_{00}&\exists C_{00}\in \mathbb {R}^+ \end{aligned}$$
(20c)

hold for all \(\ell \in \{0,1,\ldots ,L\}\), then the mean-square error of the MLMC approximation of the expected value of the solution of (8) satisfies

$$\begin{aligned} \Vert \mathbb {E}[u] - \hat{u}_{h_L} \Vert _{L^2(\varOmega ;X)}^2 =O(h_L^{2\alpha }) + O(M_0^{-1}) + \sum _{\ell =1}^{L} O(M_\ell ^{-1})O(h_{\ell -1}^\beta ), \end{aligned}$$
(21)

which will be used later in Sect. 4.

The assumptions (20) hold indeed, as the convergence orders illustrated in Fig. 4 show. Additionally, the coefficients \(C_0\) and \(C_1\) are estimated in this figure as well. The coefficient \(C_{00}\) in (20c) is an upper bound for the variance of the solution using the coarsest mesh size \(h_0\).

4 The optimal multi-level Monte–Carlo approximation

The multi-level Monte–Carlo approximation in Sect. 3 still contains several as yet unknown discretization parameters, namely the number of levels L, the mesh sizes \(h_\ell \) on each level \(\ell \), and the number \(M_\ell \) of samples to be used on each level \(\ell \). Here we determine these parameters by solving an optimization problem: the total computational work is minimized for a prescribed total error. It turns out that this approach reduces the total computational work compared to the standard Monte–Carlo method by orders of magnitude.

We start by modeling the computational work. Since the model equations (8) are a system of equations, the computational work consists of the sum of the work necessary to solve each of the three equations, i.e., the Poisson equation for V and the drift–diffusion equations for u and v. Because the computational work for each of the two drift–diffusion equations is the same, the computational work for solving the system (8) once is given by

$$\begin{aligned} W_\ell := W_\mathrm{P} + 2W_\mathrm{D} = W_\mathrm{P,a} + W_\mathrm{P,s} + 2W_\mathrm{D,a} + 2W_\mathrm{D,s}, \end{aligned}$$
(22)

where the index P indicates the Poisson equation, the index D indicates the drift–diffusion equations, the index a denotes the assembly of the system matrix, and the index s denotes solving the system matrix. Since assembling the system matrix and solving the system scale differently, these steps are modeled by separate terms.

Each of the four parts of the computational work has the form \(\mu _k h_\ell ^{-\gamma _k}\), \(k \in \{1,\dots ,4\}\), with \(\mu _k >0\) and \(\gamma _k>0\), which are multiplied by the number \(M_\ell \) of samples at level \(\ell \). Hence, the total work W is

$$\begin{aligned} \begin{aligned} W&:= \sum _{\ell =0}^L M_\ell W_\ell \\&= \sum _{\ell =0}^L M_\ell (W_{\ell ,\mathrm{P,a}} + W_{\ell ,\mathrm{P,s}} +2W_{\ell ,\mathrm{D,a}} + 2W_{\ell ,\mathrm{D,s}})\\&=\sum _{\ell =0}^L M_\ell (\mu _1 h_\ell ^{-\gamma _1} +\mu _2 h_\ell ^{-\gamma _2} + \mu _3 h_\ell ^{-\gamma _3} + \mu _4 h_\ell ^{-\gamma _4}), \end{aligned} \end{aligned}$$
(23)

where the exponents are determined by the algorithms and implementations used for assembling the finite-element matrix and by the order of the finite-element discretization. Additionally, the constants \(\mu _i > 0\) depend on the implementation.

In order to minimize the computational cost, we determine the optimal parameters \(\{h_{\ell }\}_{\ell =0}^{L}\) (via the optimal \(h_0\) and r) and \(\{M_{\ell }\}_{\ell =0}^{L}\) by solving the minimization problem

(24)

where \(h_0>0\), \(r>1\), \(M_\ell \ge 1\), and \(\varepsilon ^2\) is the prescribed total error, i.e., the sum of the statistical and discretization errors.

In order to calculate the optimal number \(M_\ell \) of samples at level \(\ell \), we consider the equation

$$\begin{aligned} \frac{\partial }{\partial M_\ell } (f+\xi ^2 g)=0, \quad \ell \in \{0,\ldots ,L\}, \end{aligned}$$
(25)

where \(\xi ^2\) is the Lagrange multiplier. Equation (25) results in

$$\begin{aligned} M_\ell =\xi \sqrt{V_\ell /W_\ell }, \end{aligned}$$

where \(V_0=C_{00}\) and \(V_\ell =C_0 h_{\ell -1}^\beta \). In order to simplify the optimization problem (24), we define a new variable \(0<\theta <1\) such that the equations

$$\begin{aligned} \frac{ C_{00}}{ M_0} + C_0 \sum _{\ell =1}^{L} \frac{ h_{\ell -1}^\beta }{M_\ell }=\theta \varepsilon ^2 \qquad \text {and} \qquad (C_1h_L^{\alpha })^2=(1-\theta )\varepsilon ^2 \end{aligned}$$
(26)

hold. Since the Lagrange multiplier is \( \xi =(\theta \epsilon ^2)^{-1} \sum _{\ell =0}^{L}\sqrt{V_\ell W_\ell }\), and \( h_0=\left( \frac{\sqrt{1-\theta } \varepsilon }{C_1}\right) ^{1/\alpha }r^L\) due to (26), the problem (24) is reduced to a simpler, two-dimensional optimization problem for \(\theta \) and r.

Since the optimization problem is a constrained nonlinear optimization problem, we use a gradient-based technique, namely the nonlinear interior-point method, in order to solve the problem numerically. Furthermore, the optimal necessary number of levels is found once the computational cost is calculated for various levels using the optimal values of \(M_\ell \) and \(h_\ell \). Since the optimal numbers \(M_\ell \) of samples at level \(\ell \) are in general not integers, they are rounded up and replaced by \(\lceil M_\ell \rceil \).

5 Three-dimensional numerical results

Having discussed the optimal numerical approach, numerical results for two three-dimensional structures are shown in this section. The two applications are nanowire field-effect biosensors and FinFETs.

5.1 Nanowire field-effect biosensors

As mentioned in the introduction, a nanowire field-effect biosensor is a field-effect transistor that is gated by changes in the surface potential induced by the binding of molecules [12, 19, 20]. The geometry of the device is shown in Fig. 1 and the random binding of the molecules at different regions of the device is illustrated in Fig. 2. The corresponding 3D meshes for a nanowire sensor \(50\,\mathrm {nm}\) thick, \(60\,\mathrm {nm}\) wide, \(500\,\mathrm {nm}\) long, and containing 15 dopants are depicted in Fig. 5.

Fig. 5
figure 5

The meshes for the nanowire field-effect sensor for \(\ell =0\) (left) and \(\ell =1\) (right). The subdomains are depicted with gray (substrate), golden (nanowire), and green (electrolyte) meshes. The randomly distributed molecules and the dopants are inside the electrolyte and the nanowire, respectively (Color figure online)

As aforementioned, solving the optimization problem (24) with respect to a given error bound yields \({h_{\ell }}\) and \({M_{\ell }}\) on each level \(\ell \). The optimization problem depends on the constants \(\mu _k\) and \(\gamma _k\), \(k\in \{1,\ldots ,4\}\). They are measured by running three-dimensional simulations and saving the CPU time needed for assembling the system matrices and solving the three elliptic equations that constitute (8). The values are shown in Table 2 and depend on the implementation and hardware used. The values shown in the table stem from simulations using a computer with an Intel Core i5-4430 3.00 GHz processor with four cores and 8 GB of memory.

Table 2 The measured constants in (23)

If there is only one level (\(L=0\)), then the multi-level Monte–Carlo method simplifies to the standard Monte–Carlo method. A comparison between the optimized Monte–Carlo and the optimized multi-level Monte–Carlo methods is drawn in Fig. 6. The effectiveness of the MLMC method is more pronounced for smaller tolerance levels. At the smallest error tolerance in this figure, the MLMC method is more efficient by more than two orders of magnitude. The coefficients and the exponents, i.e., \(\alpha \) and \(\beta \) in (20), are shown in Fig. 4, where \(C_{00}=2.95\). The estimated exponents (here \(\gamma \approx 3.0875\)) also agree well with the three-dimensional simulations. The optimal number of samples and the mesh sizes for the optimized Monte Carlo and multi-level Monte–Carlo are summarized in Tables 3 and 4, respectively.

The measured constants satisfy the assumptions of the standard complexity theorem [21], i.e., \(\alpha \ge \frac{1}{2} \min (\beta ,\gamma )\). According to this theorem, the computational cost of the MLMC method is \(\mathcal {O}(\varepsilon ^{-2})\) agreeing with the numerical results. Furthermore, the total cost of the Monte–Carlo method is \(\mathcal {O}(\varepsilon ^{-3.5})\) according to the figure, which agrees with [22].

Fig. 6
figure 6

A comparison of the total computational work necessary in the MC and MLMC methods as a function of the prescribed total error

Table 3 Optimal parameters for the Monte–Carlo method
Table 4 Optimal parameters for the MLMC method
Fig. 7
figure 7

The expected value of the electrical current as a function of back-gate voltage for \(60\,\mathrm {nm}\) width (left) and \(100\,\mathrm {nm}\) width (right) for continuum and discrete models. Here, the discrete model points out the biological noise in addition to the RDF and in continuum model only the RDF is considered. In the simulation, the results are with the experimental data [23] with the same main parameters, i.e., \(t_\text {ox}=8\,\mathrm {nm}\), \(C_\mathrm {dop}=1\times 10^{16}\mathrm {cm^{-3}}\), \(V_{\text {SD}}=0.2\,\mathrm {V}\), the nanowire thickness of \(50\,\mathrm {nm}\) and \(\mu _\mathrm{p}=100~\text {cm}^{-2}\,\text {V}^{-1}\,\text {s}^{-1}\)

Fig. 8
figure 8

Histograms of the electrical current calculated by the discrete model with 941 simulations for a doping concentration of \(1\times 10^{16}\,\mathrm {cm^{-3}}\) (left) and for a doping concentration of \(1\times 10^{17}\,\mathrm {cm^{-3}}\) (right)

Fig. 9
figure 9

The expected value of the current for \(V_\mathrm{SD}=0.4\,\mathrm {V}\) and \(V_\mathrm{SD}=0.6\,\mathrm {V}\) for both the continuum and the discrete model

Fig. 10
figure 10

The three-dimensional geometry of the FinFET investigated here. The dopant atoms are distributed in the source and drain regions

As already mentioned, only the biological noise (random movement and random orientation) is taken into account in the continuum model, whereas the effect of random dopants is also included in the discrete model. Figure 7 shows the expected value of the electrical current as a function of different gate voltages for two devices that are 60 and \(100\,\mathrm {nm}\) wide. The results are compared with experimental data [23]. In the simulation, the thermal voltage \(U_T\) is \(21\,\mathrm {mV}\). In the continuum model \(C_\mathrm {dop}=1\times 10^{16}\mathrm {cm^{-3}}\), the thickness of the oxide layer is \(8\,\mathrm {nm}\), the source-to-drain voltage is \(V_{\text {SD}}=0.2\,\mathrm {V}\), the salt concentration is \(30\,\mathrm {mM}\), and the molecule surface charge is \(-\,0.8\,\mathrm{q}\,\mathrm{nm}^{-2}\).

Very good agreement between the experiments and the simulations was found for both the discrete and the continuum model. The results show that the discrete model agrees better with the experiments than the continuum model. This is probably due to the fact that including the effect of the random dopants is a better model for the current compared to just taking the average doping as in the continuum model.

Figure 8 depicts the fluctuation of the current in the discrete model for two doping concentrations, namely \(C_\mathrm {dop}=1\times 10^{16}\mathrm {cm^{-3}}\) and \(C_\mathrm {dop}=1\times 10^{17}\mathrm {cm^{-3}}\). Here, the effects of random molecules and random dopants on the current are taken into account. For the lower doping concentration, the expected value of the current is \(\mathbb {E}(I)=2.17\times 10^{-13}\,\mathrm {A}\) and its standard deviation is \(\sigma (I)=2.38\times 10^{-14}\,\mathrm {A}\), while the values are \(\mathbb {E}(I)= 2.34\times 10^{-12}\,\mathrm {A}\) and \(\sigma (I)=2.90\times 10^{-12}\,\mathrm {A}\) for the higher doping concentration. The simulations show that more dopants increase the variance of the current. The figure shows that for \(C_\mathrm {dop}=1\times 10^{16}\mathrm {cm^{-3}}\) approximately 95% of the simulated currents are between \({2\times 10^{-13}}\) and \(2.4\times 10^{-13}\,\mathrm {A}\), resulting in a small fluctuation. On the other hand, the results obtained for the higher doping concentration fluctuate between \({1.80\times 10^{-13}}\) and \(1.08\times 10^{-11}\,\mathrm {A}\), indicating a larger variation.

Fig. 11
figure 11

The three-dimensional meshes for the FinFET in Fig. 10 for levels \(\ell =0\) (left) and \(\ell =1\) (right). The subdomains are indicated by red for the substrate, by yellow for the insulator, by black for the channel, by green for the source and drain regions, and blue gate (Color figure online)

Fig. 12
figure 12

Histogram of the current in the discrete model with 482 simulations for \(V_\mathrm{g}=0.1\,\mathrm {V}\) (left) and \(V_\mathrm{g}=0.2\,\mathrm {V}\) (right). The number of dopants is \(N_{\text {dop}}=80\)

Generally, applying a source-to-drain voltage \(V_\mathrm{SD}\) results in a low-resistance conducting path between the source and drain contacts. Figure 9 shows the current for the different source-to-drain voltages. Here, both models are used and the back-gate voltage varies between \(V_\mathrm{G}= -\,1\,\mathrm{V}\) and \(V_\mathrm{G}= -\,2\,\mathrm{V}\).

5.2 Fin field-effect transistor (FinFET)

In the second example, we investigate the effect of random dopant atoms on the device conductivity in a FinFET. Since the scaling of conventional MOSFET devices is limited due to short-channel effects and gate-insulator tunneling, FinFETs (fin field-effect transistors) [24], which are a genuinely three-dimensional structure, have replaced conventional MOSFETs in modern processors. FinFETs are a type of multi-gate MOSFETs. Due to the surrounding gate, better control over the channel is obtained and therefore less channel doping is necessary.

We consider a three-gate FinFET structure with a \(20\,\mathrm {nm}\) thick and \(20\,\mathrm {nm}\) high silicon fin. The channel length is \(50\,\mathrm {nm}\) with a doping concentration of \(10^{16}\,\mathrm {cm^{-3}}\). We assume that the acceptors and donors are distributed identically and independently in source and drain regions. The number of donors and acceptors is constant. In the continuum version of the model, a doping concentration of \(10^{19}\,\mathrm {cm^{-3}}\) is used for these regions.

The silicon-on-insulator (SOI) FinFET considered here and its subdomains are shown in Fig. 10. Corresponding three-dimensional meshes are shown in Fig. 11. The channel is surrounded by a \(1\,\mathrm {nm}\) thick layer of silicon dioxide. The thermal voltage is \(U_\mathrm{T}=26\,\mathrm {mV}\) and \(V_{\text {SD}}=0.1\,\mathrm {V}\) is applied.

Fig. 13
figure 13

Histogram of the current in the discrete model with 482 simulations for \(V_\mathrm{g}=0.1\,\mathrm {V}\) (left) and \(V_\mathrm{g}=0.2\,\mathrm {V}\) (right). The number of dopants is \(N_{\text {dop}}=20\)

Here we simulate the subthreshold current. In the subthreshold regime, the gate voltage is below the threshold voltage so that no inversion channel is formed. In this regime, the diffusion component of the current is more pronounced than the drift component. The number \(N_\text {dop}\) of dopants and the doping concentration \(C_\mathrm {dop}\) are related by \(N_\text {dop} = V \cdot C_\mathrm {dop}\) of course, where V is the volume of the subdomain. The occupation probability follows a Poisson distribution with the parameter \(\lambda =\sqrt{N_{\text {dop}}}\).

In the continuum model, both the doping in the source and drain regions and the doping in the channel are uniform. In the discrete model, the random locations of the dopants in the source and drain regions as well as randomness in the number of dopants result in device variations. For \(V_\mathrm{g}=0.1\,\mathrm {V}\) and \(V_\mathrm{g}=0.2\,\mathrm {V}\), these variations are shown in Figs. 12 and 13, respectively, for \(N_{\text {dop}}=20\) and \(N_{\text {dop}}=80\) (number of dopants in the source and drain regions). The results indicate that in the discrete model, the higher number of dopants decreases current fluctuation. As an example, for the lower gate voltage, the simulation for \(N_{\text {dop}}=80\) yields \(\sigma (I)=8.99\times 10^{-9}\,\mathrm {A}\), while the simulation for \(N_{\text {dop}}=20\) yields \(\sigma (I)=1.27\times 10^{-8}\,\mathrm {A}\).

Figure 14 depicts the subthreshold current obtained by both models for different gate voltages varying from \(V_\mathrm{g}= -\,0.1\,\mathrm{V}\) to \(V_\mathrm{g}=0.4\,\mathrm {V}\) for three different numbers of dopants, namely \(N_{\text {dop}}=20\), \(N_{\text {dop}}=40\), and \(N_{\text {dop}}=80\). The results show that for different gate voltages, the difference between the higher number of dopants and the continuum model is not significant. However, a noticeable discrepancy is obtained with \(N_{\text {dop}}=20\).

Fig. 14
figure 14

The expected value of the current as a function of different gate voltages calculated using the continuum and discrete models

6 Conclusions

We have developed an efficient three-dimensional multi-level Monte–Carlo finite-element method for the stochastic drift–diffusion–Poisson system to simulate randomness and process variations due to target molecules (in biosensors) and dopant atoms (in FinFET devices). The most noticeable advantage of this method compared to classical methods such as Monte Carlo is the much reduced computational expense. An optimization problem is solved for a given tolerance level to find the optimal parameters \(M_\ell \), \(h_\ell \), and L.

We studied the effect of random dopant fluctuation as a concrete example. In the (classical) continuum model, the doping concentration is considered as a macroscopic quantity and the effect of the dopants is averaged out. In the discrete model, the dopant atoms have microscopic structure and the device variation due to the individual dopants was quantified. We calculated the fluctuation of the current in the subthreshold regime in a FinFET for different gate voltages and compared the results with the continuum model.

In another example, namely in nanowire field-effect sensors, we used a fully three-dimensional system of stochastic PDE, namely the stochastic drift–diffusion–Poisson system, to model the effects of random DNA oligomers in a liquid on a semiconductor. We first compared the simulation results with experimental data, where very good agreement was found. The results obtained by the discrete model, i.e, the stochastic PDE, agree better with the experiments than the (classical, deterministic) continuum model. The distributions of the molecules were obtained from a physical model, namely from a random-walk-based stochastic method to simulate the association–dissociation processes of the molecules in three specific surface regions of the nanowire.