Normal approximation of Random Gaussian Neural Networks
In this paper we provide explicit upper bounds on some distances between the
(law of the) output of a random Gaussian NN and (the law of) a random Gaussian
vector. Our results concern both shallow random Gaussian neural networks with
univariate output and fully connected and deep random Gaussian neural networks,
with a rather general activation function. The upper bounds show how the widths
of the layers, the activation functions and other architecture parameters
affect the Gaussian approximation of the ouput. Our techniques, relying on
Stein's method and integration by parts formulas for the Gaussian law, yield
estimates on distances which are indeed integral probability metrics, and
include the total variation and the convex distances. These latter metrics are
defined by testing against indicator functions of suitable measurable sets, and
so allow for accurate estimates of the probability that the output is localized
in some region of the space. Such estimates have a significant interest both
from a practitioner's and a theorist's perspective.
Nicola Apollonio, Daniela De Canditiis, Giovanni Franzina, Paola Stolfi, Giovanni Luca Torrisi
# Normal approximation of random Gaussian neural networks

###### Abstract.

In this paper we provide explicit upper bounds on some distances between the (law of the) output of a random Gaussian neural network and (the law of) a random Gaussian vector. Our main results concern deep random Gaussian neural networks, with a rather general activation function. The upper bounds show how the widths of the layers, the activation function and other architecture parameters affect the Gaussian approximation of the output. Our techniques, relying on Stein's method and integration by parts formulas for the Gaussian law, yield estimates on distances which are indeed integral probability metrics, and include the convex distance. This latter metric is defined by testing against indicator functions of measurable convex sets, and so allow for accurate estimates of the probability that the output is localized in some region of the space. Such estimates have a significant interest both from a practitioner's and a theorist's perspective.

Key words and phrases:Gaussian approximation, Neural Networks, Stein's method 2020 Mathematics Subject Classification: 60F05, 68T07 \({}^{\ast}\)Corresponding author, nicola.apollonio@cnr.it \({}^{\ddagger}\)Istituto per le Applicazioni del Calcolo "M. Picone", CNR
## 1. Introduction

This work is part of the literature studying random neural networks (NNs for short), i.e., NNs whose biases and weights are random variables. In the context of modern deep learning, the interest in these types of networks is twofold: on the one hand, they naturally constitute a prior in a Bayesian approach, on the other hand they may represent the initialization of gradient flows in empirical risk minimization, see [17] for a general reference on the subject.

Within the boundaries of this topic, many contributions in the literature have been handling the asymptotic Gaussianity of random NNs, as the number of neurons in the hidden layers tends to infinity. A seminal paper is [13], where the output of a shallow (i.e., having a single hidden layer) random NN, viewed as a stochastic process on the sphere, is shown to converge to a Gaussian process, as the number of neurons in the hidden layer grows large. From that point onward, many sophisticated results have been published for deep (i.e., having more than one hidden layer) random NNs. The starting point of our work is [9], where the output of a deep random NN, viewed as a random element on the space of continuous functions on a compact set, is proved to converge to a Gaussian process, as the number of neurons in all the hidden layers tends to infinity. Other related contributions are [11, 21, 22].

Recently, the problem of the quantitative Gaussian approximation of the output of a random NN received a lot of attention. For instance, [7], exploiting Wasserstein distances, provides quantitative versions of the results in [13] when the activation function is polynomial, ReLu and hyperbolic tangent; see [1, 5, 10] for other important related contributions. In particular, the reference [1] share with our work the idea to apply Stein's method for Gaussian approximation in the context of deep NN, although in a different mathematical setting.

A significant achievement is provided in [2] where, for the first time in the literature, is given a quantitative proof of the Gaussian behavior of the output of a deep random Gaussian NN (i.e. a random NN whose biases and weights are Gaussian distributed) with a Lipschitz continuous activation function; in [2] the distance from Gaussianity is measured by means of the 2-Wasserstein metric, which comes from the Monge-Kantorovich problem with quadratic cost. As far as shallow random Gaussian NNs with univariate output is concerned, we mention the recent manuscript [4] which provides quantitative bounds on the Kolmogorov, the total variation and the 1-Wasserstein distances between the output and a Gaussian random variable, when the activation function is sufficiently smooth and has a sub-polynomial growth. A special mention deserves the independently written paper [8] where Stein's method is used to obtain tight probabilistic bounds for various distances between the output (and its derivatives) of a deep random Gaussian NN and a Gaussian random variable. We refer the reader to Remarks 4.2, 6.2 and 6.4 for comparisons between our results and the corresponding achiements in [8].

The main contribution of this paper concerns the Gaussian approximation of the output of deep random Gaussian NNs in the convex and 1-Wasserstein distances, under mild assumptions on the activation function (which, differently from [2], can be non-Lipschitz). A specialization of these results clearly provides approximations for shallow random Gaussian NN with univariate output. However, in this specific case we furnish direct proofs, which (for various technical reasons) give the same rates under more general assumptions on the activation function.

For shallow random Gaussian NNs with univariate output, combining the Stein method for the Gaussian approximation with the integration by parts formula for the Gaussian law, we provide explicit bounds for the Kolmogorov, the total variation and the 1-Wasserstein distances between the output and a Gaussian random variable, under a minimal assumption on the activation function (see Theorem 4.1). Remarkably, we obtain the same rate of convergence as in [4], as the number of
neurons in the hidden layer grows large, our constants being presumably better than the ones in [4] (see Table 1). For deep random Gaussian NNs, the novelty of our results is that we measure the error in the Gaussian approximation of the output in terms of the convex distance (see Theorem 6.1) and of the 1-Wasserstein distance (see Theorem 6.3), for a class of activation functions which includes the family of Lipschitz continuous functions (see Proposition 5.2\((ii)\)). Remarkably, for both the convex and the 1-Wasserstein distances the rate of convergence that we obtain is of the same order as the one in [2], as the number of neurons in all the hidden layers tend to infinity. The proofs of Theorems 6.1 and 6.3 are based on the Stein method for the multivariate Gaussian approximation and the integration by parts formula for the multivariate Gaussian law. The presence of more than one hidden layers complicates the derivations of the bounds, which rely on a key estimate for the \(L^{2}\)-distance between the so-called collective observables and their limiting values (see Theorem 5.1). We emphasize that, when considering the convex distance, an expedient tool is provided by a smoothing lemma that we borrow from [16].

It is well-known that localizing the output of a random NN, i.e., having a control over the probability that the output lies in a region of the space (belonging to a large class of measurable sets), is of valuable interest for practitioners. From a theorist's point of view, the output distribution of a NN is often analytically untractable, and computing the probability that the output belongs to some measurable set resorts in performing a "heroic" mathematical integration (see e.g.[17, p. 49]). Our Theorems 4.1\((ii)\) and 6.1 offer some insights into the localization problem in a simple and efficient way for both the univariate output of a shallow random Gaussian NN and the output of a deep random Gaussian NN, respectively. We refer the reader to Section 7 for some numerical illustrations of this issue.

The paper is organized as follows. In Section 2 we introduce our toolkit such as the integral probability metrics considered in the paper and some preliminaries on the Stein method. In Section 3, first we introduce all the NNs considered in this work and then we give a brief overview of the main results in [2] and [4], comparing them with our achievements. In Section 4 we give upper bounds for the Kolmogorov, the total variation and the 1-Wasserstein distances between the (univariate) output of a shallow random Gaussian NN and a Gaussian random variable. In Section 5 we prove the aforementioned key estimate on the \(L^{2}\)-distance between the collective observables and their limiting values. In Section 6 we furnish explicit upper bounds on the convex and the 1-Wasserstein distances between the output of a deep random Gaussian NN and a Gaussian random vector. Finally, in Section 7 we present some numerical illustrations concerning the above mentioned issue of the output localization.

## 2. Preliminaries

In the present section we introduce some notation and we recall some results that will be of use throughout the paper.

### Distances between probability measures

In this paper we consider various distances between probability measures on \(\mathbb{R}^{d}\), \(d\in\mathbb{N}:=\{1,2,\ldots\}\): the total variation distance, the convex distance, the Komogorov distance, and the \(p\)-Wasserstein distances. Hereon, the symbol \(\|\cdot\|_{d}\) denotes the Euclidean norm on \(\mathbb{R}^{d}\).

**Definition 2.1**.: _The total variation distance between the laws of two \(\mathbb{R}^{d}\)-valued random vectors \(\mathbf{X}\) and \(\mathbf{Y}\), written \(d_{TV}(\mathbf{X},\mathbf{Y})\), is given by_

\[d_{TV}(\mathbf{X},\mathbf{Y}):=\sup_{B\in\mathcal{B}(\mathbb{R}^{d})}|\mathbb{ P}(\mathbf{X}\in B)-\mathbb{P}(\mathbf{Y}\in B)|,\]
_where \(\mathcal{B}(\mathbb{R}^{d})\) denotes the Borel \(\sigma\)-field on \(\mathbb{R}^{d}\)._

**Definition 2.2**.: _The convex distance between the laws of two \(\mathbb{R}^{d}\)-valued random vectors \(\mathbf{X}\) and \(\mathbf{Y}\), written \(d_{c}(\mathbf{X},\mathbf{Y})\), is given by_

\[d_{c}(\mathbf{X},\mathbf{Y}):=\sup_{g\in\mathcal{I}_{d}}|\mathbb{E}[g(\mathbf{ X})]-\mathbb{E}[g(\mathbf{Y})]|,\]

_where \(\mathcal{I}_{d}\) denotes the collection of all indicator functions of measurable convex sets in \(\mathbb{R}^{d}\)._

**Definition 2.3**.: _The Kolmogorov distance between the laws of two \(\mathbb{R}^{d}\)-valued random vectors \(\mathbf{X}=(X_{1},\ldots,X_{d})\) and \(\mathbf{Y}=(Y_{1},\ldots,Y_{d})\), written \(d_{K}(\mathbf{X},\mathbf{Y})\), is given by_

\[d_{K}(\mathbf{X},\mathbf{Y}):=\sup_{\mathbf{y}=(y_{1},\ldots,y_{d})\in\mathbb{ R}^{d}}|\mathbb{P}(X_{1}\leq y_{1},\ldots,X_{d}\leq y_{d})-\mathbb{P}(Y_{1} \leq y_{1},\ldots,Y_{d}\leq y_{d})|.\]

**Definition 2.4**.: _For \(p\in[1,+\infty)\), the \(p\)-Wasserstein distance between the laws of two \(\mathbb{R}^{d}\)-valued random vectors \(\mathbf{X}\) and \(\mathbf{Y}\), written \(d_{W_{p}}(\mathbf{X},\mathbf{Y})\), is given by_

\[d_{W_{p}}(\mathbf{X},\mathbf{Y}):=\inf_{(\mathbf{U},\mathbf{V})\in C_{( \mathbf{X},\mathbf{Y})}}\mathbb{E}[\|\mathbf{U}-\mathbf{V}\|_{d}^{p}]^{1/p},\]

_where \(C_{(\mathbf{X},\mathbf{Y})}\) is the family of all the couplings of \(\mathbf{X}\) and \(\mathbf{Y}\), i.e., the family of all random vectors \((\mathbf{U},\mathbf{V})\) such that \(\mathbf{U}\) is distributed as \(\mathbf{X}\) and \(\mathbf{V}\) is distributed as \(\mathbf{Y}\)._

Clearly, by Jensen's inequality \(d_{W_{1}}\leq d_{W_{2}}\), and it follows directly by the definitions that \(d_{K}\leq d_{c}\leq d_{TV}\). Furthermore, for all \(s=TV,c,K,W_{p}\), if \(d_{s}(\mathbf{Y}_{n},\mathbf{Y})\to 0\), as \(n\to+\infty\), where \(\mathbf{Y}_{n}\), \(n\in\mathbb{N}\), and \(\mathbf{Y}\) are random vectors with values in \(\mathbb{R}^{d}\), then \(\mathbf{Y}_{n}\) converges in law to \(\mathbf{Y}\), as \(n\to+\infty\) (see e.g. [14, 20]).

In view of the Kantorovich-Rubinstein duality (see Theorem 5.10 and Eq. (5.11) in [20]), the \(1\)-Wasserstein distance between the laws of two \(\mathbb{R}^{d}\)-valued random vectors \(\mathbf{X}\) and \(\mathbf{Y}\) such that \(\max\{\mathbb{E}\|\mathbf{X}\|_{d},\mathbb{E}\|\mathbf{Y}\|_{d}\}<\infty\), satisfies the relation

\[d_{W_{1}}(\mathbf{X},\mathbf{Y})=\sup_{g\in\mathcal{L}_{d}(1)}|\mathbb{E}[g( \mathbf{X})]-\mathbb{E}[g(\mathbf{Y})]|, \tag{2.1}\]

where \(\mathcal{L}_{d}(1)\) indicates the collection of all functions \(g:\mathbb{R}^{d}\to\mathbb{R}\) which are Lipschitz continuous with Lipschitz constant less than or equal to \(1\).

Since \(d_{c}\) is defined by testing against indicator functions of Borel convex sets rather than arbitrary Borel sets, the convex distance can be expected to be estimated easier than the total variation distance; moreover, the convex distance looks more flexible than the Kolmogorov distance, for example it enjoys a number of invariance properties not satisfied by \(d_{K}\), see [3].

As for the relation between the convex distance and the optimal transport metric \(d_{W_{1}}\), it turns out that the convex distance to a fixed centered Gaussian law is bounded from above by a multiple of the square root of the \(1\)-Wasserstein distance. More precisely, one has the following Proposition 2.5, which is proved in [15].

Here and henceforth, we denote by \(\mathbf{N}_{\Sigma}=(N_{1},\ldots,N_{d})\), \(d\in\mathbb{N}\), a centered Gaussian vector with invertible covariance matrix \(\Sigma=(\Sigma_{ij})_{1\leq i,j\leq d}\).

**Proposition 2.5**.: _For any \(d\)-dimensional random vector \(\mathbf{Y}\), we have_

\[d_{c}(\mathbf{Y},\mathbf{N}_{\Sigma})\leq 2\sqrt{2}\Gamma(\Sigma)^{1/2}d_{W_{1} }(\mathbf{Y},\mathbf{N}_{\Sigma})^{1/2},\]

_where \(\Gamma(\Sigma)\) is the constant defined by_

\[\Gamma(\Sigma):=\sup_{Q,\,\epsilon>0}\frac{\mathbb{P}(\mathbf{N}_{\Sigma}\in Q ^{\epsilon})-\mathbb{P}(\mathbf{N}_{\Sigma}\in Q)}{\epsilon}, \tag{2.2}\]
_where \(Q\) ranges over all the Borel measurable convex subsets of \(\mathbb{R}^{d}\), and \(Q^{\epsilon}\) denotes the set of all elements of \(\mathbb{R}^{d}\) whose Euclidean distance from \(Q\) does not exceed \(\epsilon\)._

\(\Gamma(\Sigma)\) is in fact an isoperimetric constant. Indeed, if \(Q\) is a bounded convex Borel set, then it is easily seen that

\[\sup_{\epsilon>0}\frac{\mathbb{P}(\mathbf{N}_{\Sigma}\in Q^{\epsilon})- \mathbb{P}(\mathbf{N}_{\Sigma}\in Q)}{\epsilon}=\int_{\partial Q}h_{\Sigma} \left(\mathbf{x},\boldsymbol{\nu}_{\mathbf{x}}^{Q}\right)d\,\mathscr{H}^{d-1}\,,\]

where \(\mathscr{H}^{d-1}\) is the \((d-1)\)-dimensional Hausdorff measure, for \(\mathscr{H}^{d-1}\)-a.e. boundary point \(\mathbf{x}\) we are denoting by \(\boldsymbol{\nu}_{\mathbf{x}}^{Q}\) the outward unit normal to \(\partial Q\) at \(\mathbf{x}\), and we have set

\[h_{\Sigma}(\mathbf{x},\boldsymbol{\nu}):=(2\pi)^{-d/2}e^{-\frac{|\mathbf{x}| ^{2}}{2}}\|\Sigma^{-\frac{1}{2}}\boldsymbol{\nu}_{\mathbf{x}}^{Q}\|_{d}\,, \qquad\text{for all }(\mathbf{x}\,,\boldsymbol{\nu})\in\mathbb{R}^{d}\times \mathbb{S}^{d-1},\]

where \(\mathbb{S}^{d-1}\) is the unit sphere of \(\mathbb{R}^{d}\). Thus, \(\Gamma(\Sigma)\) is the worst (largest) possible anisotropic Gaussian perimeter for a convex body in \(\mathbb{R}^{d}\).

We refer the reader to [12] for the following bound

\[e^{-\frac{5}{4}}d^{1/4}\leq\Gamma(\Sigma)\leq(2\pi)^{-\frac{1}{4}}d^{1/4}. \tag{2.3}\]

### The one-dimensional Stein equation

Throughout this paper, we denote by \(\mathcal{N}(\mu,\eta)\) the one-dimensional Gaussian law with mean \(\mu\in\mathbb{R}\) and variance \(\eta>0\), and let \(Z\sim\mathcal{N}(0,1)\).

The celebrated Stein equation for the one-dimensional Normal approximation [18] is given by

\[g(w)-\mathbb{E}g(Z)=f_{g}^{\prime}(w)-wf_{g}(w), \tag{2.4}\]

where \(g:\mathbb{R}\to\mathbb{R}\) is a measurable function such that \(\mathbb{E}|g(Z)|<\infty\) and \(f_{g}:\mathbb{R}\to\mathbb{R}\) is unknown. The following lemma holds, see e.g. Proposition 3.2.2, Theorem 3.3.1, Theorem 3.4.2 and Proposition 3.5.1 in [14]. See [6] for an introduction on the Stein method.

Hereon, for a Lipschitz continuous function \(g:\mathbb{R}^{d}\to\mathbb{R}\) we denote by \(\mathrm{Lip}(g)\) the Lipschitz constant of \(g\), and for a function \(f:\mathbb{R}^{d}\to\mathbb{R}\) we denote by \(\|f\|_{\infty}\) the supremum norm of \(f\).

**Lemma 2.6**.: _The following claims hold:_

\((i)\) _For any \(y\in\mathbb{R}\), the Stein equation (_2.4_) with \(g(w):=\mathbf{1}_{(-\infty,y]}(w)\) has a unique solution \(f_{g}\) and \(\|f_{g}^{\prime}\|_{\infty}\leq 1\)._

\((ii)\) _Let \(g:\mathbb{R}\to[0,1]\) be a measurable function. Then there exists a unique solution \(f_{g}\) of the Stein equation (_2.4_) and \(\|f_{g}^{\prime}\|_{\infty}\leq 2\)._

\((iii)\) _Let \(g:\mathbb{R}\to\mathbb{R}\) be a Lipschitz continuous function. Then there exists a unique solution \(f_{g}\) of the Stein equation (_2.4_) and \(\|f_{g}^{\prime}\|_{\infty}\leq\mathrm{Lip}(g)\sqrt{2/\pi}\)._

### The multidimensional Stein equation

Throughout this paper, given a sufficiently smooth function \(f:\mathbb{R}^{d}\to\mathbb{R}\), we define

\[\partial_{i_{1}i_{1}\ldots i_{n}}^{n}f(x_{1},\ldots,x_{d}):=\frac{\partial^{n} f}{\partial x_{i_{1}}\ldots\partial x_{i_{n}}}(x_{1},\ldots,x_{d}).\]

Let \(\mathcal{M}_{d\times d}(\mathbb{R})\), \(d\in\mathbb{N}\), be the set of \(d\times d\) real matrices. For a function \(f\in C^{2}(\mathbb{R}^{d})\), we denote by \(\mathrm{Hess}\,f(\mathbf{y})\in\mathcal{M}_{d\times d}(\mathbb{R})\) the Hessian matrix of \(f\) at \(\mathbf{y}\in\mathbb{R}^{d}\) and by \(\|\cdot\|_{op}\) the operator norm on \(\mathcal{M}_{d\times d}(\mathbb{R})\), i.e., for any \(\Gamma\in\mathcal{M}_{d\times d}(\mathbb{R})\), \(\|\Gamma\|_{\mathrm{op}}:=\sup_{\mathbf{y}:\ \|\mathbf{y}\|_{d}=1}\|\Gamma\mathbf{y}\|_{d}\). We consider the Hilbert-Schmidt inner product and the Hilbert-Schmidt norm on \(\mathcal{M}_{d\times d}(\mathbb{R})\), which are defined, respectively, by

\[\langle\Gamma,\Psi\rangle_{H.S.}:=\mathrm{Tr}(\Gamma\Psi^{\top})=\sum_{i,j=1}^ {d}\Gamma_{ij}\Psi_{ij}\quad\text{and}\quad\|\Gamma\|_{H.S.}=\sqrt{\langle \Gamma,\Gamma\rangle_{H.S.}}\]
for every pair of matrices \(\Gamma=(\Gamma_{ij})_{1\leq i,j\leq j}\) and \(\Psi=(\Psi_{ij})_{1\leq i,j\leq d}\), where the symbols \(\operatorname{Tr}(\Gamma)\) and \(\Gamma^{\top}\) denote, respectively, the trace and the transpose of the matrix \(\Gamma\).

The Stein equation for multivariate Normal approximation is defined as

\[g(\mathbf{y})-\mathbb{E}[g(\mathbf{N}_{\Sigma})]=\langle\mathbf{y},\nabla f_{ g}(\mathbf{y})\rangle_{d}-\langle\Sigma,\operatorname{Hess}f_{g}(\mathbf{y}) \rangle_{H.S.},\quad\mathbf{y}\in\mathbb{R}^{d} \tag{2.5}\]

where \(g:\mathbb{R}^{d}\to\mathbb{R}\) is given and \(f_{g}\) is unknown. Throughout this paper the symbol \(\langle\cdot,\cdot\rangle_{d}\) denotes the inner product in \(\mathbb{R}^{d}\).

The following lemmas provide solutions to Stein's equation (2.5), under different assumptions on \(g\).

**Lemma 2.7**.: _Let \(g\in\mathcal{L}_{d}(1)\). Then the function_

\[f_{g}(\mathbf{y}):=\int_{0}^{\infty}\mathbb{E}[g(\mathbf{N}_{\Sigma})-g( \mathrm{e}^{-t}\mathbf{y}+\sqrt{1-\mathrm{e}^{-2t}}\mathbf{N}_{\Sigma})]\, \mathrm{d}t,\quad\mathbf{y}\in\mathbb{R}^{d}\]

_is such that: \(f_{g}\in C^{2}(\mathbb{R}^{d})\), \(f_{g}\) solves (2.5), \(f_{g}\) satisfies_

\[\|\partial_{i}f_{g}\|_{\infty}\leq 1,\quad\text{for any $i=1,\ldots,d$} \tag{2.6}\]

_and_

\[\sup_{\mathbf{y}\in\mathbb{R}^{d}}\|\mathrm{Hess}f_{g}(\mathbf{y})\|_{H.S.} \leq\sqrt{d}\|\Sigma^{-1}\|_{\sigma p}\|\Sigma\|_{op}^{1/2}.\]

**Lemma 2.8**.: _For \(g:\mathbb{R}^{d}\to\mathbb{R}\) measurable and bounded, define the smoothed function_

\[g_{t}(\mathbf{y}):=\mathbb{E}[g(\sqrt{t}\mathbf{N}_{\Sigma}+\sqrt{1-t}\mathbf{ y})],\quad\mathbf{y}\in\mathbb{R}^{d}, \tag{2.7}\]

_where \(t\in(0,1)\) is a smoothing parameter. Then: \((i)\) For any \(t\in(0,1)\), the function_

\[f_{t,g}(\mathbf{y}):=\frac{1}{2}\int_{t}^{1}\frac{1}{1-s}\mathbb{E}[g(\sqrt{s} \mathbf{N}_{\Sigma}+\sqrt{1-s}\mathbf{y})-g(\mathbf{N}_{\Sigma})]\,\mathrm{d }s,\quad\mathbf{y}\in\mathbb{R}^{d}\]

_is such that: \(f_{t,g}\in C^{2}(\mathbb{R}^{d})\), \(f_{t,g}\) solves (2.5) with \(g_{t}\) in place of \(g\), and_

\[\|\partial_{i}f_{t,g}\|_{\infty}\leq\|g\|_{\infty}\sqrt{\frac{1-t}{t}}\sum_{ \ell,j=1}^{d}(\Sigma^{-1/2})_{\ell j}(\Sigma^{-1/2})_{\ell i}\sqrt{\Sigma_{jj} },\quad\text{for any $i=1,\ldots,d$.} \tag{2.8}\]

\((ii)\) _For any \(d\)-dimensional random vector \(\mathbf{Y}\) it holds_

\[\sup_{g\in\mathcal{J}_{d}}\mathbb{E}\|\mathrm{Hess}(f_{t,g}(\mathbf{Y}))\|_{H. S.}^{2}\leq\|\Sigma^{-1}\|_{op}^{2}(d^{2}(\log t)^{2}d_{c}(\mathbf{Y}, \mathbf{N}_{\Sigma})+530d^{17/6}),\quad\text{for any $t\in(0,1)$.}\]

See Proposition 4.3.2 in [14] for Lemma 2.7; in particular in [14] it is noticed that

\[\partial_{i}f_{g}(\mathbf{y})=-\int_{0}^{\infty}\mathrm{e}^{-t}\mathbb{E} \left[\partial_{i}g(\mathrm{e}^{-t}\mathbf{y}+\sqrt{1-\mathrm{e}^{-2t}} \mathbf{N}_{\Sigma})\right]\mathrm{d}t,\quad i=1,\ldots,d\]

which, combined with the fact that \(g\in\mathcal{L}_{d}(1)\), gives the bound (2.6); see [16] p. 12 and Proposition 2.3 for Lemma 2.8, and Lemma 3.6\((ii)\) in [19] for the bound (2.8).
### The smoothing lemma and the integration by parts formula for Gaussian random vectors

We state a remarkable smoothing lemma for the convex distance proved in [16], see Lemma 2.2 therein. It plays a crucial role in the proof of the Normal approximation of the output of a deep random Gaussian NN in the metric \(d_{c}\), see Theorem 6.1.

**Lemma 2.9**.: _Let \(\mathbf{Y}\) be a \(d\)-dimensional random vector. Then, for any \(t\in(0,1)\),_

\[d_{c}(\mathbf{Y},\mathbf{N}_{\Sigma})\leq\frac{4}{3}\sup_{g\in\mathcal{I}_{d} }|\mathbb{E}[g_{t}(\mathbf{Y})-g_{t}(\mathbf{N}_{\Sigma})]|+\frac{20d}{\sqrt{2 }}\frac{\sqrt{t}}{1-t},\]

_where \(g_{t}\) is defined by (2.7)._

We recall the Gaussian integration by parts formula (we refer the reader to Exercise 3.1.4 in [14] for the Part \((i)\) of Lemma 2.10 and to Exercise 3.1.5 in [14] for the Part \((ii)\) of Lemma 2.10).

**Lemma 2.10**.: _The following claims hold: \((i)\)\(N\sim\mathscr{N}(\mu,\eta)\) if and only if, for any differentiable function \(g:\mathbb{R}\to\mathbb{R}\) such that \(\mathbb{E}|g^{\prime}(N)|<\infty\), we have \(\mathbb{E}(N-\mu)g(N)=\eta\mathbb{E}g^{\prime}(N)\). \((ii)\) Let \(g\in C^{1}(\mathbb{R}^{d})\) with bounded first partial derivatives. Then_

\[\mathbb{E}[N_{i}g(\mathbf{N}_{\Sigma})]=\sum_{j=1}^{d}\Sigma_{ij}\mathbb{E}[ \partial_{j}g(\mathbf{N}_{\Sigma})],\quad\text{for any $i=1,\ldots,d$.}\]

## 3. Random neural networks

We let \(L\in\mathbb{N}\), we take \(L+2\) positive integers \(n_{0},\ldots,n_{L+1}\in\mathbb{N}\), and we fix a function \(\sigma:\mathbb{R}\to\mathbb{R}\). A fully connected NN of depth \(L\) with input dimension \(n_{0}\), output dimension \(n_{L+1}\), hidden layer widths \(n_{1},\ldots,n_{L}\) and non-linearity \(\sigma\) is a mapping

\[\mathbf{x}:=(x_{1},\ldots,x_{n_{0}})\in\mathbb{R}^{n_{0}}\mapsto\mathbf{z}^{(L +1)}(\mathbf{x})=(z_{1}^{(L+1)}(\mathbf{x}),\ldots,z_{n_{L+1}}^{(L+1)}( \mathbf{x})))\in\mathbb{R}^{n_{L+1}}\]

that is defined by a recursive relation of the form

\[z_{i}^{(1)}(\mathbf{x}) =b_{i}^{(1)}+\sum_{j=1}^{n_{0}}W_{ij}^{(1)}x_{j},\quad i=1,\ldots,n_{1}\] \[z_{i}^{(\ell)}(\mathbf{x}) =b_{i}^{(\ell)}+\sum_{j=1}^{n_{\ell-1}}W_{ij}^{(\ell)}\sigma(z_{ j}^{(\ell-1)}(\mathbf{x})),\quad i=1,\ldots,n_{\ell},\,\ell=2,\ldots,L+1\]

where the parameters \(b_{i}^{(\ell)}\in\mathbb{R}\) and \(W_{ij}^{(\ell)}\in\mathbb{R}\) are called network biases and weights, respectively. The quantities \(L\) and \(n_{0},\ldots,n_{L+1}\) constitute the so-called network architecture. The function \(\sigma\) is usually called activation function. NNs of this kind will be denoted by

\[\text{NN}(L,n_{0},n_{L+1},\mathbf{n}_{L},\sigma,\mathbf{x},\mathbf{b},\mathbf{ W})\,,\]

where \(\mathbf{n}_{L}:=(n_{1},\ldots,n_{L})\), \(\mathbf{b}:=(b_{i}^{(\ell)})\) and \(\mathbf{W}:=(W_{ij}^{(\ell)})\).

We say that the neural network \(\text{NN}(L,n_{0},n_{L+1},\mathbf{n}_{L},\sigma,\mathbf{x},\mathbf{b},\mathbf{ W})\) is a (fully connected and) deep random Gaussian neural network, denoted by

\[\text{GNN}(L,n_{0},n_{L+1},\mathbf{n}_{L},\sigma,\mathbf{x},\mathbf{b},\mathbf{ W})\,,\]
if \(\sigma:\mathbb{R}\to\mathbb{R}\) is measurable and \(b_{i}^{(\ell)},W_{ij}^{(\ell)}\), \(i=1,\ldots,n_{\ell}\), \(j=1,\ldots,n_{\ell-1}\), \(\ell=1,\ldots,L+1\), are independent random variables with

\[b_{i}^{(\ell)}\sim\mathcal{N}(0,C_{b})\quad\text{and}\quad W_{ij}^{(\ell)}\sim \mathcal{N}(0,C_{W}/n_{\ell-1}),\quad\ell=1,\ldots,L+1\]

for positive constants \(C_{b},C_{W}>0\).

NNs of depth \(L=1\) are called shallow NNs. We shall denote shallow NNs (respectively, shallow random Gaussian NNs) by \(\text{NN}(1,n_{0},n_{2},n_{1},\sigma,\mathbf{x},\mathbf{b},\mathbf{W})\) (respectively, by \(\text{GNN}(1,n_{0},n_{2},n_{1},\sigma,\mathbf{x},\mathbf{b},\mathbf{W})\)).

Throughout this paper we will consider also NNs with univariate output, i.e., NNs with \(n_{L+1}=1\).

Consider a deep random Gaussian neural network \(\text{GNN}(L,n_{0},n_{L+1},\mathbf{n}_{L},\sigma,\mathbf{x},\mathbf{b}, \mathbf{W})\). It turns out that the random variables \(z_{i}^{(1)}=z_{i}^{(1)}(\mathbf{x})\), \(i=1,\ldots,n_{1}\), are independent and identically distributed with

\[z_{i}^{(1)}\sim\mathcal{N}\left(0,C_{b}+\frac{C_{W}}{n_{0}}\sum_{j=1}^{n_{0}} x_{j}^{2}\right).\]

For \(\ell=1,\ldots,L\), let \(\mathcal{F}_{\ell}\) be the \(\sigma\)-field generated by the random variables

\[\{b_{i}^{(h)},W_{ij}^{(h)},\quad i=1,\ldots,n_{h},\,j=1,\ldots,n_{h-1},\,h=1, \ldots,\ell\}.\]

By construction, for any fixed \(\ell\in\{2,\ldots,L+1\}\), given \(\mathcal{F}_{\ell-1}\), the random variables \(z_{i}^{(\ell)}=z_{i}^{(\ell)}(\mathbf{x})\), \(i=1,\ldots,n_{\ell}\), are independent and Gaussian (as linear combination of independent Gaussian random variables). A straightforward computation yields

\[\mathbb{E}[z_{i}^{(\ell)}\,|\,\mathcal{F}_{\ell-1}]=0,\quad i=1,\ldots,n_{\ell}\]

and

\[\mathbb{E}[|z_{i}^{(\ell)}|^{2}\,|\,\mathcal{F}_{\ell-1}]=C_{b}+\frac{C_{W}}{ n_{\ell-1}}\sum_{j=1}^{n_{\ell-1}}|\sigma(z_{j}^{(\ell-1)})|^{2},\quad i=1, \ldots,n_{\ell}. \tag{3.1}\]

Setting \(\mathbf{n}_{\ell}=(n_{1},\ldots,n_{\ell})\), \(\ell=1,\ldots,L\), we define the quantities

\[\mathcal{O}_{\mathbf{n}_{\ell}}^{(\ell)}:=\frac{1}{n_{\ell}}\sum_{j=1}^{n_{ \ell}}\sigma(z_{j}^{(\ell)})^{2},\quad\ell=1,\ldots,L\]

and

\[\mathcal{O}^{(\ell)}:=\mathbb{E}\left[\sigma\left(Z\sqrt{C_{b}+C_{W}\mathcal{ O}^{(\ell-1)}}\right)^{2}\right],\quad\ell=1,\ldots,L \tag{3.2}\]

where

\[\mathcal{O}^{(0)}:=\frac{1}{n_{0}}\sum_{j=1}^{n_{0}}x_{j}^{2}\quad\text{and} \quad Z\sim\mathcal{N}(0,1). \tag{3.3}\]

In the literature, the random variable \(\mathcal{O}_{\mathbf{n}_{\ell}}^{(\ell)}\) is often referred to as collective observable at layer \(\ell\).
### Some related literature

Consider the output \(\mathbf{z}^{(L+1)}:=(z_{1}^{(L+1)},\ldots,z_{n_{L+1}}^{(L+1)})\) of a deep random Gaussian neural network \(\mathrm{GNN}(L,n_{0},n_{L+1},\mathbf{n}_{L},\sigma;\mathbf{x};\mathbf{b}, \mathbf{W})\) and let

\[\mathbf{z}:=(z_{1},\ldots,z_{n_{L+1}})\]

be a centered \(n_{L+1}\)-dimensional Gaussian random vector with (invertible) covariance matrix

\[\Sigma_{n_{L+1}}:=(C_{b}+C_{W}\mathcal{O}^{(L)})\mathrm{Id}_{n_{L+1}}, \tag{3.4}\]

where \(\mathrm{Id}_{n_{L+1}}\) is the identity matrix of \(\mathcal{M}_{n_{L+1}\times n_{L+1}}(\mathbb{R})\). It follows from Theorem 1.2 in [9] (which indeed, more generally, establishes a functional weak convergence) that, if \(\sigma\) is continuous and polynomially bounded, then

\[\mathbf{z}^{(L+1)}\to\mathbf{z}\quad\text{in law, as }\min\{n_{1},\ldots,n_{L}\} \to+\infty. \tag{3.5}\]

The following result for shallow random Gaussian NNs is proved in [4], see Theorem 3.2 therein.

**Theorem 3.1**.: _Let \(\mathrm{GNN}(1,n_{0},1,n_{1},\sigma,\mathbf{x},\mathbf{b},\mathbf{W})\) be a shallow random Gaussian NN with univariate output. If_

\[\sigma\in C^{2}(\mathbb{R})\text{ and }\max\{|\sigma(x)|,|\sigma^{\prime}(x)|,| \sigma^{\prime\prime}(x)|\}\leq r_{1}+r_{2}|x|^{\gamma}\text{, }x\in\mathbb{R} \tag{3.6}\]

_for some \(r_{1},r_{2},\gamma\geq 0\), then_

\[d_{s}(z^{(2)},z)\leq c_{s}\sqrt{C_{b}+C_{W}\mathcal{O}^{(0)}+(C_{ b}+C_{W}\mathcal{O}^{(0)})^{2}(2+\sqrt{3(1+2(C_{b}+C_{W}\mathcal{O}^{(0)})+3(C_{ b}+C_{W}\mathcal{O}^{(0)})^{2})})}\\ \times\|r_{1}+r_{2}|Z\sqrt{C_{b}+C_{W}\mathcal{O}^{(0)}}|^{ \gamma}\|_{L^{4}}^{2}\frac{1}{\sqrt{n_{1}}}, \tag{3.7}\]

_where \(s=TV,K,W_{1}\) and_

\[c_{TV}:=\frac{4}{C_{b}+C_{W}\mathcal{O}^{(1)}},\quad c_{K};=\frac{2}{C_{b}+C_ {W}\mathcal{O}^{(1)}},\quad c_{W_{1}}:=\frac{1}{\sqrt{C_{b}+C_{W}\mathcal{O}^ {(1)}}}\sqrt{8/\pi}.\]

In Section 4, we will give bounds on the quantities \(d_{s}(z^{(2)},z)\), \(s=TV,K,W_{1}\), of order \(1/\sqrt{n_{1}}\), as \(n_{1}\to\infty\), under a minimal assumption on the activation function (note that Condition (3.6) excludes the important case of the ReLu function, i.e., \(\sigma(x):=x\mathbf{1}\{x\geq 0\}\)), see Theorem 4.1. In Section 6 we will give two general bounds on \(d_{c}(\mathbf{z}^{(L+1)},\mathbf{z})\) and \(d_{W_{1}}(\mathbf{z}^{(L+1)},\mathbf{z})\) for deep random Gaussian NNs, see Theorems 6.1 and 6.3. When specialized to shallow random Gaussian neural networks \(\mathrm{GNN}(1,n_{0},n_{2},n_{1},\sigma,\mathbf{x},\mathbf{b},\mathbf{W})\), they provide computable bounds respectively on \(d_{c}(\mathbf{z}^{(2)},\mathbf{z})\) and \(d_{W_{1}}(\mathbf{z}^{(2)},\mathbf{z})\) of order \(1/\sqrt{n}_{1}\), as \(n_{1}\to\infty\), see Theorem 3.3 in [4] for a related result.

The first result in literature which quantifies the convergence in distribution (3.5) with \(L\geq 2\) is given in [2], where the following theorem has been proved.

**Theorem 3.2**.: _Let \(\mathrm{GNN}(L,n_{0},n_{L+1},\mathbf{n}_{L},\sigma,\mathbf{x},\mathbf{b}, \mathbf{W})\) be a deep random Gaussian NN, and suppose that the activation function \(\sigma\) is Lipschitz continuous. Then_

\[d_{W_{2}}(\mathbf{z}^{(L+1)},\mathbf{z})\leq\sqrt{n_{L+1}}\sum_{i=1}^{L}\frac{ C^{(i+1)}[\mathrm{Lip}(\sigma)\sqrt{C_{W}}]^{L-i}}{\sqrt{n_{i}}},\]

_where, for any \(i=1,\ldots,L\), \(C^{(i+1)}\) are explicitly known positive constants, depending upon \(\sigma\), \(\mathbf{x}\), \(C_{b}\) and \(C_{W}\)._

The next corollary is an immediate consequence of Theorem 3.2, the fact that \(d_{W_{1}}\leq d_{W_{2}}\), Proposition 2.5 and (2.3).
**Corollary 3.3**.: _Let the asssumptions and notation of Theorem 3.2 prevail. Then_

\[d_{W_{1}}(\mathbf{z}^{(L+1)},\mathbf{z})\leq\sqrt{n_{L+1}}\sum_{i=1}^{L}\frac{C^ {(i+1)}[\mathrm{Lip}(\sigma)\sqrt{C_{W}}]^{L-i}}{\sqrt{n_{i}}} \tag{3.8}\]

_and_

\[d_{c}(\mathbf{z}^{(L+1)},\mathbf{z})\leq 2^{\frac{11}{8}}\pi^{-\frac{1}{8}}n_ {L+1}^{\frac{3}{8}}\left(\sum_{i=1}^{L}\frac{C^{(i+1)}[\mathrm{Lip}(\sigma) \sqrt{C_{W}}]^{L-i}}{\sqrt{n_{i}}}\right)^{1/2}. \tag{3.9}\]

Theorems 6.1 and 6.3 will provide, under more general assumptions on \(\sigma\) (see Proposition 5.2\((ii)\)) explicit bounds respectively on \(d_{c}(\mathbf{z}^{(L+1)},\mathbf{z})\) and \(d_{W_{1}}(\mathbf{z}^{(L+1)},\mathbf{z})\) which are of the same order of the bound in (3.8), as \(n_{1},\ldots,n_{L}\to\infty\). In particular, the bound on the convex distance of Theorem 6.1 considerably improves the one in (3.9).

**Remark 3.4**.: Although not strictly related to our results, the pioneering papers [7] and [13] deserve a special mention. In [13] the author considers a random shallow \(NN(1,n_{0},1,n_{1},\sigma,\mathbf{x},\mathbf{0},\mathbf{W})\) with univariate output, \(b_{i}^{(1)}:=0\), for all \(i=1,\ldots,n_{1}\), \(b_{1}^{(2)}:=0\), \(W_{ij}^{(1)}\), \(i=1,\ldots,n_{1}\), \(j=1,\ldots,n_{0}\), independent with law \(\mathcal{N}(0,1)\) and \(W_{1j}^{(2)}\), \(j=1,\ldots,n_{1}\), independent, identically distributed with law \(\mathbb{P}(W_{1j}^{(2)}=\pm 1/\sqrt{n_{1}})=1/2\) and independent of the random variables \(W_{ij}^{(1)}\). It is proved in [13] that there exists a Gaussian process \(G\) on \(\mathbb{S}^{n_{0}-1}\) (the unit sphere in \(\mathbb{R}^{n_{0}}\)) such that the process \(\{z^{(2)}(\mathbf{x})\}_{\mathbf{x}\in\mathbb{S}^{n_{0}-1}}\) converges in distribution to \(G\), as \(n_{1}\to\infty\). Quantitative versions of this result (for various Wasserstein metrics and some specific choices of \(\sigma\)) are provided in [7].

## 4. Normal approximation of shallow random Gaussian NNs with univariate output

The following theorem holds.

**Theorem 4.1**.: _Let \(\mathrm{GNN}(1,n_{0},1,n_{1},\sigma,\mathbf{x},\mathbf{b},\mathbf{W})\) be a shallow random Gaussian NN with univariate output, and assume that the activation function \(\sigma\) is such that_

\[0<\mathbb{V}\mathrm{ar}(\sigma(Z\sqrt{C_{b}+C_{W}\mathcal{O}^{(0)}})^{2})<\infty. \tag{4.1}\]

_Then:_

\((i)\)__

\[d_{K}(z^{(2)},z)\leq\frac{C_{W}\sqrt{\mathbb{V}\mathrm{ar}(\sigma(Z\sqrt{C_{b }+C_{W}\mathcal{O}^{(0)}})^{2})}}{C_{b}+C_{W}\mathbb{E}\sigma(Z\sqrt{C_{b}+C_{ W}\mathcal{O}^{(0)}})^{2}}\frac{1}{\sqrt{n_{1}}}.\]

\((ii)\)__

\[d_{TV}(z^{(2)},z)\leq 2\frac{C_{W}\sqrt{\mathbb{V}\mathrm{ar}(\sigma(Z\sqrt{C_{b }+C_{W}\mathcal{O}^{(0)}})^{2})}}{C_{b}+C_{W}\mathbb{E}\sigma(Z\sqrt{C_{b}+C_{ W}\mathcal{O}^{(0)}})^{2}}\frac{1}{\sqrt{n_{1}}}.\]

\((iii)\)__

\[d_{W_{1}}(z^{(2)},z)\leq\sqrt{2/\pi}\frac{C_{W}\sqrt{\mathbb{V}\mathrm{ar}( \sigma(Z\sqrt{C_{b}+C_{W}\mathcal{O}^{(0)}})^{2})}}{\sqrt{C_{b}+C_{W}\mathbb{ E}\sigma(Z\sqrt{C_{b}+C_{W}\mathcal{O}^{(0)}})^{2}}}\frac{1}{\sqrt{n_{1}}}.\]

_Note that the bound on the Kolmogorov distance is better than the one which can be obtained using the relation \(d_{K}\leq d_{TV}\)._
**Remark 4.2**.: Remarkably, Theorem 3.3 in [8] shows that if \(\operatorname{GNN}(1,n_{0},1,n_{1},\sigma,\mathbf{x},\mathbf{b},\mathbf{W})\) is a shallow random Gaussian NN with univariate output, and the activation function \(\sigma\) is polynomially bounded to order \(r\geq 1\) (see Definition 2.1 in [8]), then there exist two constants \(C,C_{0}>0\) such that

\[\frac{C_{0}}{n_{1}}\leq\max\{d_{W_{1}}(z^{(2)},z),d_{TV}(z^{(2)},z)\}\leq\frac {C}{n_{1}}.\]

Although this inequality shows the optimality of the rate \(1/n_{1}\), since the constants are not provided in closed form, it can not be directly used for the purpose of output localization (see Section 7). Moreover, the assumption (4.1) on \(\sigma\) does not require any regularity of the activation function.

Proof.: We prove the three bounds \((i)\), \((ii)\), and \((iii)\) separately, by the Stein method.

_Proof of Part \((i)\)._ Set

\[\nu:=\sqrt{C_{b}+C_{W}\mathcal{O}^{(1)}}, \tag{4.2}\]

and consider the Stein equation (2.4) with

\[g(w):=\mathbf{1}_{(-\infty,y]}(\nu w)\,.\]

Let \(f_{g}\) be the unique solution of the Stein equation (see Lemma 2.6\((i)\)). Then, for any \(y\in\mathbb{R}\),

\[\mathbf{1}\{z^{(2)}\leq y\}-\mathbb{P}(z\leq y)=f_{g}^{\prime}(z^{(2)}/\nu)-(z ^{(2)}/\nu)f_{g}(z^{(2)}/\nu).\]

Taking the expectation, we have

\[\mathbb{P}(z^{(2)}\leq y)-\mathbb{P}(z\leq y)=\mathbb{E}[f_{g}^{\prime}(z^{(2) }/\nu)-(z^{(2)}/\nu)f_{y/\nu}(z^{(2)}/\nu)].\]

By Lemma 2.10\((i)\) we have

\[\begin{split}\mathbb{E}[(z^{(2)}/\nu)f_{g}(z^{(2)}/\nu)\,|\, \mathcal{F}_{1}]&=\nu^{-2}(C_{b}+C_{W}\mathcal{O}_{n_{1}}^{(1)}) \mathbb{E}[f_{g}^{\prime}(z^{(2)}/\nu)\,|\,\mathcal{F}_{1}]\\ &=\mathbb{E}[\nu^{-2}(C_{b}+C_{W}\mathcal{O}_{n_{1}}^{(1)})f_{g}^ {\prime}(z^{(2)}/\nu)\,|\,\mathcal{F}_{1}],\end{split} \tag{4.3}\]

where the latter equality follows by the \(\mathcal{F}_{1}\)-measurability of \(\mathcal{O}_{n_{1}}^{(1)}\). Then

\[\mathbb{P}(z^{(2)}\leq y)-\mathbb{P}(z\leq y)=\mathbb{E}[f_{g}^{\prime}(z^{(2 )}/\nu)(1-\nu^{-2}(C_{b}+C_{W}\mathcal{O}_{n_{1}}^{(1)}))],\quad y\in\mathbb{ R}.\]

Setting

\[\varphi(n_{1}):=\nu^{-2}C_{W}\sqrt{\mathbb{V}\mathrm{ar}(\mathcal{O}_{n_{1}}^ {(1)})}=\nu^{-2}C_{W}\sqrt{\mathbb{V}\mathrm{ar}(\sigma(z_{1}^{(1)})^{2})}/ \sqrt{n_{1}}, \tag{4.4}\]

we have

\[\frac{\mathbb{P}(z^{(2)}\leq y)-\mathbb{P}(z\leq y)}{\varphi(n_{1})}=\mathbb{ E}\left[f_{y/\nu_{1}}^{\prime}(z^{(2)}/\nu)V_{n_{1}}\right], \tag{4.5}\]

where

\[V_{n_{1}}:=\frac{1-\nu^{-2}(C_{b}+C_{W}\mathcal{O}_{n_{1}}^{(1)}))}{\varphi(n _{1})}=-\frac{\mathcal{O}_{n_{1}}^{(1)}-\mathcal{O}^{(1)}}{\sqrt{\mathbb{V} \mathrm{ar}(\mathcal{O}_{n_{1}}^{(1)})}}=-\frac{\sum_{j=1}^{n_{1}}\sigma(z_{j }^{(1)})^{2}-n_{1}\mathbb{E}\sigma(z_{1}^{(1)})^{2}}{\sqrt{n_{1}}\sqrt{ \mathbb{V}\mathrm{ar}(\sigma(z_{1}^{(1)})^{2})}}\]

(recall that \(\nu\) is defined in (4.2)). Taking the modulus in (4.5) and then using that \(\|f_{g}^{\prime}\|_{\infty}\leq 1\) uniformly in \(y\in\mathbb{R}\) (see Lemma 2.6\((i)\)) and that \(\mathbb{E}V_{n_{1}}^{2}=1\), we have

\[d_{K}(z^{(2)},z)\leq\varphi(n_{1})\mathbb{E}[|V_{n_{1}}|]\leq\varphi(n_{1}),\]

which, combined with (4.4), proves the statement.

_Proof of Part \((ii)\)._ Consider the Stein equation (2.4) with \(g(w):=\mathbf{1}_{B}(\nu w)\), where \(B\subseteq\mathbb{R}^{d}\) is a
Borel set, and \(\nu\) is defined at the beginning of the proof of Part \((i)\). Let \(f_{g}\) be the unique solution of the Stein equation (see Lemma 2.6\((ii)\)). Then

\[\mathbf{1}_{B}(z^{(2)})-\mathbb{E}\mathbf{1}_{B}(z)=f_{g}^{\prime}(z^{(2)}/\nu) -(z^{(2)}/\nu)f_{g}(z^{(2)}/\nu).\]

Taking the expectation and arguing as in (4.3), we have

\[\mathbb{P}(z^{(2)}\in B)-\mathbb{P}(z\in B)=\mathbb{E}[f_{g}^{\prime}(z^{(2)}/ \nu)(1-\nu^{-2}(C_{b}+C_{W}\mathcal{O}_{n_{1}}^{(1)}))].\]

Along similar computations as for (4.5), we have

\[\frac{\mathbb{P}(z^{(2)}\in B)-\mathbb{P}(z\in B)}{\varphi(n_{1})}=\mathbb{E} \left[f_{g}^{\prime}(z^{(2)}/\nu)V_{n_{1}}\right].\]

Taking the modulus on this relation and then using that \(\|f_{g}^{\prime}\|_{\infty}\leq 2\) (see Lemma 2.6\((ii)\)) and that \(\mathbb{E}V_{n_{1}}^{2}=1\), we have

\[d_{TV}(z^{(2)},z)\leq 2\varphi(n_{1})\mathbb{E}[|V_{n_{1}}|]\leq 2\varphi(n_{ 1}),\]

which, combined with (4.4), proves the statement.

_Proof of Part \((iii)\)._ Consider the Stein equation (2.4) with \(g(y):=h(\nu y)\), where \(h:\mathbb{R}\to\mathbb{R}\) is Lipschitz continuous with \(\mathrm{Lip}(h)\leq 1\), and \(\nu_{1}\) is defined at the beginning of the proof of Part \((i)\). Let \(f_{g}\) be the unique solution of the Stein equation (see Lemma 2.6\((iii)\)). Then

\[h(z^{(2)})-\mathbb{E}h(z)=f_{g}^{\prime}(z^{(2)}/\nu)-(z^{(2)}/\nu)f_{g}(z^{( 2)}/\nu).\]

Taking the expectation and arguing as in (4.3), we have

\[\mathbb{E}h(z^{(2)})-\mathbb{E}h(z)=\mathbb{E}[f_{g}^{\prime}(z^{(2)}/\nu)(1- \nu^{-2}(C_{b}+C_{W}\mathcal{O}_{n_{1}}^{(1)}))].\]

Along similar computations as for (4.5), we have

\[\frac{\mathbb{E}h(z^{(2)})-\mathbb{E}h(z)}{\varphi(n_{1})}=\mathbb{E}\left[f_{ g}^{\prime}(z^{(2)}/\nu)V_{n_{1}}\right].\]

Taking the modulus on this relation and then using that \(\|f_{g}^{\prime}\|_{\infty}\leq\nu\sqrt{2/\pi}\) (see Lemma 2.6\((iii)\)) and that \(\mathbb{E}V_{n_{1}}^{2}=1\), we have

\[d_{W_{1}}(z^{(2)},z)\leq\nu\sqrt{2/\pi}\varphi(n_{1})\mathbb{E}[|V_{n_{1}}|] \leq\nu\sqrt{2/\pi}\varphi(n_{1}),\]

which, combined with (4.4), proves the statement.

\(\square\)

Note that both Theorem 3.1 and Theorem 4.1 provide bounds on \(d_{s}(z^{(2)},z)\), \(s=TV,K,W_{1}\), with a common rate \(1/\sqrt{n_{1}}\), but different constants. In Table 1 we compare those constants in a special case. We observe that the constants given by Theorem 4.1 are more effective than those in [4]. We also note that Condition (4.1) is satisfied by the ReLu activation function, while the assumptions of Theorem 3.1 do not hold for the ReLu.

\begin{table}
\begin{tabular}{c|c c c} \hline  & \(d_{TV}\left(z^{(2)},z\right)\) & \(d_{K}\left(z^{(2)},z\right)\) & \(d_{W_{1}}\left(z^{(2)},z\right)\) \\ \hline Thm. 3.1 & 5.05 & 2.52 & 2.01 \\ Thm. 4.1 & 1.68 & 0.84 & 0.67 \\ \hline \end{tabular}
\end{table}
Table 1. Values of the constants given in Theorems 3.1 and 4.1. Here, \(\sigma(x)=x^{3}\), \(\gamma=3\), \(r_{2}=1\), \(r_{1}=6\), \(L=1\), \(C_{b}=C_{W}=1\) and \(x=1\).
## 5. A key estimate for the collective observables

The next theorem provides an estimate for the \(L^{2}\)-norm of the random variable \(\mathcal{O}_{\mathbf{n}_{\ell}}^{(\ell)}-\mathcal{O}^{(\ell)}\). In Section 6, such estimate will play a crucial role in the proofs of the results on the Normal approximation of the output of a deep random Gaussian NN, both in the convex and in the \(1\)-Wasserstein distances (see Theorems 6.1 and 6.3).

Hereon, we denote by \(\|Y\|_{L^{2}}:=(\mathbb{E}[|Y|^{2}])^{1/2}\) the \(L^{2}\)-norm of a real-valued random variable \(Y\).

**Theorem 5.1**.: _Let \(\operatorname{GNN}(L,n_{0},n_{L+1},\mathbf{n}_{L},\sigma,\mathbf{x},\mathbf{b },\mathbf{W})\) be a deep random Gaussian NN. Suppose that the activation function \(x\mapsto\sigma(x)\) is such that: \((i)\) For any \(a_{1},a_{2}\geq 0\) and \(C_{b},C_{W}>0\), there exists a polynomial_

\[P(x):=\sum_{k=0}^{m}d_{k}x^{k},\]

_with non-negative coefficients \(d_{k}=d_{k}(\sigma(\cdot),C_{b},C_{W})\geq 0\) dependent only on \(\sigma(\cdot),C_{b},C_{W}\) and degree \(m\geq 0\) independent of \(\sigma(\cdot),a_{1},a_{2},C_{b},C_{W}\), such that_

\[|\sigma(x\sqrt{C_{b}+C_{W}a_{2}})^{2}-\sigma(x\sqrt{C_{b}+C_{W}a_{1}})^{2}| \leq P(|x|)|a_{2}-a_{1}|,\quad\text{for all }x\in\mathbb{R}. \tag{5.1}\]

\((ii)\) _For any \(\kappa\in\mathbb{R}\), \(\mathbb{E}\sigma(\kappa Z)^{4}<\infty\)._

_Then, for any \(\ell=1,\ldots,L\), we have_

\[\|\mathcal{O}_{\mathbf{n}_{\ell},\sigma^{2}}^{(\ell)}-\mathcal{O}_{\sigma^{2 }}^{(\ell)}\|_{2}\leq\sum_{k=1}^{\ell}(4\sqrt{2}\|P(|Z|)\|_{2})^{\ell-k}\frac{ c_{k}}{\sqrt{n_{k}}},\]

_where_

\[c_{\ell}=c_{\ell}(n_{0},\sigma,\mathbf{x},C_{b},C_{W}):=\sqrt{2\mathbb{E} \left[\sigma\left(Z\sqrt{C_{b}+C_{W}\mathcal{O}^{(\ell-1)}}\right)^{4}\right] }<\infty,\quad\ell=1,\ldots,L. \tag{5.2}\]

The proof of the theorem is given later on in this section. We proceed stating a proposition and a remark, which clarify the generality of our assumptions on the activation function \(\sigma\).

**Proposition 5.2**.: _The following statements hold: \((i)\) If \(\sigma\) is the perceptron function, i.e., \(\sigma(x):=\mathbf{1}\{x\geq 0\}\), \(x\in\mathbb{R}\), then it satisfies Conditions \((i)\) and \((ii)\) of Theorem 5.1. \((ii)\) If \(\sigma\) is Lipschitz continuous, then it satisfies Conditions \((i)\) and \((ii)\) of Theorem 5.1. In particular, Condition \((i)\) holds with_

\[P(x):=\frac{2|\sigma(0)|C_{W}\mathrm{Lip}(\sigma)}{2\sqrt{C_{b}}}x+C_{W} \mathrm{Lip}(\sigma)^{2}x^{2}. \tag{5.3}\]

\((iii)\) _If \(\sigma\) is such that \(\sigma(\cdot)^{2}\) is Lipschitz continuous then it satisfies Conditions \((i)\) and \((ii)\) of Theorem 5.1. In particular, Condition \((i)\) holds with_

\[P(x)=\frac{\mathrm{Lip}(\sigma^{2})C_{W}}{2\sqrt{C_{b}}}x. \tag{5.4}\]

\((iv)\) _If \(\sigma\in C^{1}(\mathbb{R})\) and \(\max\{|\sigma(x)|,|\sigma^{\prime}(x)|\}\leq r_{1}+r_{2}|x|^{\gamma}\), \(x\in\mathbb{R}\), for some \(r_{1},r_{2},\gamma\geq 0\), then \(\sigma\) satisfies Conditions \((i)\) and \((ii)\) of Theorem 5.1. In particular, Condition \((i)\) holds with_

\[P(x)=\frac{C_{W}}{\sqrt{C_{b}}}x(r_{1}+r_{2}|x|^{\gamma})\]
The proof of the proposition is given later on in this section.

**Remark 5.3**.: As a consequence of Proposition 5.2, we have that the most common activation functions satisfy the assumptions of Theorem 5.1. Indeed, one can easily prove that the ReLu function \(\sigma(x):=x\mathbf{1}\{x\geq 0\}\), the sigmoid function \(\sigma(x):=(1+\mathrm{e}^{-x})^{-1}\), the hyperbolic tangent function \(\sigma(x):=(\mathrm{e}^{2x}-1)/(\mathrm{e}^{2x}+1)\), the \(\sin\) function \(\sigma(x):=\sin(x)\), the softplus function \(\sigma(x):=\log(1+\mathrm{e}^{x})\) and the SWISH function \(\sigma(x):=x/(1+\mathrm{e}^{-x})\) are Lipschitz continuous. We emphasize that the conditions on the activation function of Theorem 5.1 are more general than the one required in [2], where \(\sigma(\cdot)\) is assumed Lipschitz continuous (see Theorem 3.2 and Proposition 5.2\((ii)\)). We also emphasize that the conditions on the activation function of Theorem 5.1 are satisfied by the perceptron function which is non-continuous and therefore non-Lipschitz (see Proposition 5.2\((i)\)). Another non-Lipschitz function which satisfies the conditions of Theorem 5.1 is e.g. \(\sigma(x):=\sqrt{x}\mathbf{1}\{x\geq 0\}\). Indeed, \(\sigma^{2}\) is the ReLu function and therefore Lipschitz continuous (see Proposition 5.2\((iii)\)).

Proof of Theorem 5.1.: We consider separately the cases of the first hidden layer and that of the following ones.

_Case \(\ell=1\)._

Since the random variables \(z_{i}^{(1)}\), \(i=1,\ldots,n_{1}\), are independent and identically distributed with law \(\mathcal{N}(0,C_{b}+C_{W}\mathcal{O}^{(0)})\), we have

\[\|\mathcal{O}^{(1)}_{n_{1}}-\mathcal{O}^{(1)}\|_{L^{2}} =\sqrt{\mathbb{E}\left(\frac{1}{n_{1}}\sum_{j=1}^{n_{1}}\sigma(z_{ j}^{(1)})^{2}-\mathbb{E}\left[\sigma\left(Z\sqrt{C_{b}+C_{W}\mathcal{O}^{(0)}} \right)^{2}\right]\right)^{2}}\] \[=\sqrt{\mathbb{E}\left(\frac{1}{n_{1}}\sum_{j=1}^{n_{1}}(\sigma( z_{j}^{(1)})^{2}-\mathbb{E}\sigma(z_{1}^{(1)})^{2})\right)^{2}}\] \[=\frac{1}{\sqrt{n_{1}}}\sqrt{\mathbb{V}\mathrm{ar}(\sigma(z_{1}^ {(1)})^{2})}\] \[\leq\frac{1}{\sqrt{n_{1}}}\sqrt{\mathbb{E}\left[\sigma\left(Z \sqrt{C_{b}+C_{W}\mathcal{O}^{(0)}}\right)^{4}\right]} \tag{5.6}\] \[\leq\frac{c_{1}}{\sqrt{n_{1}}}. \tag{5.5}\]

Note that this latter term is finite due to the assumption \((ii)\).

_Case \(\ell=2,\ldots,L\)._

Take \(\ell\in\{2,\ldots,L\}\). We have already noticed that, given \(\mathcal{F}_{\ell-1}\), the random variables \(\{z_{i}^{(\ell)}\}_{i=1,\ldots,n_{\ell}}\) are independent with Gaussian law with mean zero and variance

\[C_{b}+C_{W}\mathcal{O}^{(\ell-1)}_{\mathbf{n}_{\ell-1}}.\]

Therefore, letting \(Z_{\ell-1}\) denote a standard Gaussian random variable, independent of \(\mathcal{F}_{\ell-1}\), we have

\[z_{i}^{(\ell)}\stackrel{{ d}}{{=}}Z_{\ell-1}\sqrt{C_{b}+C_{W} \mathcal{O}^{(\ell-1)}_{\mathbf{n}_{\ell-1}}},\quad i=1,\ldots,n_{\ell}\]

where the symbol \(\stackrel{{ d}}{{=}}\) denotes the equality in law (this relation immediately follows computing e.g. the characteristic function of both random variables). Therefore, letting \(p(\cdot)\) denote the standard
Gaussian density, we have

\[\mathbb{E}[\sigma(z_{i}^{(\ell)})^{r}\,|\,\mathcal{F}_{\ell-1}]\overset{d}{=}\int_ {\mathbb{R}}\sigma\left(z\sqrt{C_{b}+C_{W}\mathcal{O}_{\mathbf{n}_{\ell-1}}^{( \ell-1)}}\right)^{r}p(z)\mathrm{d}z,\quad r\in\{2,4\},\,i=1,\ldots,n_{\ell} \tag{5.7}\]

and

\[\mathbb{E}\mathcal{O}_{\mathbf{n}_{\ell}}^{(\ell)}=\mathbb{E}\left[\sigma \left(Z_{\ell-1}\sqrt{C_{b}+C_{W}\mathcal{O}_{\mathbf{n}_{\ell-1}}^{(\ell-1)}} \right)^{2}\right].\]

By assumption \((i)\) and the fact that \(Z_{\ell-1}\) is independent of \(\mathcal{F}_{\ell-1}\), we have

\[|\mathbb{E}\mathcal{O}_{\mathbf{n}_{\ell}}^{(\ell)}-\mathcal{O}^{ (\ell)}| =\left|\mathbb{E}\left[\sigma\left(Z_{\ell-1}\sqrt{C_{b}+C_{W} \mathcal{O}_{\mathbf{n}_{\ell-1}}^{(\ell-1)}}\right)^{2}\right]-\mathbb{E} \left[\sigma\left(Z_{\ell-1}\sqrt{C_{b}+C_{W}\mathcal{O}^{(\ell-1)}}\right)^{ 2}\right]\Big{|}\] \[\leq\mathbb{E}P(|Z_{\ell-1}|)|\mathcal{O}_{\mathbf{n}_{\ell-1}}^ {(\ell-1)}-\mathcal{O}^{(\ell-1)}|\] \[\leq\mathbb{E}P(|Z|)\|\mathcal{O}_{\mathbf{n}_{\ell-1}}^{(\ell-1 )}-\mathcal{O}^{(\ell-1)}\|_{L^{2}}.\]

Therefore

\[\|\mathcal{O}_{\mathbf{n}_{\ell}}^{(\ell)}-\mathcal{O}^{(\ell)} \|_{L^{2}} \leq\|\mathcal{O}_{\mathbf{n}_{\ell}}^{(\ell)}-\mathbb{E}\mathcal{ O}_{\mathbf{n}_{\ell}}^{(\ell)}\|_{L^{2}}+|\mathbb{E}\mathcal{O}_{\mathbf{n}_{ \ell}}^{(\ell)}-\mathcal{O}^{(\ell)}| \tag{5.8}\] \[=\sqrt{\mathbb{V}\mathrm{ar}(\mathcal{O}_{\mathbf{n}_{\ell}}^{( \ell)})}+|\mathbb{E}\mathcal{O}_{\mathbf{n}_{\ell}}^{(\ell)}-\mathcal{O}^{( \ell)}|\] \[\leq\sqrt{\mathbb{V}\mathrm{ar}(\mathcal{O}_{\mathbf{n}_{\ell}}^{( \ell)})}+\mathbb{E}P(|Z|)\|\mathcal{O}_{\mathbf{n}_{\ell-1}}^{(\ell-1)}- \mathcal{O}^{(\ell-1)}\|_{L^{2}}.\]

Note that

\[\mathbb{V}\mathrm{ar}(\mathcal{O}_{\mathbf{n}_{\ell}}^{(\ell)})= \frac{1}{n_{\ell}^{2}}\left(\mathbb{E}\left(\sum_{j=1}^{n_{\ell}}\sigma(z_{j}^ {(\ell)})^{2}\right)^{2}-n_{\ell}^{2}(\mathbb{E}\sigma(z_{1}^{(\ell)})^{2})^{2 }\right)\] \[=\frac{1}{n_{\ell}^{2}}\left(n_{\ell}\mathbb{E}\sigma(z_{1}^{( \ell)})^{4}+n_{\ell}(n_{\ell}-1)\mathbb{E}\sigma(z_{1}^{(\ell)})^{2}\sigma(z_ {2}^{(\ell)})^{2}-n_{\ell}^{2}(\mathbb{E}\sigma(z_{1}^{(\ell)})^{2})^{2}\right)\] \[=\frac{1}{n_{\ell}^{2}}\left(n_{\ell}\mathbb{E}\sigma(z_{1}^{( \ell)})^{4}-n_{\ell}\mathbb{E}\sigma(z_{1}^{(\ell)})^{2}\sigma(z_{2}^{(\ell)} )^{2}+n_{\ell}^{2}\mathbb{C}\mathrm{ov}(\sigma(z_{1}^{(\ell)})^{2},\sigma(z_ {2}^{(\ell)})^{2})\right)\] \[=\frac{1}{n_{\ell}^{2}}\left(n_{\ell}\mathbb{V}\mathrm{ar}( \sigma(z_{1}^{(\ell)})^{2})+(n_{\ell}^{2}-n_{\ell})\mathbb{C}\mathrm{ov}( \sigma(z_{1}^{(\ell)})^{2},\sigma(z_{2}^{(\ell)})^{2})\right) \tag{5.9}\] \[=\frac{1}{n_{\ell}}\mathbb{V}\mathrm{ar}(\sigma(z_{1}^{(\ell)})^{ 2})+\left(1-\frac{1}{n_{\ell}}\right)\mathbb{C}\mathrm{ov}(\sigma(z_{1}^{( \ell)})^{2},\sigma(z_{2}^{(\ell)})^{2}).\]

By (5.7) we have

\[\mathbb{E}[\sigma(z_{1}^{(\ell)})^{4}]=\mathbb{E}\sigma\left(Z_{\ell-1}\sqrt{ C_{b}+C_{W}\mathcal{O}_{\mathbf{n}_{\ell-1}}^{(\ell-1)}}\right)^{4}.\]

By assumption \((i)\), we have

\[\sigma\left(Z_{\ell-1}\sqrt{C_{b}+C_{W}\mathcal{O}_{\mathbf{n}_{\ell-1}}^{( \ell-1)}}\right)^{2}\leq P(|Z_{\ell-1}|)|\mathcal{O}_{\mathbf{n}_{\ell-1}}^{( \ell-1)}-\mathcal{O}^{(\ell-1)}|+\sigma\left(Z_{\ell-1}\sqrt{C_{b}+C_{W} \mathcal{O}^{(\ell-1)}}\right)^{2},\quad\mathbb{P}\text{-a.s.}\]
and so (using that \(Z_{\ell-1}\) is independent of \(\mathcal{F}_{\ell-1}\) and the inequality \((a+b)^{2}\leq 2a^{2}+2b^{2}\), \(a,b\in\mathbb{R}\))

\[\mathbb{V}\mathrm{ar}(\sigma(z_{1}^{(\ell)})^{2}) \leq\mathbb{E}[\sigma(z_{1}^{(\ell)})^{4}]\] \[\leq 2\mathbb{E}P(|Z|)^{2}\|\mathcal{O}_{\mathbf{n}_{\ell-1}}^{( \ell-1)}-\mathcal{O}^{(\ell-1)}\|_{2}^{2}+2\mathbb{E}\sigma\left(Z\sqrt{C_{b}+ C_{W}\mathcal{O}^{(\ell-1)}}\right)^{4} \tag{5.10}\] \[=A\|\mathcal{O}_{\mathbf{n}_{\ell-1}}^{(\ell-1)}-\mathcal{O}^{( \ell-1)}\|_{L^{2}}^{2}+c_{\ell}^{2},\]

where \(A:=2\mathbb{E}P(|Z|)^{2}<\infty\). Note that the quantities \(\mathcal{O}^{(\ell)}\), \(\ell=2,\ldots,L,\) are all finite due to the assumption \((ii)\). Then, again by assumption \((ii)\), we have

\[\mathbb{E}\sigma\left(Z\sqrt{C_{b}+C_{W}\mathcal{O}^{(\ell-1)}}\right)^{4}< \infty,\quad\text{for any }\ell=2,\ldots,L\]

and therefore \(c_{\ell}<\infty\), for any \(\ell=2,\ldots,L\). By the conditional independence of the random variables \(z_{1}^{(\ell)}\) and \(z_{2}^{(\ell)}\), given \(\mathcal{F}_{\ell-1}\), we have

\[\mathbb{C}\mathrm{ov}(\sigma(z_{1}^{(\ell)})^{2},\sigma(z_{2}^{( \ell)})^{2})=\mathbb{C}\mathrm{ov}(\mathbb{E}[\sigma(z_{1}^{(\ell)})^{2}\,| \,\mathcal{F}_{\ell-1}],\mathbb{E}[\sigma(z_{2}^{(\ell)})^{2}\,|\,\mathcal{F}_ {\ell-1}])\] \[=\mathbb{E}[(\mathbb{E}[\sigma(z_{1}^{(\ell)})^{2}\,|\,\mathcal{F} _{\ell-1}]-\mathbb{E}\sigma(z_{1}^{(\ell)})^{2})(\mathbb{E}[\sigma(z_{2}^{( \ell)})^{2}\,|\,\mathcal{F}_{\ell-1}]-\mathbb{E}\sigma(z_{2}^{(\ell)})^{2})],\]

and so by the Cauchy-Schwarz inequality and (5.7) we have

\[|\mathbb{C}\mathrm{ov}(\sigma(z_{1}^{(\ell)})^{2},\sigma(z_{2}^{( \ell)})^{2})|\leq\mathbb{E}[(\mathbb{E}[\sigma(z_{1}^{(\ell)})^{2}\,|\, \mathcal{F}_{\ell-1}]-\mathbb{E}\sigma(z_{1}^{(\ell)})^{2})^{2}]. \tag{5.11}\]

Letting \(\mathbb{P}_{X}\) denote the law of a random variable \(X\) and using again (5.7), we have that the random variable \(\mathbb{E}[\sigma(z_{1}^{(\ell)})^{2}\,|\,\mathcal{F}_{\ell-1}]-\mathbb{E} \sigma(z_{1}^{(\ell)})^{2}\) has the same law as the random variable

\[\int_{\mathbb{R}}\left(\sigma\left(z\sqrt{C_{b}+C_{W}\mathcal{O}_ {\mathbf{n}_{\ell-1}}^{(\ell-1)}}\right)^{2}-\int_{[0,\infty)}\sigma\left(z \sqrt{C_{b}+C_{W}y}\right)^{2}\mathbb{P}_{\mathcal{O}_{\mathbf{n}_{\ell-1}}^{( \ell-1)}}(\mathrm{d}y)\right)p(z)\mathrm{d}z\] \[=\int_{[0,\infty)\times\mathbb{R}}\left(\sigma\left(z\sqrt{C_{b}+ C_{W}\mathcal{O}_{\mathbf{n}_{\ell-1}}^{(\ell-1)}}\right)^{2}-\sigma\left(z \sqrt{C_{b}+C_{W}y}\right)^{2}\right)\mathbb{P}_{\mathcal{O}_{\mathbf{n}_{\ell -1}}^{(\ell-1)}}(\mathrm{d}y)p(z)\mathrm{d}z.\]

Therefore, by (5.11) and Jensen's inequality we have

\[|\mathbb{C}\mathrm{ov}(\sigma(z_{1}^{(\ell)})^{2},\sigma(z_{2}^{ (\ell)})^{2})|\] \[\qquad\leq\mathbb{E}\int_{[0,\infty)\times\mathbb{R}}\left(\sigma \left(z\sqrt{C_{b}+C_{W}\mathcal{O}_{\mathbf{n}_{\ell-1}}^{(\ell-1)}}\right)^{ 2}-\sigma\left(z\sqrt{C_{b}+C_{W}y}\right)^{2}\right)^{2}\mathbb{P}_{\mathcal{ O}_{\mathbf{n}_{\ell-1}}^{(\ell-1)}}(\mathrm{d}y)p(z)\mathrm{d}z\]

By assumption \((i)\) it then follows that

\[|\mathbb{C}\mathrm{ov}(\sigma(z_{1}^{(\ell)})^{2},\sigma(z_{2}^{( \ell)})^{2})|\leq(\mathbb{E}P(|Z|))^{2}\int_{[0,\infty)}\mathbb{E}|\mathcal{ O}_{\mathbf{n}_{\ell-1}}^{(\ell-1)}-y|^{2}\mathbb{P}_{\mathcal{O}_{\mathbf{n}_{ \ell-1}}^{(\ell-1)}}(\mathrm{d}y)\leq A\mathbb{V}\mathrm{ar}\left(\mathcal{O}_ {\mathbf{n}_{\ell-1}}^{(\ell-1)}\right), \tag{5.12}\]

where the latter relation follows by the definition of the constant \(A\). Combining (5.9), (5.10) and (5.12), we have

\[\mathbb{V}\mathrm{ar}(\mathcal{O}_{\mathbf{n}_{\ell}}^{(\ell)})\leq A(\mathbb{ V}\mathrm{ar}(\mathcal{O}_{\mathbf{n}_{\ell-1}}^{(\ell-1)})+\|\mathcal{O}_{ \mathbf{n}_{\ell-1}}^{(\ell-1)}-\mathcal{O}_{\sigma^{2}}^{(\ell-1)}\|_{L^{2}}^ {2})+\frac{c_{\ell}^{2}}{n_{\ell}}.\]
Iterating this inequality we have

\[\mathbb{V}\mathrm{ar}(\mathcal{O}_{\mathbf{n}_{\ell}}^{(\ell)}) \leq A\left(A(\mathbb{V}\mathrm{ar}(\mathcal{O}_{\mathbf{n}_{\ell-2} }^{(\ell-2)})+\|\mathcal{O}_{\mathbf{n}_{\ell-2}}^{(\ell-2)}-\mathcal{O}^{( \ell-2)}\|_{L^{2}}^{2})+\frac{c_{\ell-1}^{2}}{n_{\ell-1}}\right)\] \[\qquad\qquad\qquad\qquad+A\|\mathcal{O}_{\mathbf{n}_{\ell-1}}^{( \ell-1)}-\mathcal{O}^{(\ell-1)}\|_{L^{2}}^{2}+\frac{c_{\ell}^{2}}{n_{\ell}}\] \[=A^{2}\mathbb{V}\mathrm{ar}(\mathcal{O}_{\mathbf{n}_{\ell-2}}^{( \ell-2)})+A^{2}\|\mathcal{O}_{\mathbf{n}_{\ell-2}}^{(\ell-2)}-\mathcal{O}^{( \ell-2)}\|_{L^{2}}^{2}+A\|\mathcal{O}_{\mathbf{n}_{\ell-1}}^{(\ell-1)}- \mathcal{O}^{(\ell-1)}\|_{L^{2}}^{2}\] \[\qquad\qquad\qquad\qquad+A\frac{c_{\ell-1}^{2}}{n_{\ell-1}}+ \frac{c_{\ell}^{2}}{n_{\ell}}\] \[\leq A^{3}\mathbb{V}\mathrm{ar}(\mathcal{O}_{\mathbf{n}_{\ell-3} }^{(\ell-3)})+A^{3}\|\mathcal{O}_{\mathbf{n}_{\ell-3}}^{(\ell-3)}-\mathcal{O}^ {(\ell-3)}\|_{L^{2}}^{2}+A^{2}\|\mathcal{O}_{\mathbf{n}_{\ell-2}}^{(\ell-2)}- \mathcal{O}^{(\ell-2)}\|_{L^{2}}^{2}\] \[\qquad\qquad\qquad+A\|\mathcal{O}_{\mathbf{n}_{\ell-1}}^{(\ell-1 )}-\mathcal{O}^{(\ell-1)}\|_{L^{2}}^{2}+A^{2}\frac{c_{\ell-2}^{2}}{n_{\ell-2}} +A\frac{c_{\ell-1}^{2}}{n_{\ell-1}}+\frac{c_{\ell}^{2}}{n_{\ell}}\] \[\leq A^{\ell-1}\mathbb{V}\mathrm{ar}(\mathcal{O}_{n_{1}}^{(1)})+ \sum_{k=1}^{\ell-1}A^{\ell-k}\|\mathcal{O}_{\mathbf{n}_{k}}^{(k)}-\mathcal{O}^ {(k)}\|_{L^{2}}^{2}+\sum_{k=2}^{\ell}A^{\ell-k}\frac{c_{k}^{2}}{n_{k}}\] \[=2A^{\ell-1}\mathbb{V}\mathrm{ar}(\mathcal{O}_{n_{1}}^{(1)})+ \sum_{k=2}^{\ell-1}A^{\ell-k}\|\mathcal{O}_{\mathbf{n}_{k}}^{(k)}-\mathcal{O}^ {(k)}\|_{L^{2}}^{2}+\sum_{k=2}^{\ell}A^{\ell-k}\frac{c_{k}^{2}}{n_{k}},\]

for any \(\ell=2,\ldots,L\), where the latter equality follows noticing that \(\mathbb{E}\mathcal{O}_{n_{1}}^{(1)}=\mathcal{O}^{(1)}\). Here, we adopt the usual convention \(\sum_{k=k_{1}}^{k_{2}}\cdots=0\) if \(k_{1}>k_{2}\). Note that by (5.5) we have

\[\mathbb{V}\mathrm{ar}(\mathcal{O}_{n_{1}}^{(1)})\leq\frac{1}{n_{1}}\mathbb{E} \sigma\left(Z\sqrt{C_{b}+C_{W}\mathcal{O}^{(0)}}\right)^{4},\]

and so

\[2\mathbb{V}\mathrm{ar}(\mathcal{O}_{n_{1}}^{(1)})\leq\frac{c_{1}^{2}}{n_{1}}.\]

Consequently,

\[\mathbb{V}\mathrm{ar}(\mathcal{O}_{\mathbf{n}_{\ell}}^{(\ell)})\leq\sum_{k=2}^ {\ell-1}A^{\ell-k}\|\mathcal{O}_{\mathbf{n}_{k}}^{(k)}-\mathcal{O}^{(k)}\|_{L^ {2}}^{2}+\sum_{k=1}^{\ell}A^{\ell-k}\,\frac{c_{k}^{2}}{n_{k}}.\]

Combining this inequality with (5.8) and using the elementary relation \(\sqrt{a_{1}+a_{2}}\leq\sqrt{a}_{1}+\sqrt{a}_{2}\), \(a_{1},a_{2}\geq 0\), for any \(\ell=2,\ldots,L\), we have

\[\|\mathcal{O}_{\mathbf{n}_{\ell}}^{(\ell)}-\mathcal{O}^{(\ell)}\| _{L^{2}} \leq\sum_{k=2}^{\ell-1}A^{(\ell-k)/2}\|\mathcal{O}_{\mathbf{n}_{k}}^{(k)}- \mathcal{O}^{(k)}\|_{L^{2}}+\sum_{k=1}^{\ell}A^{(\ell-k)/2}\frac{c_{k}}{\sqrt{n _{k}}}\] \[\qquad\qquad\qquad+\mathbb{E}P(|Z|)\|\mathcal{O}_{\mathbf{n}_{ \ell-1}}^{(\ell-1)}-\mathcal{O}^{(\ell-1)}\|_{L^{2}} \tag{5.13}\] \[\leq\sum_{k=2}^{\ell-1}B^{(\ell-k)/2}\|\mathcal{O}_{\mathbf{n}_{k }}^{(k)}-\mathcal{O}^{(k)}\|_{L^{2}}+\sum_{k=1}^{\ell}B^{(\ell-k)/2}\frac{c_{k}} {\sqrt{n_{k}}},\]

where we used that \(\mathbb{E}P(|Z|)\leq A^{1/2}\), and we set \(B:=4A\). Recalling that \(\sqrt{A}=\sqrt{2}\|P(|Z|)\|_{2}\) and the definition of \(B\), one easily realizes that the claim reads as

\[\|\mathcal{O}_{\mathbf{n}_{2}}^{(\ell)}-\mathcal{O}^{(\ell)}\|_{L^{2}}\leq\sum_ {j=1}^{\ell}(2\sqrt{B})^{\ell-j}\frac{c_{j}}{\sqrt{n_{j}}},\quad\ell=2,\ldots,L. \tag{5.14}\]
Now we use the relation (5.13) to prove (5.14) by induction on \(\ell=2,\ldots,L\). Taking \(\ell=2\) in (5.13) we have

\[\|\mathcal{O}_{\mathbf{n}_{2}}^{(2)}-\mathcal{O}^{(2)}\|_{L^{2}}\leq B^{1/2} \frac{c_{1}}{\sqrt{n_{1}}}+\frac{c_{2}}{\sqrt{n_{2}}}\leq 2B^{1/2}\frac{c_{1}}{ \sqrt{n_{1}}}+\frac{c_{2}}{\sqrt{n_{2}}},\]

i.e., (5.14) with \(\ell=2\). Now, suppose that

\[\|\mathcal{O}_{\mathbf{n}_{k}}^{(k)}-\mathcal{O}^{(k)}(\mathbf{x})\|_{L^{2}} \leq\sum_{j=1}^{k}(2\sqrt{B})^{k-j}\frac{c_{j}}{\sqrt{n_{j}}},\quad\text{for any }k=2,\ldots,\ell-1.\]

Then by (5.13), we have

\[\|\mathcal{O}_{\mathbf{n}_{\ell}}^{(\ell)}-\mathcal{O}^{(\ell)}\| _{L^{2}} \leq\sum_{k=2}^{\ell-1}B^{(\ell-k)/2}\sum_{j=1}^{k}2^{k-j}B^{(k-j )/2}\frac{c_{j}}{\sqrt{n_{j}}}+\sum_{k=1}^{\ell}B^{(\ell-k)/2}\frac{c_{k}}{ \sqrt{n_{k}}}\] \[\leq\sum_{k=2}^{\ell-1}\sum_{j=1}^{k}2^{k-j}B^{(\ell-j)/2}\frac{c _{j}}{\sqrt{n_{j}}}+\sum_{k=1}^{\ell}B^{(\ell-k)/2}\frac{c_{k}}{\sqrt{n_{k}}}\] \[\leq\sum_{j=1}^{\ell-1}\sum_{k=j}^{\ell-1}2^{k-j}B^{(\ell-j)/2} \frac{c_{j}}{\sqrt{n_{j}}}+\sum_{k=1}^{\ell}B^{(\ell-k)/2}\frac{c_{k}}{\sqrt{n _{k}}}\] \[=\sum_{j=1}^{\ell-1}\left(\sum_{k=j}^{\ell-1}2^{k-j}+1\right)B^{( \ell-j)/2}\frac{c_{j}}{\sqrt{n_{j}}}+\frac{c_{\ell}}{\sqrt{n_{\ell}}}\] \[=\sum_{j=1}^{\ell-1}(2\sqrt{B})^{\ell-j}\frac{c_{j}}{\sqrt{n_{j}} }+\frac{c_{\ell}}{\sqrt{n_{\ell}}}=\sum_{j=1}^{\ell}(2\sqrt{B})^{\ell-j}\frac {c_{j}}{\sqrt{n_{j}}},\]

where we used that

\[\sum_{k=j}^{\ell-1}2^{k-j}+1=\sum_{s=0}^{\ell-j-1}2^{s}+1=2^{\ell-j},\quad \text{for any }j=1,\ldots,\ell-1\]

since \(\{2^{s}\}_{s\geq 0}\) is a geometric progression. The proof is completed.

_Proof of Proposition 5.2._

_Proof of \((i)\)._ The claim immediately follows noticing that, due to the positivity of the quantities \(\sqrt{C_{b}+C_{W}a_{2}}\) and \(\sqrt{C_{b}+C_{W}a_{1}}\), we have \(|\sigma(x\sqrt{C_{b}+C_{W}a_{2}})^{2}-\sigma(x\sqrt{C_{b}+C_{W}a_{1}})^{2}|=0\), for any \(x\in\mathbb{R}\).

_Proof of \((ii)\)._ Since \(\sigma\) is Lipschitz continuous, we have

\[|\sigma(x\sqrt{C_{b}+C_{W}a_{2}})^{2}-\sigma(x\sqrt{C_{b}+C_{W}a_ {1}})^{2}|\] \[=|\sigma(x\sqrt{C_{b}+C_{W}a_{2}})-\sigma(x\sqrt{C_{b}+C_{W}a_{1} })||\sigma(x\sqrt{C_{b}+C_{W}a_{2}})+\sigma(x\sqrt{C_{b}+C_{W}a_{1}})|\] \[\leq\text{Lip}(\sigma)|x||\sqrt{C_{b}+C_{W}a_{2}}-\sqrt{C_{b}+C_{ W}a_{1}}|(|\sigma(x\sqrt{C_{b}+C_{W}a_{2}})|+|\sigma(x\sqrt{C_{b}+C_{W}a_{1}})|) \tag{5.15}\] \[\leq\text{Lip}(\sigma)|x||\sqrt{C_{b}+C_{W}a_{2}}-\sqrt{C_{b}+C_{ W}a_{1}}|[2|\sigma(0)|+\text{Lip}(\sigma)|x|(\sqrt{C_{b}+C_{W}a_{2}}+\sqrt{C_{b}+C_{ W}a_{1}})],\]
where the latter inequality follows noticing that (again by the Lipschitz continuity of \(\sigma\)), for any \(x,\kappa\in\mathbb{R}\),

\[|\sigma(\kappa x)|\leq|\sigma(0)|+\text{Lip}(\sigma(\cdot))|\kappa||x|. \tag{5.16}\]

Multiplying and dividing the term in (5.15) by \(\sqrt{C_{b}+C_{W}a_{2}}+\sqrt{C_{b}+C_{W}a_{1}}\), we easily have that

\[|\sigma(x\sqrt{C_{b}+C_{W}a_{2}})^{2}-\sigma(x\sqrt{C_{b}+C_{W}a _{1}})^{2}|\] \[\leq C_{W}\text{Lip}(\sigma)|x|\left(\frac{2|\sigma(0)|}{\sqrt{C _{b}+C_{W}a_{2}}+\sqrt{C_{b}+C_{W}a_{1}}}+\text{Lip}(\sigma)|x|\right)|a_{2}-a _{1}|\] \[\leq P(|x|)|a_{2}-a_{1}|,\]

where \(P(x)\) is defined by (5.3). As far as Condition \((ii)\) of Theorem 5.1 is concerned, we note that by (5.16)

\[\sigma(\kappa Z)^{4}\leq(|\sigma(0)|+\text{Lip}(\sigma)|\kappa||Z|)^{4},\quad \text{almost surely}\]

and so the claim is an immediate consequence of the fact that the absolute moments of \(Z\) are finite.

_Proof of \((iii)\)_. If \(\sigma(\cdot)^{2}\) is Lipschitz continuous, then

\[|\sigma(x\sqrt{C_{b}+C_{W}a_{2}})^{2}-\sigma(x\sqrt{C_{b}+C_{W}a _{1}})^{2}|\] \[\qquad\leq\text{Lip}(\sigma^{2})|x||\sqrt{C_{b}+C_{W}a_{2}}-\sqrt {C_{b}+C_{W}a_{1}}|\] \[\qquad=\text{Lip}(\sigma^{2})|x||\sqrt{C_{b}+C_{W}a_{2}}-\sqrt{C_ {b}+C_{W}a_{1}}|\frac{\sqrt{C_{b}+C_{W}a_{2}}+\sqrt{C_{b}+C_{W}a_{1}}}{\sqrt{C _{b}+C_{W}a_{2}}+\sqrt{C_{b}+C_{W}a_{1}}}\] \[\qquad=\text{Lip}(\sigma^{2})|x||(C_{b}+C_{W}a_{2})-(C_{b}+C_{W}a _{1})|\frac{1}{\sqrt{C_{b}+C_{W}a_{2}}+\sqrt{C_{b}+C_{W}a_{1}}}\] \[\qquad\leq\frac{\text{Lip}(\sigma^{2})C_{W}}{2\sqrt{C_{b}}}|x||a_ {2}-a_{1}|,\]

which shows that Condition \((i)\) of Theorem 5.1 holds with \(P(x)\) given by (5.4). Furthermore, using (5.16) with \(\sigma(\cdot)^{2}\) in place of \(\sigma(\cdot)\), for any \(\kappa\in\mathbb{R}\),

\[\sigma(\kappa Z)^{4}\leq\left(|\sigma(0)|^{2}+\text{Lip}(\sigma(\cdot)^{2})| \kappa||Z|\right)^{2},\quad\text{almost surely}.\]

Therefore, Condition \((ii)\) of Theorem 5.1 is an immediate consequence of this latter relation and the fact that the absolute moments of \(Z\) are finite.

_Proof of \((iv)\)_. Condition \((ii)\) of Theorem 5.1 immediately follows noticing that, for any \(\kappa\in\mathbb{R}\),

\[\mathbb{E}\sigma(\kappa Z)^{4}\leq\mathbb{E}(r_{1}+r_{2}|\kappa|^{\gamma}|Z|^ {\gamma})^{4}<\infty.\]

As far as Condition \((i)\) is concerned, note that by the mean value theorem, for any \(x\in\mathbb{R}\), there exists \(\xi\in\left(\min\{x\sqrt{C_{b}+C_{W}a_{1}},x\sqrt{C_{b}+C_{W}a_{1}}\},\max\{x \sqrt{C_{b}+C_{W}a_{1}},x\sqrt{C_{b}+C_{W}a_{1}}\}\right)\) such that

\[|\sigma(x\sqrt{C_{b}+C_{W}a_{2}})^{2}-\sigma(x\sqrt{C_{b}+C_{W}a _{1}})^{2}| =2|\sigma^{\prime}(\xi)||x||\sqrt{C_{b}+C_{W}a_{2}}-\sqrt{C_{b}+C_ {W}a_{1}}|\] \[=\frac{2C_{W}|\sigma^{\prime}(\xi)|}{\sqrt{C_{b}+C_{W}a_{2}}+ \sqrt{C_{b}+C_{W}a_{1}}}|x||a_{2}-a_{1}|.\]

The claim follows noticing that by assumption \(|\sigma^{\prime}(x)|\leq r_{1}+r_{2}|x|^{\gamma}\), for any \(x\in\mathbb{R}\).
## 6. Normal approximation of deep random Gaussian NNs

### Normal approximation of deep random Gaussian NNs in the convex distance

The following theorem holds.

**Theorem 6.1**.: _Let \(\operatorname{GNN}(L,n_{0},n_{L+1},\mathbf{n}_{L},\sigma;\mathbf{x};\mathbf{b}, \mathbf{W})\) be a deep random Gaussian NN, and let the notation and assumptions of Theorem 5.1 prevail. Then_

\[d_{c}(\mathbf{z}^{(L+1)},\mathbf{z}) \leq C_{1}\left(\sum_{k=1}^{L}[4\sqrt{2}\|P(|Z|)\|_{L^{2}}]^{L-k} \frac{c_{k}}{\sqrt{n_{k}}}\right)\] \[\leq C_{i}\left(\sum_{k=1}^{L}[4\sqrt{2}\|P(|Z|)\|_{L^{2}}]^{L-k} \frac{c_{k}}{\sqrt{n_{k}}}\right),\quad i=2,3\]

_where the constants \(c_{k}\), \(k=1,\ldots,L\), are defined by (5.2),_

\[C_{1}=C_{1}(n_{0},n_{L+1},\mathbf{x},\sigma,C_{b},C_{W}):=C_{W} \left(\frac{80}{(C_{b}+C_{W}\mathcal{O}^{(L+1)})^{3/2}}+\frac{48}{C_{b}+C_{W} \mathcal{O}^{(L+1)}}+20\sqrt{2}\right)n_{L+1}^{59/24},\] \[C_{2}=C_{2}(n_{L+1},C_{b},C_{W}):=C_{W}\left(\frac{80}{C_{b}^{3/2 }}+\frac{48}{C_{b}}+20\sqrt{2}\right)n_{L+1}^{59/24} \tag{6.1}\]

_and_

\[C_{3}=C_{3}(n_{0},n_{L+1},\mathbf{x},\sigma,C_{W}):=C_{W}\left(\frac{80}{(C_{W }\mathcal{O}_{\sigma^{2}}^{(L+1)})^{3/2}}+\frac{48}{C_{W}\mathcal{O}_{\sigma^ {2}}^{(L+1)}}+20\sqrt{2}\right)n_{L+1}^{59/24}.\]

**Remark 6.2**.: Let \(\operatorname{GNN}(L,n_{0},n_{L+1},\mathbf{n}_{L},\sigma;\mathbf{x};\mathbf{b },\mathbf{W})\) be a deep random Gaussian NN. Theorem 3.5 in [8] shows that if

\[c_{2}n\leq n_{1},\ldots,n_{L}\leq c_{1}n,\quad\text{for some constants $c_{1}\geq c_{2}>0$ and some $n\geq 1$} \tag{6.2}\]

and \(\sigma\) is polynomially bounded to order \(r\geq 1\), then there exists a constant \(C_{0}\) such that

\[d_{c}(\mathbf{z}^{(L+1)},\mathbf{z})\leq C_{0}n^{-1/2}.\]

We stress that the bounds in Theorem 6.1 provide (under different assumptions on \(\sigma\) and without any condition on the widths of the hidden layers) a detailed description of the analytical dependence of the upper estimate on the parameters of the model.

Proof.: Throughout this proof, for ease of notation, we put

\[\kappa:=d_{c}(\mathbf{z}^{(L+1)},\mathbf{z})\quad\text{and}\quad\gamma:=C_{W} \|\mathcal{O}_{\mathbf{n}_{L}}^{(L)}-\mathcal{O}^{(L)}\|_{L^{2}}.\]

We preliminary note that it suffices to prove that

\[\kappa\leq(80\|\Sigma_{n_{L+1}}^{-1}\|_{op}^{3/2}+48\|\Sigma_{n_{L+1}}^{-1}\|_ {op}+20\sqrt{2})n_{L+1}^{59/24}\gamma. \tag{6.3}\]

Indeed, the claim then follows by Theorem 5.1, noticing that

\[\|\Sigma_{n_{L+1}}^{-1}\|_{op}=\frac{1}{C_{b}+C_{W}\mathcal{O}^{(L)}} \tag{6.4}\]

and that \(C_{1}\leq C_{i}\), \(i=2,3\).

If \(\gamma>1/\mathrm{e}\), then the inequality (6.3) holds since \(\kappa\leq 1\) (which follows by the definition of the convex distance) and

\[20\sqrt{2}n_{L+1}^{59/24}\gamma>20\sqrt{2}\gamma>20\sqrt{2}/3>1.\]
From now on, we assume \(\gamma\leq 1/\mathrm{e}\). Let \(h\in\mathcal{I}_{n_{L+1}}\) (i.e., \(h\) is the indicator function of a measurable convex set in \(\mathbb{R}^{n_{L+1}}\)) be arbitrarily fixed and let

\[h_{t}(\mathbf{y}):=\mathbb{E}h(\sqrt{t}\mathbf{z}+\sqrt{1-t}\mathbf{y}),\quad t \in(0,1),\quad\mathbf{y}\in\mathbb{R}^{n_{L+1}}.\]

For any \(t\in(0,1)\), by Lemma 2.8\((i)\)

\[f_{t,h}(\mathbf{y}):=\frac{1}{2}\int_{t}^{1}\frac{1}{1-s}(\mathbb{E}h(\sqrt{t} \mathbf{z}+\sqrt{1-t}\mathbf{y})-\mathbb{E}h(\mathbf{z}))\mathrm{d}s,\quad \mathbf{y}\in\mathbb{R}^{n_{L+1}}\]

solves the Stein equation (2.5) with \(n_{L+1}\), \(h_{t}\), \(\Sigma_{n_{L+1}}\) defined by (3.4), and \(\mathbf{z}\), in place of \(d\), \(g\), \(\Sigma\) and \(\mathbf{N}_{\Sigma}\), respectively, i.e.,

\[h_{t}(\mathbf{y})-\mathbb{E}[h_{t}(\mathbf{z})]=\langle\mathbf{y},\nabla f_{t,h}(\mathbf{y})\rangle_{n_{L+1}}-\langle\Sigma_{n_{L+1}},\mathrm{Hess}\,f_{t,h }(\mathbf{y})\rangle_{H.S.},\quad\mathbf{y}\in\mathbb{R}^{n_{L+1}}. \tag{6.5}\]

By Lemma 2.9 it follows

\[\kappa\leq\frac{4}{3}\sup_{h\in\mathcal{I}_{n_{L+1}}}|\mathbb{E}h_{t}(\mathbf{ z}^{(L+1)})-\mathbb{E}h_{t}(\mathbf{z})|+\frac{20n_{L+1}}{\sqrt{2}}\frac{\sqrt{t}}{1 -t},\quad t\in(0,1). \tag{6.6}\]

Without loss of generality, hereafter we assume that \(\mathbf{z}\) is independent of \(\mathcal{F}_{L}\). Therefore, by (6.5) we have

\[\mathbb{E}[h_{t}(\mathbf{z}^{(L+1)})-h_{t}(\mathbf{z})\,|\,\mathcal{F}_{L}]= \sum_{i=1}^{n_{L+1}}\mathbb{E}[z_{i}^{(L+1)}\partial_{i}f_{t,h}(\mathbf{z}^{(L +1)})\,|\,\mathcal{F}_{L}]-\sum_{i,j=1}^{n_{L+1}}\Sigma_{n_{L+1}}(i,j)\mathbb{ E}[\partial_{ij}^{2}f_{t,h}(\mathbf{z}^{(L+1)})\,|\,\mathcal{F}_{L}]. \tag{6.7}\]

By Lemma 2.8\((i)\), for any \(t\in(0,1)\), the mapping \(\mathbf{y}\mapsto\partial_{i}f_{t,h}(\mathbf{y})\) is in \(C^{1}(\mathbb{R}^{n_{L+1}})\) and has bounded first order derivatives. Then, since \(\mathbf{z}^{(L+1)}\,|\,\mathcal{F}_{L}\) is a centered Gaussian random vector with covariance matrix

\[\Sigma^{\prime}_{n_{L+1}}:=(C_{b}+C_{W}\mathcal{O}_{\mathbf{n}_{L}}^{(L)}) \mathrm{Id}_{n_{L+1}}, \tag{6.8}\]

by Lemma 2.10\((ii)\) we have

\[\mathbb{E}[z_{i}^{(L+1)}\partial_{i}f_{t,h}(\mathbf{z}^{(L+1)})\,|\,\mathcal{ F}_{L}]=\sum_{j=1}^{n_{L+1}}\Sigma^{\prime}_{n_{L+1}}(i,j)\mathbb{E}[\partial_{ij}^{2}f_ {t,h}(\mathbf{z}^{(L+1)})\,|\,\mathcal{F}_{L}].\]

On combining this relation with (6.7) and taking the expectation, we have

\[\mathbb{E}[h_{t}(\mathbf{z}^{(L+1)})-h_{t}(\mathbf{z})] =\sum_{i,j=1}^{n_{L+1}}\mathbb{E}[(\Sigma^{\prime}_{n_{L+1}}(i,j) -\Sigma_{n_{L+1}}(i,j))\mathbb{E}[\partial_{ij}^{2}f_{t,h}(\mathbf{z}^{(L+1)}) \,|\,\mathcal{F}_{L}]]\] \[=\sum_{i,j=1}^{n_{L+1}}\mathbb{E}[\mathbb{E}[(\Sigma^{\prime}_{n_ {L+1}}(i,j)-\Sigma_{n_{L+1}}(i,j))\partial_{ij}^{2}f_{t,h}(\mathbf{z}^{(L+1)}) \,|\,\mathcal{F}_{L}]] \tag{6.9}\] \[=\mathbb{E}\langle\Sigma^{\prime}_{n_{L+1}}-\Sigma_{n_{L+1}}, \mathrm{Hess}(f_{t,h}(\mathbf{z}^{(L+1)}))\rangle_{H.S.}\]

where in the second equality we used the \(\mathcal{F}_{L}\)-measurability of \(\mathcal{O}_{\mathbf{n}_{L}}^{(L)}\). Taking the modulus on the relation (6.9) and applying the Cauchy-Schwarz inequality, we have

\[|\mathbb{E}[h_{t}(\mathbf{z}^{(L+1)})-h_{t}(\mathbf{z})]|\leq\sqrt{\mathbb{E} \|\Sigma^{\prime}_{n_{L+1}}-\Sigma_{n_{L+1}}\|^{2}_{H.S.}}\sqrt{\mathbb{E}\| \mathrm{Hess}(f_{t,h}(\mathbf{z}^{(L+1)}))\|^{2}_{H.S.}}. \tag{6.10}\]
By Lemma 2.8\((ii)\), for any \(h\in\mathcal{I}_{n_{L+1}}\), we have

\[\mathbb{E}\|\mathrm{Hess}(f_{t,h}(\mathbf{z}^{(L+1)}))\|_{H.S.}^{2}\leq\|\Sigma_{ n_{L+1}}^{-1}\|_{op}^{2}(n_{L+1}^{2}(\log t)^{2}\kappa+530n_{L+1}^{17/6}),\quad t \in(0,1).\]

Moreover,

\[\mathbb{E}\|\Sigma_{n_{L+1}}^{\prime}-\Sigma_{n_{L+1}}\|_{H.S.}^{2}=n_{L+1}C_{ W}^{2}\|\mathcal{O}_{\mathbf{n}_{L}}^{(L)}-\mathcal{O}^{(L)}\|_{L^{2}}^{2}. \tag{6.11}\]

On combining these relations and using the elementary inequality \(\sqrt{a_{1}+a_{2}}\leq\sqrt{a}_{1}+\sqrt{a}_{2}\), \(a_{1},a_{2}\geq 0\), we have

\[\sup_{h\in\mathcal{I}_{n_{L+1}}}|\mathbb{E}[h_{t}(\mathbf{z}^{(L +1)})-h_{t}(\mathbf{z})]|\] \[\qquad\leq C_{W}\|\Sigma_{n_{L+1}}^{-1}\|_{op}(n_{L+1}^{3/2}|\log t |\sqrt{\kappa}+24n_{L+1}^{23/12})\|\mathcal{O}_{\mathbf{n}_{L}}^{(L)}- \mathcal{O}^{(L)}\|_{L^{2}}.\]

On combining this latter inequality with (6.6), we have

\[\kappa\leq\frac{4}{3}\|\Sigma_{n_{L+1}}^{-1}\|_{op}(n_{L+1}^{3/2}|\log t| \sqrt{\kappa}+24n_{L+1}^{23/12})\gamma+\frac{20n_{L+1}}{\sqrt{2}}\frac{\sqrt{t }}{1-t},\quad t\in(0,1). \tag{6.12}\]

Since \(\kappa\leq 1\), by this relation we have

\[\kappa\leq\frac{4}{3}\|\Sigma_{n_{L+1}}^{-1}\|_{op}(n_{L+1}^{3/2}|\log t|+24n_ {L+1}^{23/12})\gamma+\frac{20n_{L+1}}{\sqrt{2}}\frac{\sqrt{t}}{1-t},\quad t\in (0,1).\]

Setting \(t=\gamma^{2}\) in this latter inequality (note that this choice of the parameter \(t\) is admissible since \(\gamma\leq 1/\mathrm{e}<1\)), we have

\[\kappa \leq\frac{4}{3}\|\Sigma_{n_{L+1}}^{-1}\|_{op}(2n_{L+1}^{3/2}|\log \gamma|+24n_{L+1}^{23/12})\gamma+\frac{20n_{L+1}}{\sqrt{2}}\frac{\gamma}{1- \gamma^{2}} \tag{6.13}\] \[\leq\frac{4}{3}\|\Sigma_{n_{L+1}}^{-1}\|_{op}(2n_{L+1}^{3/2}|\log \gamma|+24n_{L+1}^{23/12})\gamma+20\sqrt{2}n_{L+1}\gamma,\]

where in the latter inequality we used the relation

\[\frac{1}{\sqrt{2}}\frac{\gamma}{1-\gamma^{2}}\leq\sqrt{2}\gamma, \tag{6.14}\]

which holds since \(\gamma\leq 1/\mathrm{e}<1/\sqrt{2}\). We rewrite the inequality (6.13) as

\[\kappa\leq\frac{8}{3}\|\Sigma_{n_{L+1}}^{-1}\|_{op}n_{L+1}^{3/2}\gamma|\log \gamma|+(32n_{L+1}^{23/12}\|\Sigma_{n_{L+1}}^{-1}\|_{op}+20\sqrt{2}n_{L+1})\gamma.\]

Taking the square root and multiplying by \(|\log\gamma|\), we have

\[|\log\gamma|\sqrt{\kappa}\leq\sqrt{\frac{8}{3}}\|\Sigma_{n_{L+1}}^{-1}\|_{op}^ {1/2}n_{L+1}^{3/4}\gamma^{1/2}|\log\gamma|^{3/2}+(32n_{L+1}^{23/12}\|\Sigma_{n_ {L+1}}^{-1}\|_{op}+20\sqrt{2}n_{L+1})^{1/2}\gamma^{1/2}|\log\gamma|.\]
Since \(\max\{\sup_{y\in(0,1/\mathrm{e}]}y^{1/2}|\log y|^{3/2},\sup_{y\in(0,1/\mathrm{e}]}y^{1/2}| \log y|^{1/2}\}\leq 4\), we have

\[|\log\gamma|\sqrt{\kappa} \leq 4\sqrt{\frac{8}{3}}\|\Sigma_{n_{L+1}}^{-1}\|_{op}^{1/2}n_{L+1}^ {3/4}+4(32n_{L+1}^{23/12}\|\Sigma_{n_{L+1}}^{-1}\|_{op}+20\sqrt{2}n_{L+1})^{1/2}\] \[=8\frac{\sqrt{6}}{3}\|\Sigma_{n_{L+1}}^{-1}\|_{op}^{1/2}n_{L+1}^ {3/4}+4(32n_{L+1}^{23/12}\|\Sigma_{n_{L+1}}^{-1}\|_{op}+20\sqrt{2}n_{L+1})^{1/2}\] \[\leq 8\frac{\sqrt{6}}{3}\|\Sigma_{n_{L+1}}^{-1}\|_{op}^{1/2}n_{L+1 }^{3/4}+16\sqrt{2}n_{L+1}^{23/24}\|\Sigma_{n_{L+1}}^{-1}\|_{op}^{1/2}+\sqrt{2 0\sqrt{2}}n_{L+1}^{1/2}\] \[\leq\left[\left(8\frac{\sqrt{6}}{3}+16\sqrt{2}\right)\|\Sigma_{n _{L+1}}^{-1}\|_{op}^{1/2}+\sqrt{20\sqrt{2}}\right]n_{L+1}^{23/24} \tag{6.15}\] \[\leq(30\|\Sigma_{n_{L+1}}^{-1}\|_{op}^{1/2}+6)n_{L+1}^{23/24}.\]

By (6.12) with \(t=\gamma^{2}\), (6.14) and (6.15), we finally have (6.3), indeed

\[\kappa \leq\frac{4}{3}\|\Sigma_{n_{L+1}}^{-1}\|_{op}(2n_{L+1}^{3/2}|\log \gamma|\sqrt{\kappa}+24n_{L+1}^{23/12})\gamma+20\sqrt{2}n_{L+1}\gamma\] \[\leq\frac{4}{3}\|\Sigma_{n_{L+1}}^{-1}\|_{op}\left[\left(60\| \Sigma_{n_{L+1}}^{-1}\|_{op}^{1/2}+12\right)n_{L+1}^{59/24}+24n_{L+1}^{23/12} \right]\gamma+20\sqrt{2}n_{L+1}\gamma\] \[\leq(80\|\Sigma_{n_{L+1}}^{-1}\|_{op}^{3/2}+48\|\Sigma_{n_{L+1}}^ {-1}\|_{op}+20\sqrt{2})n_{L+1}^{59/24}\gamma.\]

The proof is completed.

\(\square\)

### Normal approximation of deep random Gaussian NNs in the \(1\)-Wasserstein distance

The following theorem holds.

**Theorem 6.3**.: _Let \(\mathrm{GNN}(L,n_{0},n_{L+1},\mathbf{n}_{L},\sigma,\mathbf{x},\mathbf{b}, \mathbf{W})\) be a deep random Gaussian NN, and let the notation and assumptions of Theorem 5.1 prevail. Then_

\[d_{W_{1}}(\mathbf{z}^{(L+1)},\mathbf{z}) \leq K_{1}\left(\sum_{k=1}^{L}[4\sqrt{2}\|P(|Z|)\|_{L^{2}}]^{L-k} \frac{c_{k}}{\sqrt{n_{k}}}\right)\] \[\leq K_{i}\left(\sum_{k=1}^{L}[4\sqrt{2}\|P(|Z|)\|_{L^{2}}]^{L-k} \frac{c_{k}}{\sqrt{n_{k}}}\right),\quad i=2,3\]

_where the constants \(c_{k}\), \(k=1,\ldots,L\), are defined by (5.2),_

\[K_{1}=K_{1}(n_{0},n_{L+1},\mathbf{x},\sigma,C_{b},C_{W}):=\frac{n_{L+1}C_{W}}{ \sqrt{C_{b}+C_{W}\mathcal{O}^{(L)}}},\]

\[K_{2}=K_{2}(n_{L+1},C_{b},C_{W}):=\frac{n_{L+1}C_{W}}{\sqrt{C_{b}}}\]

_and_

\[K_{3}=K_{3}(n_{0},n_{L+1},\mathbf{x},\sigma,C_{W}):=\frac{n_{L+1}\sqrt{C_{W}}}{ \sqrt{\mathcal{O}^{(L)}}},\]

**Remark 6.4**.: Let \(\mathrm{GNN}(L,n_{0},1,\mathbf{n}_{L},\sigma,\mathbf{x},\mathbf{b},\mathbf{W})\) be a deep random Gaussian NN with univariate output, widths of the hidden layers satsfying (6.2) and a polynomially bounded to order \(r\geq 1\)
activation function \(\sigma\). Then by Theorem 3.3 in [8] we have that there exist two constants \(C,C_{0}>0\) such that

\[\frac{C_{0}}{n}\leq d_{W_{1}}(z^{(L+1)},z)\leq\frac{C}{n}.\]

Clearly this inequality shows the optimality of the rate \(1/n\). Here again, we note that the corresponding bound provided by Theorem 6.3 gives (under different assumptions on \(\sigma\) and without any condition on the widths of the hidden layers) a detailed description of the analytical dependence of the upper estimate on the parameters of the model. This makes our result useful for the purpose of output localization (see Section 7).

_Proof._ Let \(g\in\mathcal{L}_{n_{L+1}}(1)\) be arbitrarily fixed. Without loss of generality we assume that \(\mathbf{z}\) is independent of \(\mathcal{F}_{L}\). By Lemma 2.7 we then have

\[\mathbb{E}[g(\mathbf{z}^{(L+1)})-g(\mathbf{z})\,|\,\mathcal{F}_{L}]=\sum_{i=1 }^{n_{L+1}}\mathbb{E}[z_{i}^{(L+1)}\partial_{i}f_{g}(\mathbf{z}^{(L+1)})\,| \,\mathcal{F}_{L}]-\sum_{i,j=1}^{n_{L+1}}\Sigma_{n_{L+1}}(i,j)\mathbb{E}[ \partial_{ij}^{2}f_{g}(\mathbf{z}^{(L+1)})\,|\,\mathcal{F}_{L}], \tag{6.16}\]

where

\[f_{g}(\mathbf{y}):=\int_{0}^{\infty}\mathbb{E}[g(\mathbf{z})-g(\mathrm{e}^{-t }\mathbf{y}+\sqrt{1-\mathrm{e}^{-2t}}\mathbf{z})]\,\mathrm{d}t,\quad\mathbf{y }\in\mathbb{R}^{n_{L+1}}.\]

Again by Lemma 2.7 we have that the mapping \(\mathbf{y}\mapsto\partial_{i}f_{g}(\mathbf{y})\) is in \(C^{1}(\mathbb{R}^{n_{L+1}})\) and has bounded first order derivatives. Applying Lemma 2.10\((ii)\) exactly as in the proof of Theorem 6.1 (see a few lines before Equation (6.9)), we have

\[\mathbb{E}[g(\mathbf{z}^{(L+1)})-g(\mathbf{z})]=\mathbb{E}\langle\Sigma^{ \prime}_{n_{L+1}}-\Sigma_{n_{L+1}},\mathrm{Hess}(f_{g}(\mathbf{z}^{(L+1)})) \rangle_{H.S.},\]

where the matrix \(\Sigma^{\prime}_{n_{L+1}}\) is defined by (6.8). Therefore, applying the Cauchy-Schwarz inequality as in (6.10), we have

\[|\mathbb{E}[g(\mathbf{z}^{(L+1)})-g(\mathbf{z})]|\leq\sqrt{\mathbb{E}\| \Sigma^{\prime}_{n_{L+1}}-\Sigma_{n_{L+1}}\|_{H.S.}^{2}}\sqrt{\mathbb{E}\| \mathrm{Hess}(f_{g}(\mathbf{z}^{(L+1)}))\|_{H.S.}^{2}} \tag{6.17}\]

By Lemma 2.7 we have

\[\sqrt{\mathbb{E}\|\mathrm{Hess}(f_{g}(\mathbf{z}^{(L+1)}))\|_{H.S.}^{2}}\leq \sup_{\mathbf{y}\in\mathbb{R}^{n_{L+1}}}\|\mathrm{Hess}f_{g}(\mathbf{y})\|_{H.S.}\leq\sqrt{n_{L+1}}\|\Sigma_{n_{L+1}}^{-1}\|_{op}\|\Sigma_{n_{L+1}}\|_{op}^ {1/2},\]

On combining these relations with (6.11), we have

\[|\mathbb{E}[g(\mathbf{z}^{(L+1)})-g(\mathbf{z})]|\leq n_{L+1}C_{W}\|\Sigma_{n _{L+1}}^{-1}\|_{op}\|\Sigma_{n_{L+1}}\|_{op}^{1/2}\|\mathcal{O}_{\mathbf{n}_{ L}}^{(L)}-\mathcal{O}^{(L)}\|_{L^{2}}.\]

The claim follows taking the supremum over \(g\) on this inequality and then using Theorem 5.1, relation (6.4) and the fact that

\[\|\Sigma_{n_{L+1}}\|_{op}=C_{b}+C_{W}\mathcal{O}^{(L)}.\]

\(\square\)
## 7. Localization of the output

In this section we want to show the potentiality of the obtained results for practical applications. Indeed, both Theorem 4.1\((ii)\) and Theorem 6.1 allow one to explicitly estimate the probability that the output of a random Gaussian NN evaluated at the input \(\mathbf{x}\) belongs to a suitable set, without resorting to computationally expensive Monte Carlo methods. This is what we call output localization, which can suggest a suitable architecture design to estimate a target function \(f\). Indeed in statistical learning, given a training set

\[\{(\mathbf{x}_{i},f(\mathbf{x}_{i})\}_{i\in I}\subset\mathbb{R}^{n_{0}}\times \mathbb{R}^{n_{L+1}},\]

the goal is to estimate the unknown function \(f\) by a NN with a certain fixed architecture. This is performed by minimizing an empirical risk function over the space of NN's parameters, i.e., the biases and the weights. Such kind of minimization problems are non-convex and are usually addressed by a gradient descent procedure; the latter stabilizes towards a solution which depends on the inizialization point. Since in practical applications the inizialization point is given by a realization of a random Gaussian NN, it can be convenient to choose \(L\), \(\mathbf{n}_{L}\), \(\sigma\), \(C_{b}\) and \(C_{W}\) by exploiting output localization, i.e., in such a way to have a good estimate of the probability \(\mathbb{P}(\mathbf{z}^{(L+1)}\left(\mathbf{x}_{i}\right)\in V_{i})\), \(i\in I\), where \(V_{i}\) is an appropriate neighborhood of \(f(\mathbf{x}_{i})\).

Hence, in the following we want to show how to use the upper bound on the total variation distance provided in Theorem 4.1\((ii)\), for a shallow random Gaussian NN with univariate output, and the upper bound on the convex distance provided by Theorem 6.1, for a deep random Gaussian NN, to localize the output. Indeed, given a measurable convex set \(V\subset\mathbb{R}^{n_{L+1}}\), by the definitions of both the total variation and the convex distances we have

\[\mathbb{P}(\mathbf{z}\in V)-C_{bound}\leq\mathbb{P}(\mathbf{z}^{(L+1)}\in V) \leq\mathbb{P}(\mathbf{z}\in V)+C_{bound},\]

where \(L=1\), \(n_{2}=1\) and

\[C_{bound}:=2\frac{C_{W}\sqrt{\forall\text{Var}(\sigma(Z\sqrt{C_{b}+C_{W} \mathcal{O}^{(0)}})^{2})}}{C_{b}+C_{W}\mathbb{E}\sigma(Z\sqrt{C_{b}+C_{W} \mathcal{O}^{(0)}})^{2}}\frac{1}{\sqrt{n_{1}}}, \tag{7.1}\]

for the case of a shallow NN, while

\[C_{bound}:=C_{1}\left(\sum_{k=1}^{L}[4\sqrt{2}\|P(|Z|)\|_{L^{2}}]^{L-k}\frac{ c_{k}}{\sqrt{n_{k}}}\right), \tag{7.2}\]

for the case of a deep NN, where \(C_{1}\) is given by (6.1) and the constants \(c_{k}\), \(k=1,\ldots,L\), are defined by (5.2).

Let \(V:=\prod_{i=1}^{n_{L+1}}[r_{i},s_{i}]\) be a rectangle of \(\mathbb{R}^{n_{L+1}}\). Since \(\mathbf{z}\) is an \(n_{L+1}\)-dimensional centered Gaussian random vector with covariance matrix (3.4), we have

\[\mathbb{P}(\mathbf{z}\in V)=\prod_{i=1}^{n_{L+1}}\left(\mathbb{P}\left(Z\leq \frac{s_{i}}{\sqrt{C_{b}+C_{W}\mathcal{O}^{(L)}}}\right)-\mathbb{P}\left(Z\leq \frac{r_{i}}{\sqrt{C_{b}+C_{W}\mathcal{O}^{(L)}}}\right)\right).\]

Now, we furnish numerical values of the constant \(C_{bound}\) in (7.1) and (7.2); in both cases we take \(\sigma(x):=x\mathbf{1}\{x\geq 0\}\), i.e., a ReLu activation function. Since the ReLu function is Lipschitz
continuous with Lipschitz constant equal to \(1\), \(\mathbb{E}Z^{2}=1\) and \(\mathbb{E}Z^{4}=3\), by Proposition 5.2\((ii)\) we have

\[\|P(|Z|)\|_{L^{2}}=C_{W}\sqrt{\mathbb{E}Z^{4}\mathbf{1}\{Z\geq 0\}}=C_{W}\sqrt{3/2}.\]

By the expression of the constants \(c_{\ell}\) in Theorem 5.1, we have

\[c_{\ell}=(C_{b}+C_{W}\mathcal{O}^{(\ell-1)})\sqrt{2\mathbb{E}Z^{4}\mathbf{1}\{ Z\geq 0\}}=(C_{b}+C_{W}\mathcal{O}^{(\ell-1)})\sqrt{3},\quad\ell=1,\ldots,L.\]

By the definition of the quantities \(\mathcal{O}^{(\ell)}\), \(\ell=1,\ldots,L\), (see (3.2)) we have

\[\mathcal{O}^{(\ell)}=(C_{b}+C_{W}\mathcal{O}^{(\ell-1)})\mathbb{E}Z^{2} \mathbf{1}\{Z\geq 0\}=(C_{b}+C_{W}\mathcal{O}^{(\ell-1)})/2,\quad\ell=1,\ldots,L\]

with \(\mathcal{O}^{(0)}\) given by (3.3). Therefore,

\[\mathcal{O}^{(\ell)}=\frac{C_{b}}{2}\sum_{k=0}^{\ell-1}\frac{C_{W}^{k}}{2^{k}} +\frac{C_{W}^{\ell}}{2^{\ell}}\mathcal{O}^{(0)}.\]

Table 2 gives the values of \(C_{bound}\) in (7.1) in the case of a shallow random Gaussian NN with architecture \(L=1\), \(n_{0}=4\), \(n_{1}=n\) and \(n_{2}=1\), for different values of \(n\in\{1,10,10^{2},10^{3},10^{4},10^{5}\}\). Table 3 gives the values of \(C_{bound}\) in (7.2) in the case of a deep random Gaussian NN with architecture \(L=3\), \(n_{0}=4\), \(n_{1}=n_{2}=n_{3}=n\) and \(n_{4}=1\), for different values of \(n\in\{10^{4},10^{5},10^{6},10^{7},10^{8},10^{9}\}\). In both tables we consider four different inputs

\[\mathbf{x}\in\{(0,0,0,0),(0.1,0.1,0.1,0.1),(0.5,-0.5,0.5,-0.5),(10,10,10,10)\},\]

\begin{table}
\begin{tabular}{c|c c c|c c c|c c c|c c c|c c c|c c c} \hline \hline  & \multicolumn{11}{c}{\(\mathbf{x}=(\mathbf{0},\mathbf{0},\mathbf{0},\mathbf{0})\)} \\ \hline \(n\) & \multicolumn{1}{c}{1} & \multicolumn{1}{c}{10} & \multicolumn{1}{c}{10\({}^{2}\)} & \multicolumn{1}{c}{10\({}^{3}\)} & \multicolumn{1}{c}{10\({}^{4}\)} & \multicolumn{1}{c}{10\({}^{5}\)} \\ \hline \(C_{b}\) & \(C_{W}\) & \(0.01\) & \(0.1\) & \(1\) & \(0.01\) & \(0.1\) & \(1\) & \(0.01\) & \(0.1\) & \(1\) & \(0.01\) & \(0.1\) & \(1\) & \(0.01\) & \(1\) & \(0.01\) & \(1\) \\ \hline \(1\) & \(0.02\) & \(0.21\) & \(1.49\) & \(0.01\) & \(0.07\) & \(0.47\) & \(0.00\) & \(0.02\) & \(0.15\) & \(0.00\) & \(0.01\) & \(0.05\) & \(0.00\) & \(0.00\) & \(0.01\) & \(0.00\) & \(0.00\) & \(0.00\) \\ \(10\) & \(0.01\) & \(0.07\) & \(0.47\) & \(0.00\) & \(0.02\) & \(0.15\) & \(0.00\) & \(0.01\) & \(0.05\) & \(0.00\) & \(0.00\) & \(0.01\) & \(0.00\) & \(0.00\) & \(0.00\) & \(0.00\) & \(0.00\) & \(0.00\) \\ \hline \hline  & \multicolumn{11}{c}{\(\mathbf{x}=(\mathbf{0}.\mathbf{1},\mathbf{0},\mathbf{1},\mathbf{0}, \mathbf{1},\mathbf{0}.\mathbf{1})\)} \\ \hline \(n\) & \multicolumn{11}{c}{10} & \multicolumn{11}{c}{10\({}^{2}\)} & \multicolumn{11}{c}{10\({}^{3}\)} & \multicolumn{11}{c}{10\({}^{4}\)} & \multicolumn{11}{c}{10\({}^{5}\)} \\ \hline \(C_{b}\) & \(C_{W}\) & \(0.01\) & \(0.1\) & \(1\) & \(0.01\) & \(0.1\) & \(1\) & \(0.01\) & \(1\) & \(0.01\) & \(1\) & \(0.01\) & \(1\) & \(1\) & \(0.01\) & \(0.1\) & \(1\) \\ \hline \(1\) & \(0.02\) & \(0.21\) & \(1.49\) & \(0.01\) & \(0.07\) & \(0.47\) & \(0.00\) & \(0.02\) & \(0.15\) & \(0.00\) & \(0.01\) & \(0.05\) & \(0.00\) & \(0.00\) & \(0.01\) & \(0.00\) & \(0.00\) & \(0.00\) \\ \(10\) & \(0.01\) & \(0.07\) & \(0.47\) & \(0.00\) & \(0.02\) & \(0.15\) & \(0.00\) & \(0.01\) & \(0.05\) & \(0.00\) & \(0.00\) & \(0.01\) & \(0.00\) & \(0.00\) & \(0.00\) & \(0.00\) & \(0.00\) \\ \hline \hline  & \multicolumn{11}{c}{\(\mathbf{x}=(\mathbf{0}.\mathbf{5},-\mathbf{0}.\mathbf{5},\mathbf{0}. \mathbf{5},-\mathbf{0}.\mathbf{5})\)} \\ \hline \(n\) & \multicolumn{11}{c}{10} & \multicolumn{11}{c}{10\({}^{2}\)} & \multicolumn{11}{c}{10\({}^{3}\)} & \multicolumn{11}{c}{10\({}^{4}\)} & \multicolumn{11}{c}{10\({}^{5}\)} \\ \hline \(C_{b}\) & \(C_{W}\) & \(0.01\) & \(0.1\) & \(1\) & \(0.01\) & \(0.1\) & \(1\) & \(0.01\) & \(0.1\) & \(1\) & \(0.01\) & \(0.1\) & \(1\) & \(0.01\) & \(1\) & \(0.01\) & \(1\) \\ \hline \(1\) & \(0.02\) & \(0.22\) & \(1.54\) & \(0.01\) & \(0.07\) & \(0.49\) & \(0.00\) & \(0.02\) & \(0.15\) & \(0.00\) & \(0.01\) & \(0.05\) & \(0.00\) & \(0.00\) & \(0.02\) & \(0.00\) & \(0.00\) & \(0.00\) \\ \(10\) & \(0.01\) & \(0.07\) & \(0.47\) & \(0.00\) & \(0.02\) & \(0.15\) & \(0.00\) & \(0.01\) & \(0.05\) & \(0.00\) & \(0.00\) & \(0.01\) & \(0.00\) & \(0.00\) & \(0.00\) & \(0.00\) & \(0.00\) & \(0.00\) \\ \hline \hline  & \multicolumn{11}{c}{\(\mathbf{x}=(\mathbf{10},\mathbf{10},\mathbf{10},\mathbf{10}, \mathbf{10})\)} \\ \hline \(n\) & \multicolumn{11}{c}{10} & \multicolumn{11}{c}{10} & \multicolumn{11
whose Euclidean norm is, respectively, \(0\), strictly less than \(1\), \(1\) and strictly larger than \(1\), and

\[C_{b}\in\{1,10\}\quad\text{and}\quad C_{W}\in\{0.01,0.1,1\}.\]

It is clear from Table 2 that for a shallow random Gaussian NN, the Gaussian approximation of the output is very good for any of the choices of the parameters \(n\), \(C_{b}\), \(C_{W}\) and of the input \(\mathbf{x}\). It is also clear from Table 3 that for a deep random Gaussian NN, such as the considered NN with three hidden layers, the Gaussian approximation of the output is very good for some choices of the parameters \(C_{b}\), \(C_{W}\), \(n\) and of the input \(\mathbf{x}\) (also when the number \(n\) of neurons in the hidden layers is not excessive) but it is very poor for other choices of these quantities. In order to analyse the influence of the parameters \(C_{b}\), \(C_{W}\) and of the input \(\mathbf{x}\) on the value of \(C_{bound}\) in (7.2), in Table 4 we reported the value of the constant \(C_{1}\) that appears in (7.2) and it is explicitly given in (6.1). As it can be seen from this table, the value of \(C_{bound}\) strongly depends on the value of \(C_{1}\) which,

\begin{table}
\begin{tabular}{l|r r r|r r r|r r r|r r r r|r r r r} \hline  & \multicolumn{10}{c}{\(\mathbf{x}=(\mathbf{0},\mathbf{0},\mathbf{0},\mathbf{0})\)} & \multicolumn{10}{c}{\(\mathbf{x}=(\mathbf{0}.\mathbf{1},\mathbf{0}.\mathbf{1},\mathbf{0}.\mathbf{1}, \mathbf{0}.\mathbf{1})\)} & \multicolumn{1}{c}{\(\mathbf{x}=(\mathbf{0}.\mathbf{5},-\mathbf{0}.\mathbf{5},\mathbf{0}. \mathbf{5},-\mathbf{0}.\mathbf{5})\)} & \multicolumn{1}{c}{\(\mathbf{x}=(\mathbf{10},\mathbf{10},\mathbf{10},\mathbf{10})\)} \\ \hline \(C_{b}\)\(C_{W}\) & 0.01 & 0.1 & 1 & 0.01 & 0.1 & 1 & 0.01 & 0.1 & 1 & 0.01 & 0.1 & 1 & 0.01 & 0.1 & 1 \\ \hline
1 & 1.55 & 14.80 & 85.04 & 1.55 & 14.80 & 85.00 & 1.55 & 14.80 & 83.86 & 1.55 & 14.78 & 33.09 & \\
10 & 0.36 & 3.52 & 31.83 & 0.36 & 3.52 & 31.83 & 0.36 & 3.52 & 31.82 & 0.36 & 3.52 & 30.28 & \\ \hline \end{tabular}
\end{table}
Table 4. Values of \(C_{1}\) in (6.1) for different inputs \(\mathbf{x}\) for a deep random Gaussian NN with architecture \(L=3\), \(n_{0}=4\), \(n_{1}=n_{2}=n_{3}=n\), \(n_{4}=1\) and ReLu activation function.

\begin{table}
\begin{tabular}{l|r r r|r r|r r r|r r r|r r r r|r r r} \hline \hline \(n\) & \multicolumn{10}{c}{\(\mathbf{x}=(\mathbf{0},\mathbf{0},\mathbf{0},\mathbf{0})\)} & \multicolumn{10}{c}{\(\mathbf{x}=(\mathbf{0},\mathbf{0},\mathbf{0},\mathbf{1})\)} \\ \hline \(C_{b}\)\(C_{W}\) & 0.01 & 0.1 & 1 & 0.01 & 0.1 & 1 & 0.01 & 0.1 & 1 & 0.01 & 0.1 & 1 & 0.01 & 0.1 & 1 & 0.01 & 0.1 & 1 \\ \hline
1 & 0.03 & 0.58 & 88.59 & 0.01 & 0.18 & 28.01 & 0.00 & 0.06 & 8.86 & 0.00 & 0.02 & 2.80 & 0.00 & 0.01 & 0.89 & 0.00 & 0.00 & 0.28 \\
10 & 0.07 & 1.38 & 331.57 & 0.02 & 0.44 & 104.85 & 0.01 & 0.14 & 33.16 & 0.00 & 0.04 & 10.49 & 0.00 & 0.01 & 3.32 & 0.00 & 0.00 & 1.05 \\ \hline \hline \multicolumn{10}{c}{\(\mathbf{x}=(\mathbf{0},\mathbf{1},\mathbf{0},\mathbf{1},\mathbf{0},\mathbf{1}, \mathbf{0}.\mathbf{1})\)} \\ \hline \(n\) & \multicolumn{10}{c}{\(\mathbf{10}^{4}\)} & \multicolumn{10}{c}{\(\mathbf{10}^{5}\)} & \multicolumn{10}{c}{\(\mathbf{10}^{6}\)} & \multicolumn{10}{c}{\(\mathbf{10}^{7}\)} & \multicolumn{10}{c}{\(\mathbf{10}^{8}\)} & \multicolumn{1}{c}{\(\mathbf{10}^{9}\)} \\ \hline \(C_{b}\)\(C_{W}\) & 0.01 & 0.1 & 1 & 0.01 & 1 & 0.01 & 0.1 & 1 & 0.01 & 0.1 & 1 & 0.01 & 0.1 & 1 & 0.01 & 0.1 & 1 \\ \hline
1 & 0.03 & 0.58 & 89.30 & 0.01 & 0.18 & 28.24 & 0.00 & 0.06 & 8.93 & 0.00 & 0.02 & 2.82 & 0.00 & 0.01 & 0.89 & 0.00 & 0.00 & 0.28 \\
10 & 0.07 & 1.38 & 331.85 & 0.02 & 0.44 & 104.94 & 0.01 & 0.14 & 33.18 & 0.00 & 0.04 & 10.49 & 0.00 & 0.01 & 3.32 & 0.00 & 0.00 & 1.05 \\ \hline \hline \multicolumn{10}{c}{\(\mathbf{x}=(\mathbf{0},\mathbf{5},-\mathbf{0},\mathbf{5},\mathbf{0},-\mathbf{0}.\mathbf{5})\)} \\ \hline \(n\) & \multicolumn{10}{c}{\(\mathbf{10}^{*}\)} & \multicolumn{10}{c}{\(\mathbf{10}^{*}\)} & \multicolumn{10}{c}{\(\mathbf{10}^{*}\)} & \multicolumn{10}{c}{\(\mathbf{10}^{*}\)} & \multicolumn{10}{c}{\(\mathbf{10}^{*}\)} & \multicolumn{10}{c}{\(\mathbf{10}^{*}\)} \\ \hline \(C_{b}\)\(C_{W}\) & 0.01 & 0.1 & 1 & 0.01 & 1 & 0.01 & 0.1 & 1 & 0.01 & 0.1 & 1 & 0.01 & 0.1 & 1 & 0.01 & 0.1 & 1 \\ \hline
1 & 0.03 & 0.58 & 106.14 & 0.01 & 0.18 & 33.56 & 0.00 & 0.06 & 10.61 & 0.00 & 0.02 & 3.36 & 0.00 & 0.01 & 1.06 & 0.00 & 0.00 & 0.34 \\
10 & 0.07 & 1.38 & 338.62 & 0.02 & 0.44 & 107.08 & 0.01 & 0.14 & 33.86 & 0.00 & 0.04 & 10.71 & 0.00 & 0.01 & 3.39 & 0.00 & 0.00 & 1.07 \\ \hline \hline \multicolumn{10}{c}{\(\mathbf{x}=(\mathbf{10},\mathbf{10},\mathbf{10},\mathbf{10},\mathbf{10})\)} \\ \hline \(n\) & \multicolumn{10}{c}{\(\mathbf{10}^{4}\)} & \multicolumn{10}{c}{\(\mathbf{10}^{5}\)} & \multicolumn{10}{c}{\(\mathbf{10}^{6}\)} & \multicolumn{10}{c}{\(\mathbf{10}^{7}\)} & \multicolumn{10}{c}{\(\mathbf{10}^{8}\)} & \multicolumn{1}{c}{\(\mathbf{10}^{6}\)} \\ \hline \(C_{b}\)\(C_{W}\) & 0.01 & 0.1 & 1 & 0.01 & 0.1 & 1 & 0.01 & 0.1 & 1 & 0.01 & 0.1 & 1 & 0.01 & 0.1 & 1 & 0.01 & 0.1 & 1 \\ \hline
1 & 0.03 & 1.90 & 2998.50 & 0.01 & 0.06 & 948.21 & 0.00 & 0.19 & 299.85 & 0.00 & 0.06 & 94.82 & 0.00 & 0.02 & 29.99
in turn, it is closely related to the choice of the parameters \(C_{b}\) and \(C_{W}\) and does not depend much on the norm of the input vector \(\mathbf{x}\).
