L 2 L_{2} -approximation using median lattice algorithms Zexin Pan, Peter Kritzer, Takashi Goda Abstract In this paper, we study the problem of multivariate L 2 L_{2} -approximation of functions belonging to a weighted Korobov space. We propose and analyze a median lattice-based algorithm, inspired by median integration rules, which have attracted significant attention in the theory of quasi-Monte Carlo methods. Our algorithm approximates the Fourier coefficients associated with a suitably chosen frequency index set, where each coefficient is estimated by taking the median over approximations from randomly shifted rank-1 lattice rules with independently chosen generating vectors. We prove that the algorithm achieves, with high probability, a convergence rate of the L 2 L_{2} -approximation error that is arbitrarily close to optimal with respect to the number of function evaluations. Furthermore, we show that the error bound depends only polynomially on the dimension, or is even independent of the dimension, under certain summability conditions on the weights. Numerical experiments illustrate the performance of the proposed median lattice-based algorithm. MSC Classification]41A25, 41A63, 65D15, 65D30, 65Y20 keywords multivariate L_{2} -approximation, median algorithm, lattice algorithm, Korobov spaces, quasi-Monte Carlo methods, tractability pacs [ 1 Introduction In this paper, we study the problem of multivariate L_{2} -approximation in weighted Korobov spaces of smoothness \alpha , denoted by \mathcal{H}_{d,\alpha,\boldsymbol{\gamma}} . Our goal is to derive a probabilistic result that yields a competitive error bound with high probability. This result, in turn, leads to an almost optimal rate of the randomized (worst-case root-mean-squared) L_{2} -approximation error. In this context, d is the number of variables the elements of the space depend on (frequently referred to as the dimension of the approximation problem), \alpha is the smoothness parameter and \boldsymbol{\gamma}=(\gamma_{\mathfrak{u}})_{\mathfrak{u}\in\{1{:}d\}} is a collection of weights . Here and in the following, we write \{1{:}V\} to denote the set \{1,\ldots,V\} for a positive integer V . The basic idea of weights is to assign a positive number to every possible group of variables \mathfrak{u}\in\{1{:}d\} , which describes how much influence the respective groups of variables have in the problem. Large values of \gamma_{\mathfrak{u}} indicate higher influence, low values of \gamma_{\mathfrak{u}} indicate less influence. This concept was introduced in the seminal paper [ 25 ] . We will give the detailed definition of the spaces \mathcal{H}_{d,\alpha,\boldsymbol{\gamma}} and further comments on the weights in Section 2 . Korobov spaces are Hilbert spaces of d -variate, one-periodic functions with absolutely convergent Fourier series. These spaces have been studied frequently in the context of numerical integration and function approximation (see, e.g., [ 5 , 3 , 24 ] for overviews), but have—in a slightly different form—recently also attracted interest in the literature on neural networks, see [ 18 ] . A natural approach for approximating functions in Korobov spaces is to truncate the Fourier series first and then approximate the remaining Fourier coefficients, see, e.g., [ 16 , 21 ] and the references therein. Specifically, we define a finite set \mathcal{A}\subset\mathbb{Z}^{d} , and approximate f\in\mathcal{H}_{d,\alpha,\boldsymbol{\gamma}} by truncating its Fourier expansion to the frequencies in \mathcal{A} first: f(\boldsymbol{x})=\sum_{\boldsymbol{h}\in\mathbb{Z}^{d}}\widehat{f}(\boldsymbol{h})\exp(2\pi\mathtt{i}\boldsymbol{h}\cdot\boldsymbol{x})\approx\sum_{\boldsymbol{h}\in\mathcal{A}}\widehat{f}(\boldsymbol{h})\exp(2\pi\mathtt{i}\boldsymbol{h}\cdot\boldsymbol{x}), where \widehat{f}({\boldsymbol{h}}):=\int_{[0,1]^{d}}f(\boldsymbol{x})\exp({-2\pi\mathtt{i}\boldsymbol{h}\cdot\boldsymbol{x}})\,\mathrm{d}\boldsymbol{x} denotes the \boldsymbol{h} -th Fourier coefficient of f and \cdot denotes the standard inner product in \mathbb{R}^{d} . Here, the set \mathcal{A} needs to be chosen carefully so that we can handle the truncation error and, simultaneously, that the computational cost of an approximation algorithm based on \mathcal{A} is not too high. Once we have selected \mathcal{A} , the next step is to approximate each Fourier coefficient \widehat{f}(\boldsymbol{h}) for every \boldsymbol{h}\in\mathcal{A} . Since each Fourier coefficient is defined as an integral over [0,1]^{d} , as shown above, a suitable integration rule can be used for this approximation. In this paper, we employ quasi-Monte Carlo (QMC) rules for this purpose. QMC rules are equal-weight quadrature rules of the form Q_{N,d}(g)=\frac{1}{N}\sum_{k=0}^{N-1}g(\boldsymbol{x}_{k}), where the integration nodes \boldsymbol{x}_{0},\ldots,\boldsymbol{x}_{N-1} are chosen deterministically in a way that matches the properties of the integrand g . The standard choice for integrating functions in Korobov spaces is to use lattice point sets as integration nodes, yielding lattice rules Q_{N,d} (we again refer to Section 2 for details). This principal idea goes back to Korobov, see [ 12 ] and also [ 9 ] . We will mostly follow the paper [ 16 ] in our notation, but we also refer to [ 17 , 26 , 27 , 28 ] for related results. As shown in [ 16 ] and related works, using a single lattice rule with M nodes to approximate the Fourier coefficients yields a convergence rate of the worst-case (i.e., considering the supremum over all functions in the unit ball of the space) L_{2} -approximation error (see Section 2 ) arbitrarily close to \mathcal{O}(M^{-\alpha/2}) . In a slightly more general setting, [ 1 ] proves that the rate \mathcal{O}(M^{-\alpha/2}) cannot be improved with such an approach for any d\geq 2 . However, as shown in [ 10 ] and [ 11 ] , this convergence rate can be improved in a probabilistic sense by employing so-called multiple lattices . Moreover, in the recent paper [ 2 ] by Cai, Goda, and Kazashi, the authors introduced a randomized lattice-based algorithm for L_{2} -approximation and proved that one can achieve a convergence rate arbitrarily close to \mathcal{O}(M^{-\alpha/2-1/8}) of the worst-case root-mean-squared L_{2} -approximation error. The same paper proves that this randomized algorithm cannot achieve a better rate than \mathcal{O}(M^{-\alpha/2-1/2}) . The key idea that we present in this paper is to adopt a probabilistic framework by using so-called median lattice rules to approximate all Fourier coefficients \widehat{f}(\boldsymbol{h}) , \boldsymbol{h}\in\mathcal{A} , instead of relying on a single fixed lattice rule. Median integration rules, as previously studied in, e.g., [ 6 , 7 , 22 , 23 ] , rely on a randomly chosen or suitably randomized point set within a QMC rule. By repeating this random experiment R times and then taking the median of the resulting estimates, one obtains a quadrature rule that can often be applied over a wide range of parameters, such as smoothness and weights, without the need to specify them in advance, while still achieving excellent convergence rates. In the present context, we apply a median rule based on R independent lattice rules, each using N nodes, requiring a total of M=RN function evaluations. The number of repetitions R must grow with N , but only at a rate proportional to \log N , making the approach computationally feasible even for large N . Our main result shows that the proposed algorithm achieves a convergence rate arbitrarily close to \mathcal{O}(M^{-\alpha}) with high probability for individual functions in \mathcal{H}_{d,\alpha,\boldsymbol{\gamma}} . Moreover, we show that, under suitable summability conditions on the weights \boldsymbol{\gamma} , the dependence of both the required number of repetitions R and the probabilistic error bound on the dimension d can be significantly reduced or even eliminated. This property links our result to the field of Information-Based Complexity , see [ 20 ] , and ensures that high-dimensional problems remain computationally feasible. Although this main result does not necessarily imply that the proposed algorithm achieves the worst-case L_{2} -approximation error of \mathcal{O}(M^{-\alpha+\varepsilon}) with high probability (see Section 6 ), it can be shown that the algorithm does achieve the randomized (worst-case root-mean-squared) L_{2} -approximation error of \mathcal{O}(M^{-\alpha+\varepsilon}) . Importantly, this convergence rate is optimal in the sense that no randomized algorithm based on M function evaluations can achieve a better rate (see again Section 6 ). The rest of the paper is structured as follows. In Section 2 , we define the space \mathcal{H}_{d,\alpha,\boldsymbol{\gamma}} , formally state the approximation problem, and introduce rank-1 lattice rules. Section 3 presents our median lattice-based algorithm and shows the main result of this paper on the L_{2} -approximation error bound. Section 4 examines to what extent and under what conditions the curse of dimensionality can be avoided in our approximation error bounds. Section 5 reports numerical results illustrating the performance of the proposed algorithm. The paper concludes with a discussion in Section 6 . 2 Preliminaries and notation Below, we denote the set of integers by \mathbb{Z} and the set of positive integers by \mathbb{N} . Furthermore, as usual, we denote the exponential function by \exp , and write \exp(1)=e for short. Bold symbols denote vectors, where the length is usually clear from the context. Further notation will be introduced as necessary. 2.1 Weighted Korobov spaces Let \boldsymbol{\gamma}=(\gamma_{\mathfrak{u}})_{\mathfrak{u}\in\{1{:}d\}} be a collection of positive reals, which we refer to as the weights in the following. As mentioned in the introduction, the weight \gamma_{\mathfrak{u}} models the influence of the group of variables x_{j} with indices j\in\mathfrak{u} . In this paper, we restrict ourselves to the most common case of weights, namely product weights , which are characterized by a non-increasing positive sequence (\gamma_{j})_{j\geq 1} , where we assume that 1\geq\gamma_{1}\geq\gamma_{2}\geq\cdots . In this case we choose \gamma_{\mathfrak{u}}:=\prod_{j\in\mathfrak{u}}\gamma_{j}, and put \gamma_{\emptyset}:=1 . We remark that also other choices of weights are considered in the literature, for which one may also allow single weights \gamma_{\mathfrak{u}} to be zero. However, to avoid technical difficulties, we restrict ourselves to the product weight case in the present paper. We also note that the assumption that 1\geq\gamma_{1} could be dropped without changing the nature of the results in this paper, but resulting in additional technical notation. For the sake of simplicity, we therefore stay with the assumption 1\geq\gamma_{1} in the following. For other kinds of weights and the corresponding function spaces, see, e.g., [ 5 , 3 ] . For product weights \boldsymbol{\gamma} as above, and a real number \alpha>1/2 , we define the function r_{2\alpha,\boldsymbol{\gamma}}(\boldsymbol{h}):=\prod_{j=1}^{d}\max\left\{\frac{\left|h_{j}\right|^{2\alpha}}{\gamma_{j}},1\right\} for \boldsymbol{h}=(h_{1},\ldots,h_{d})\in\mathbb{Z}^{d} . We now define the weighted Korobov space \mathcal{H}_{d,\alpha,\boldsymbol{\gamma}} , which is a reproducing kernel Hilbert space consisting of one-periodic functions on [0,1]^{d} , where periodicity is understood with respect to each variable. The reproducing kernel and the inner product in \mathcal{H}_{d,\alpha,\boldsymbol{\gamma}} are given, respectively, by K_{d,\alpha,\boldsymbol{\gamma}}(\boldsymbol{x},\boldsymbol{y})=\sum_{\boldsymbol{h}\in\mathbb{Z}^{d}}\frac{\exp(2\pi i\boldsymbol{h}\cdot(\boldsymbol{x}-\boldsymbol{y}))}{r_{2\alpha,\boldsymbol{\gamma}}(\boldsymbol{h})}, and \langle f,g\rangle_{d,\alpha,\boldsymbol{\gamma}}=\sum_{\boldsymbol{h}\in\mathbb{Z}^{d}}\hat{f}(\boldsymbol{h})\,\overline{\hat{g}(\boldsymbol{h})}\,r_{2\alpha,\boldsymbol{\gamma}}(\boldsymbol{h}), where, as already defined in the introduction, \widehat{f}({\boldsymbol{h}}) denotes the \boldsymbol{h} -th Fourier coefficient of f . The induced norm is then given by \|f\|_{d,\alpha,\boldsymbol{\gamma}}=\sqrt{\langle f,f\rangle_{d,\alpha,\boldsymbol{\gamma}}} . Note that \mathcal{H}_{d,\alpha,\boldsymbol{\gamma}} is a subspace of L_{2}([0,1]^{d}) , and that every element of the Korobov space with \alpha>1/2 can be represented pointwise by its Fourier series. Moreover, it is known that if \alpha\in\mathbb{N} , we have that \mathcal{H}_{d,\alpha,\boldsymbol{\gamma}} consists of all functions whose mixed partial derivatives up to order \alpha-1 in each variable are absolutely continuous and whose mixed derivatives of order \alpha belong to L_{2}([0,1]^{d}) (see [ 4 , 14 ] for details). For this reason, \alpha is referred to as the smoothness parameter. 2.2 L_{2} -approximation Our goal is to study L_{2} -approximation of functions f\in\mathcal{H}_{d,\alpha,\boldsymbol{\gamma}} . Formally, this corresponds to approximating the embedding operator S:\mathcal{H}_{d,\alpha,\boldsymbol{\gamma}}\to L_{2}([0,1]^{d}) , S(f)=f . For a given deterministic approximation algorithm A:\mathcal{H}_{d,\alpha,\boldsymbol{\gamma}}\to L_{2}([0,1]^{d}) , a common error measure is the worst-case error, defined as \displaystyle\mathrm{err}(\mathcal{H}_{d,\alpha,\boldsymbol{\gamma}},L_{2},A):=\sup_{\begin{subarray}{c}f\in\mathcal{H}_{d,\alpha,\boldsymbol{\gamma}}\\ \left\|f\right\|_{d,\alpha,\boldsymbol{\gamma}}\leq 1\end{subarray}}\|f-A(f)\|_{L_{2}}, (1) i.e., one considers the worst performance of A over the unit ball of \mathcal{H}_{d,\alpha,\boldsymbol{\gamma}} . When we speak of a randomized approximation algorithm, we refer to a pair consisting of a probability space (\Omega,\Sigma,\mu) and a family of mappings A=(A^{\omega})_{\omega\in\Omega} , where each A^{\omega} is a deterministic approximation algorithm for fixed \omega\in\Omega . In the randomized setting, a common error measure is the worst-case root-mean-squared error, also referred to as the randomized error , defined by \displaystyle\mathrm{err}^{\mathrm{ran}}(\mathcal{H}_{d,\alpha,\boldsymbol{\gamma}},L_{2},(A^{\omega})):=\sup_{\begin{subarray}{c}f\in\mathcal{H}_{d,\alpha,\boldsymbol{\gamma}}\\ \left\|f\right\|_{d,\alpha,\boldsymbol{\gamma}}\leq 1\end{subarray}}\left(\mathbb{E}_{\omega}\left[\|f-A^{\omega}(f)\|^{2}_{L_{2}}\right]\right)^{1/2}. (2) Alternatively, one can consider the (\epsilon,\delta) -approximation framework, see for instance [ 15 ] , which asks for which pairs (\epsilon,\delta) the algorithm satisfies \displaystyle\mathrm{Pr}_{\omega}\left[\|f-A^{\omega}(f)\|_{L_{2}}>\epsilon\right]\leq\delta\qquad\text{for all $f$ with $\left\|f\right\|_{d,\alpha,\boldsymbol{\gamma}}\leq 1$.} (3) Our main result (see Corollary 12 below) states that, with high probability, a median-based lattice algorithm can achieve an error bound of order M^{-\alpha+\varepsilon} for individual functions in \mathcal{H}_{d,\alpha,\boldsymbol{\gamma}} , where M denotes the total number of function evaluations used in A (see Section 3 for the precise definition). This is equivalent to saying that our proposed algorithm satisfies the (\epsilon,\delta) -approximation framework ( 3 ) with small \delta and \epsilon=\mathcal{O}(M^{-\alpha+\varepsilon}) for arbitrarily small \varepsilon . This result, in turn, leads to an almost optimal rate of the randomized L_{2} -approximation error (see Section 6 ). The algorithm is based on rank-1 lattice rules, introduced in the next subsection, and uses R randomized instances of such rules, each with N nodes. Thus, the total cost is M=RN . 2.3 Rank-1 lattice rules Let us now introduce rank-1 lattice rules, which are a key building block of our median algorithm. For simplicity, we assume in the following that N is a prime number. Let \boldsymbol{z}=(z_{1},\ldots,z_{d}) be a vector with each component in \{1{:}(N-1)\} . Using this vector, we define a lattice point set \mathcal{P}_{N}=\{\boldsymbol{x}_{0},\ldots,\boldsymbol{x}_{N-1}\} as follows: for each j\in\{1{:}d\} and k\in\{0,\ldots,N-1\} , the j -th component of the k -th point \boldsymbol{x}_{k} is given by x_{j}^{(k)}:=\left\{\frac{kz_{j}}{N}\right\}, where \{y\}=y-\lfloor y\rfloor denotes the fractional part of a non-negative real number y . By repeating the above procedure for all j\in\{1{:}d\} and k\in\{0,\ldots,N-1\} , we obtain the full lattice point set \mathcal{P}_{N} . A QMC rule using \mathcal{P}_{N} is called a rank-1 lattice rule. Note that, for fixed N and d , a lattice rule is fully characterized by the choice of the generating vector \boldsymbol{z} . However, not all choices of \boldsymbol{z} lead to lattice rules of sufficient quality for integration or approximation purposes. Fortunately, there exist fast construction algorithms that provide good generating vectors for given N , d , \alpha , and \boldsymbol{\gamma} . For comprehensive overviews of the theory of lattice rules, we refer to the books [ 5 , 24 ] , and in particular to ( 5 , Chapters 3 and 4) for details on the construction of good lattice rules. In this paper, however, we employ a randomized approach, in which the generating vectors \boldsymbol{z} are chosen at random to generate the lattice point sets. Hence, we do not need to be concerned with construction algorithms. It is sometimes useful, and we shall also adopt this approach here, to introduce an additional random element when applying lattice rules. This is commonly achieved by a random shift \Delta\in[0,1)^{d} . Given a lattice point set \mathcal{P}_{N}=\{\boldsymbol{x}_{0},\ldots,\boldsymbol{x}_{N-1}\} and drawing \boldsymbol{\Delta} from the uniform distribution over [0,1)^{d} , the corresponding randomly shifted lattice rule applied to a function g is given by Q_{N,d,\boldsymbol{\Delta}}(g):=\frac{1}{N}\sum_{k=0}^{N-1}g\left(\left\{\boldsymbol{x}_{k}+\boldsymbol{\Delta}\right\}\right), i.e., all points of \mathcal{P}_{N} are shifted modulo one by the same \boldsymbol{\Delta} . Here, the operation \{\cdot\} is applied component-wise to a vector. If we wish to emphasize the role of the generating vector \boldsymbol{z} of \mathcal{P}_{N} , we will write Q_{N,d,\boldsymbol{z},\boldsymbol{\Delta}} instead. 3 The median algorithm and its error In this section, we introduce our median lattice-based algorithm and analyze its L_{2} -approximation error. 3.1 Median lattice-based algorithm We assume product weights \boldsymbol{\gamma} with \gamma_{j}\in(0,1] for all j\geq 1 , and a smoothness parameter \alpha>1/2 . These parameters are assumed fixed but otherwise arbitrary. For a real L\geq 1 , we define \mathcal{A}_{d}(L):=\left\{\boldsymbol{h}\in\mathbb{Z}^{d}:r_{2\alpha,\boldsymbol{\gamma}}(\boldsymbol{h})\leq L^{2\alpha}\right\}=\left\{\boldsymbol{h}\in\mathbb{Z}^{d}:r_{1,\boldsymbol{\gamma}^{1/(2\alpha)}}(\boldsymbol{h})\leq L\right\}. Additionally, for R\in\mathbb{N} , we define the median of the complex numbers Z_{1},\dots,Z_{R} as \mathrm{median}_{r\in\{1{:}R\}}(Z_{r})=\mathrm{median}_{r\in\{1{:}R\}}\Re(Z_{r})+\mathtt{i}\cdot\mathrm{median}_{r\in\{1{:}R\}}\Im(Z_{r}). When R is odd, the median of R real numbers is uniquely defined, ensuring that the above definition is well-defined. Although the case with even R can be analyzed in a similar manner, we assume in the following that R is an odd integer. Moreover, we will assume that N is a prime number. While this assumption is not strictly necessary for all results below, it simplifies certain aspects of the analysis and will be adopted henceforth. We now introduce the median lattice-based algorithm for L_{2} -approximation in the weighted Korobov space \mathcal{H}_{d,\alpha,\boldsymbol{\gamma}} . Algorithm 1 . Let \alpha>1/2 and d\in\mathbb{N} , and let \gamma_{j}\in(0,1] for j=1,\ldots,d . Given an odd number of repetitions R\in\mathbb{N} , a parameter \tau>0 , and a prime number N , do the following: 1. Define P_{N}(\tau,d,\boldsymbol{\gamma}):=\prod_{j=1}^{d}\left(1+2\gamma_{j}^{1/(2\alpha)}(1+\tau\log N)\right), (4) and N_{*}:=\frac{N-1}{\exp(\tau^{-1})P_{N}(\tau,d,\boldsymbol{\gamma})}. (5) 2. For r from 1 to R , do the following: (a) Randomly draw \boldsymbol{z}_{r} from the uniform distribution over the set \{1{:}(N-1)\}^{d} . (b) Randomly draw \boldsymbol{\Delta}_{r} from the uniform distribution over [0,1)^{d} . (c) For all \boldsymbol{h}\in\mathcal{A}_{d}(N_{*}) , set \widehat{f}_{N,\boldsymbol{z}_{r},\boldsymbol{\Delta}_{r}}(\boldsymbol{h}):=\frac{1}{N}\sum_{k=0}^{N-1}f\left(\left\{\frac{k\boldsymbol{z}_{r}}{N}+\boldsymbol{\Delta}_{r}\right\}\right)\exp\left(-2\pi\mathtt{i}\boldsymbol{h}\cdot\left(\frac{k\boldsymbol{z}_{r}}{N}+\boldsymbol{\Delta}_{r}\right)\right). end for 3. For all \boldsymbol{h}\in\mathcal{A}_{d}(N_{*}) , define the aggregation \widehat{f}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}}}(\boldsymbol{h}):=\mathrm{median}_{r\in\{1{:}R\}}\Big(\widehat{f}_{N,\boldsymbol{z}_{r},\boldsymbol{\Delta}_{r}}(\boldsymbol{h})\Big), where \boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}} denote the collections of \boldsymbol{z}_{r} and \boldsymbol{\Delta}_{r} , for r\in\{1{:}R\} , respectively. Define the final approximation by (A^{\mathrm{rand}}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}},\mathcal{A}_{d}(N_{*})}(f))(\boldsymbol{x}):=\sum_{\boldsymbol{h}\in\mathcal{A}_{d}(N_{*})}\widehat{f}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}}}(\boldsymbol{h})\exp(2\pi\mathtt{i}\boldsymbol{h}\cdot\boldsymbol{x}), Before proceeding to the error analysis, we summarize some remarks concerning the algorithm. Remark 2 . Note that for computing \widehat{f}_{N,\boldsymbol{z}_{r},\boldsymbol{\Delta}_{r}}(\boldsymbol{h}) , the function evaluations required of f do not depend on \boldsymbol{h} . Thus, a total of RN evaluations of f are required to run Algorithm 1 . Furthermore, due to the independence between different repetitions r , the second step of Algorithm 1 can be performed in parallel. Remark 3 . The use of the median aggregation over R independent estimators mitigates the impact of outliers caused by unfavorable choices of generating vectors \boldsymbol{z}_{r} or shifts \boldsymbol{\Delta}_{r} . This approach follows the same principle as the median trick used in recent works on numerical integration [ 6 , 7 , 22 , 23 ] . A key distinction from [ 6 ] is that our approximation algorithm requires the input of the parameter \alpha and the weights \gamma_{j} , which are necessary for defining the index set \mathcal{A}_{d}(N_{*}) . Specifically, the quantity N_{*} is defined in ( 5 ), controlling the trade-off between truncation error and the error arising from the estimation of Fourier coefficients. Making the algorithm universal, i.e., applicable without specifying these parameters, will be explored in a subsequent work. Remark 4 . For an implementation of Algorithm 1 , Remark 11 specifies the requirements on N and R for the algorithm to succeed with 1-\delta probability, given \tau>0 and \delta\in(0,1) . Remark 16 provides further guidance on selecting the parameter \tau when there is a budget limit on the total number of function evaluations, i.e., when RN\leq M_{\max} . 3.2 Error analysis To prove our main result, we begin by presenting several lemmas. The first lemma improves upon Lemma 1 from [ 16 ] concerning the cardinality of the hyperbolic cross \mathcal{A}_{d}(L) . The subsequent corollary applies this result to bound the size of the index set \mathcal{A}_{d}(N_{*}) used in Algorithm 1 . Lemma 5 . For L\geq 1 , we have |\mathcal{A}_{d}(L)|\leq 1+\inf_{q>1}\frac{L^{q}}{\zeta(q)}\prod_{j=1}^{d}\Big(1+2\gamma^{q/(2\alpha)}_{j}\zeta(q)\Big), (6) where \zeta(q):=\sum_{n=1}^{\infty}n^{-q} is the Riemann zeta function. We further have, for any \tau>0 , |\mathcal{A}_{d}(L)|\leq 1+\frac{L\exp(\tau^{-1})}{1+\tau\log{L}}P_{L}(\tau,d,\boldsymbol{\gamma}), (7) where P_{L}(\tau,d,\boldsymbol{\gamma}) is defined as in ( 4 ), but with N\in\mathbb{N} replaced by L . Proof. For K\geq 0 , define \mathcal{A}^{*}_{d}(K):=\left\{\boldsymbol{h}\in\mathbb{N}^{d}:\prod_{j=1}^{d}h_{j}\leq K\right\}. Observe that \displaystyle\mathcal{A}_{d}(L) \displaystyle=\bigcup_{u\subseteq\{1{:}d\}}\left\{\boldsymbol{h}\in\mathbb{Z}^{d}\,\colon\,r_{1,\boldsymbol{\gamma}^{1/(2\alpha)}}(\boldsymbol{h})\leq L,h_{j}=0\text{ if and only if }j\notin u\right\} \displaystyle=\bigcup_{u\subseteq\{1{:}d\}}\left\{\boldsymbol{h}\in\mathbb{Z}^{d}\,\colon\,\prod_{j\in u}|h_{j}|\leq L\,\prod_{j\in u}\gamma_{j}^{1/(2\alpha)},h_{j}=0\text{ if and only if }j\notin u\right\}, where the second equality follows from the assumption 1\geq\gamma_{1}\geq\gamma_{2}\geq\cdots . Thus, we have |\mathcal{A}_{d}(L)|=1+\sum_{\begin{subarray}{c}u\subseteq\{1{:}d\}\\ u\neq\emptyset\end{subarray}}2^{|u|}\Big|\mathcal{A}^{*}_{|u|}\Big(L\,\prod_{j\in u}\gamma_{j}^{1/(2\alpha)}\Big)\Big|. (8) It suffices to bound |\mathcal{A}^{*}_{d}(K)| . When d=1 , |\mathcal{A}^{*}_{d}(K)|=\lfloor K\rfloor\leq K . For d\geq 2 , note that, given the values of h_{1},\dots,h_{d-1} , there are \Big\lfloor\Big(\prod_{j=1}^{d-1}h_{j}\Big)^{-1}K\Big\rfloor choices for h_{d} . Therefore, when K\geq 1 , \displaystyle|\mathcal{A}^{*}_{d}(K)| \displaystyle=\sum_{h_{1}=1}^{\infty}\dots\sum_{h_{d-1}=1}^{\infty}\left\lfloor\left(\prod_{j=1}^{d-1}h_{j}\right)^{-1}K\right\rfloor \displaystyle\leq\inf_{q\geq 1}K^{q}\sum_{h_{1}=1}^{\infty}\dots\sum_{h_{d-1}=1}^{\infty}\left(\prod_{j=1}^{d-1}h_{j}\right)^{-q}\,\boldsymbol{1}\left\{\prod_{j=1}^{d-1}h_{j}\leq K\right\} \displaystyle\leq\inf_{q\geq 1}K^{q}\prod_{j=1}^{d-1}\left(\sum_{h_{j}=1}^{\infty}h_{j}^{-q}\,\boldsymbol{1}\{h_{j}\leq K\}\right) (9) \displaystyle\leq\inf_{q>1}K^{q}\zeta(q)^{d-1}, where \boldsymbol{1}A denotes the indicator function of a set A . Substituting the above bound into ( 8 ), we obtain \displaystyle|\mathcal{A}_{d}(L)|-1 \displaystyle\leq\inf_{q>1}\sum_{\begin{subarray}{c}u\subseteq\{1{:}d\}\\ u\neq\emptyset\end{subarray}}2^{|u|}\left(\prod_{j\in u}\gamma_{j}\right)^{q/(2\alpha)}L^{q}\zeta(q)^{|u|-1}\boldsymbol{1}\left\{L\prod_{j\in u}\gamma_{j}^{1/(2\alpha)}\geq 1\right\} (10) \displaystyle\leq\inf_{q>1}\frac{L^{q}}{\zeta(q)}\sum_{\begin{subarray}{c}u\subseteq\{1{:}d\}\\ u\neq\emptyset\end{subarray}}2^{|u|}\zeta(q)^{|u|}\prod_{j\in u}\gamma_{j}^{q/(2\alpha)} \displaystyle\leq\inf_{q>1}\frac{L^{q}}{\zeta(q)}\prod_{j=1}^{d}\Big(1+2\gamma^{q/(2\alpha)}_{j}\zeta(q)\Big). This completes the proof of ( 6 ). Next, for \tau>0 , we set q:=1+\frac{1}{\tau\log L} in the infimum above to get an upper bound. It follows that L^{q}=\exp\left(\log L+\log L\frac{1}{\tau\log L}\right)=L\exp(\tau^{-1}). Meanwhile, since \sum_{n=1}^{\infty}\frac{1}{n^{q}}\leq 1+\int_{1}^{\infty}\frac{1}{x^{q}}dx, we obtain the bound \zeta(q)\leq 1+\frac{1}{q-1}=1+\tau\log L. Using this estimate and \sup_{j\in\{1{:}d\}}\gamma_{j}\leq 1 , we can derive from ( 10 ) that \displaystyle|\mathcal{A}_{d}(L)|-1 \displaystyle\leq L^{q}\sum_{\begin{subarray}{c}u\subseteq\{1{:}d\}\\ u\neq\emptyset\end{subarray}}2^{|u|}\zeta(q)^{|u|-1}\prod_{j\in u}\gamma_{j}^{q/(2\alpha)} \displaystyle\leq L\exp(\tau^{-1})\sum_{\begin{subarray}{c}u\subseteq\{1{:}d\}\\ u\neq\emptyset\end{subarray}}2^{|u|}(1+\tau\log L)^{|u|-1}\prod_{j\in u}\gamma_{j}^{1/(2\alpha)} \displaystyle=\frac{L\exp(\tau^{-1})}{1+\tau\log L}\sum_{\begin{subarray}{c}u\subseteq\{1{:}d\}\\ u\neq\emptyset\end{subarray}}2^{|u|}(1+\tau\log L)^{|u|}\prod_{j\in u}\gamma_{j}^{1/(2\alpha)} \displaystyle\leq\frac{L\exp(\tau^{-1})}{1+\tau\log L}\prod_{j=1}^{d}\Big(1+2\gamma^{1/(2\alpha)}_{j}(1+\tau\log L)\Big) \displaystyle=\frac{L\exp(\tau^{-1})}{1+\tau\log L}P_{L}(\tau,d,\boldsymbol{\gamma}). This completes the proof of ( 7 ). ∎ Corollary 6 . Let \tau>0 . Suppose that N is a prime number and let N_{*} be defined as in ( 5 ). Then, whenever N_{*}\geq 1 , it holds that |\mathcal{A}_{d}(N_{*})|\leq 1+\frac{N-1}{1+\tau\log N_{*}}. Proof. By the bound in ( 7 ), we have \displaystyle|\mathcal{A}_{d}(N_{*})| \displaystyle\leq 1+\frac{N_{*}\exp(\tau^{-1})}{1+\tau\log N_{*}}P_{N_{*}}(\tau,d,\boldsymbol{\gamma}) \displaystyle=1+\frac{N-1}{1+\tau\log N_{*}}\frac{P_{N_{*}}(\tau,d,\boldsymbol{\gamma})}{P_{N}(\tau,d,\boldsymbol{\gamma})} \displaystyle\leq 1+\frac{N-1}{1+\tau\log N_{*}}, where the last inequality uses the facts that N_{*}\leq N and that P_{N}(\tau,d,\boldsymbol{\gamma}) is increasing in N . ∎ Note that the condition N_{*}\geq 1 is precisely equivalent to N\geq P_{N}(\tau,d,\boldsymbol{\gamma})\exp{(\tau^{-1})}+1. (11) Remark 7 . The bound ( 6 ) can be improved by defining the partial sum H_{N}(q):=\sum_{n=1}^{N}n^{-q} and applying the estimate |\mathcal{A}^{*}_{d}(K)|\leq\inf_{q\geq 1}K^{q}H_{\lfloor K\rfloor}(q)^{d-1} from ( 9 ). Although we omit the derivation details, it follows from this estimate (under the assumption \sup_{j\in\{1{:}d\}}\gamma_{j}\leq 1 ) that \displaystyle|\mathcal{A}_{d}(L)|-1\leq\inf_{q\geq 1}\frac{L^{q}}{H_{L}(q)}\prod_{j=1}^{d}\Big(1+2\gamma^{q/(2\alpha)}_{j}H_{L}(q)\Big). (12) The minimization in ( 12 ) can be carried out by solving for the zero of the logarithmic derivative of the right-hand side of ( 12 ), i.e., \log L-\frac{H^{\prime}_{L}(q)}{H_{L}(q)}+\sum_{j=1}^{d}\frac{\alpha^{-1}\log(\gamma_{j})\gamma^{q/(2\alpha)}_{j}H_{L}(q)+2\gamma^{q/(2\alpha)}_{j}H^{\prime}_{L}(q)}{1+2\gamma^{q/(2\alpha)}_{j}H_{L}(q)}=0. Introducing the shorthand w_{j}(q)=\frac{2\gamma^{q/(2\alpha)}_{j}H_{L}(q)}{1+2\gamma^{q/(2\alpha)}_{j}H_{L}(q)}, this equation becomes -\frac{H^{\prime}_{L}(q)}{H_{L}(q)}\left(\sum_{j=1}^{d}w_{j}(q)-1\right)-\frac{1}{2\alpha}\sum_{j=1}^{d}w_{j}(q)\log(\gamma_{j})=\log L. (13) Note that H^{\prime}_{L}(q)<0 for all q\geq 1 , and \displaystyle\left(\frac{H^{\prime}_{L}(q)}{H_{L}(q)}\right)^{\prime} \displaystyle=\frac{H^{\prime\prime}_{L}(q)H_{L}(q)-\left(H^{\prime}_{L}(q)\right)^{2}}{H_{L}(q)^{2}} \displaystyle=\frac{1}{H_{L}(q)^{2}}\left(\sum_{n=1}^{L}\frac{(\log n)^{2}}{n^{q}}\sum_{n=1}^{L}\frac{1}{n^{q}}-\left(\sum_{n=1}^{L}\frac{\log n}{n^{q}}\right)^{2}\right)>0. Hence, -H^{\prime}_{L}(q)/H_{L}(q) is positive and strictly decreasing for q\geq 1 . Furthermore, each w_{j}(q) is strictly decreasing in q , and since \log(\gamma_{j})\leq 0 , the entire left-hand side of ( 13 ) is strictly decreasing over [1,\overline{q}] , where \overline{q} satisfies \sum_{j=1}^{d}w_{j}(\overline{q})=1 . For the univariate case d=1 , the global minimizer is q=1 as long as \gamma^{1/2\alpha}_{1}L>1 . When d\geq 2 , the minimizer over [1,\overline{q}] becomes the global minimizer for sufficiently large L . To show this, observe \lim_{q\to 1^{+}}\lim_{L\to\infty}\sum_{j=1}^{d}w_{j}(q)=\lim_{q\to 1^{+}}\sum_{j=1}^{d}\frac{2\gamma^{q/(2\alpha)}_{j}\zeta(q)}{1+2\gamma^{q/(2\alpha)}_{j}\zeta(q)}=d>1. Hence for sufficiently small \tau>0 , there exists L_{\tau}\geq 1 such that \sum_{j=1}^{d}w_{j}(1+\tau)\geq 1 for L\geq L_{\tau} . Using the estimate H_{L}(1)\leq 1+\log L , we find \inf_{q\geq 1+\tau}\frac{L^{q}}{H_{L}(q)}\prod_{j=1}^{d}\left(1+2\gamma^{q/(2\alpha)}_{j}H_{L}(q)\right)\geq\frac{L^{1+\tau}}{H_{L}(1)}\geq\frac{L^{1+\tau}}{1+\log L}. On the other hand, for q=1+\tau/2 , \frac{L^{q}}{H_{L}(q)}\prod_{j=1}^{d}\left(1+2\gamma^{q/(2\alpha)}_{j}H_{L}(q)\right)\leq L^{1+\tau/2}\prod_{j=1}^{d}\left(1+2\gamma^{1/(2\alpha)}_{j}(1+\log L)\right), which grows at a strictly slower rate than L^{1+\tau}/(1+\log L) as L\to\infty . Therefore, the global minimizer lies in [1,1+\tau]\subset[1,\overline{q}] for large enough L . Although we rely on the bound ( 7 ) for the subsequent analysis, one could alternatively use the improved bound ( 12 ) by choosing q as the minimizer over [1,\overline{q}] . This minimization is numerically straightforward due to the monotonicity of the logarithmic derivative in ( 13 ). Let us proceed with our error analysis. To simplify notation, for a given f\in\mathcal{H}_{d,\alpha,\boldsymbol{\gamma}} , parameter \tau>0 , and a prime number N , we write \epsilon(\boldsymbol{h}):=\left((\tau^{-1}+\log N_{*})\left(\frac{\|f\|^{2}_{d,\alpha,\boldsymbol{\gamma}}}{N_{*}^{2\alpha}(N-1)}+\sum_{\boldsymbol{\ell}\in N\cdot\mathbb{Z}^{d}\setminus\{\boldsymbol{0}\}}|\widehat{f}(\boldsymbol{\ell}+\boldsymbol{h})|^{2}\right)\right)^{1/2}, for \boldsymbol{h}\in\mathbb{Z}^{d} , where N\cdot\mathbb{Z}^{d}=\{\boldsymbol{\ell}\in\mathbb{Z}^{d}:\ell_{j}\equiv 0{\;(\text{mod}\;N)}\text{ for all }j\in\{1{:}d\}\} . The following lemma establishes that, with some probability, each independent trial for estimating the Fourier coefficients corresponding to indices in the set \mathcal{A}_{d}(N_{*}) , i.e., \widehat{f}_{N,\boldsymbol{z}_{r},\boldsymbol{\Delta}_{r}}(\boldsymbol{h}) , for r\in\{1{:}R\} , yields a good approximation with the error bounded by \epsilon(\boldsymbol{h}) . Lemma 8 . Let f\in\mathcal{H}_{d,\alpha,\boldsymbol{\gamma}} , \tau>0 , and let N be prime such that N_{*}\geq 1 . Using the notation introduced above, for any \boldsymbol{h}\in\mathcal{A}_{d}(N_{*}) and any r\in\{1{:}R\} , we have \Pr\Big(|\widehat{f}_{N,\boldsymbol{z}_{r},\boldsymbol{\Delta}_{r}}(\boldsymbol{h})-\widehat{f}(\boldsymbol{h})|^{2}>\epsilon(\boldsymbol{h})^{2}\Big)\leq\frac{1+\tau}{1+\tau\log N_{*}}. Proof. Fix \boldsymbol{h}\in\mathcal{A}_{d}(N_{*}) and r\in\{1{:}R\} . Furthermore, we define P_{N,\boldsymbol{z}_{r}}^{\perp}:=\{\boldsymbol{\ell}\in\mathbb{Z}^{d}:\boldsymbol{z}^{T}_{r}\cdot\boldsymbol{\ell}\equiv 0{\;(\text{mod}\;N)}\}. Note that N\cdot\mathbb{Z}^{d}\subset P_{N,\boldsymbol{z}_{r}}^{\perp} holds for any N and \boldsymbol{z}_{r} . Then, as outlined, for example, in ( 2 , Proof of Lemma 4.1) , we have \displaystyle\int_{[0,1]^{d}}|\widehat{f}_{N,\boldsymbol{z}_{r},\boldsymbol{\Delta}_{r}}(\boldsymbol{h})-\widehat{f}(\boldsymbol{h})|^{2}\,\mathrm{d}\boldsymbol{\Delta}_{r} \displaystyle=\int_{[0,1]^{d}}\left|\sum_{\boldsymbol{\ell}\in P_{N,\boldsymbol{z}_{r}}^{\perp}\setminus\{\boldsymbol{0}\}}\widehat{f}(\boldsymbol{\ell}+\boldsymbol{h})\exp(2\pi\mathtt{i}\boldsymbol{\ell}\cdot\boldsymbol{\Delta}_{r})\right|^{2}\,\mathrm{d}\boldsymbol{\Delta}_{r} \displaystyle=\sum_{\boldsymbol{\ell}\in P_{N,\boldsymbol{z}_{r}}^{\perp}\setminus\{\boldsymbol{0}\}}|\widehat{f}(\boldsymbol{\ell}+\boldsymbol{h})|^{2}. (14) Moreover, for each \boldsymbol{\ell}\in\mathbb{Z}^{d}\setminus(N\cdot\mathbb{Z}^{d}) , we denote by V_{\boldsymbol{\ell}} the event \boldsymbol{\ell}\in P_{N,\boldsymbol{z}_{r}}^{\perp} . Then, it follows from, for instance, ( 14 , Lemma 4) that \Pr(V_{\boldsymbol{\ell}})=\Pr(\boldsymbol{z}^{T}_{r}\cdot\boldsymbol{\ell}\equiv 0{\;(\text{mod}\;N)})\leq\frac{1}{N-1}. We now define \mathcal{B}_{\boldsymbol{h}}=\left\{\boldsymbol{\ell}\in\mathbb{Z}^{d}\setminus(N\cdot\mathbb{Z}^{d})\,\colon\,r_{2\alpha,\boldsymbol{\gamma}}(\boldsymbol{h}+\boldsymbol{\ell})\leq N_{*}^{2\alpha}\right\}. Then, by Corollary 6 , we have \displaystyle|\mathcal{B}_{\boldsymbol{h}}| \displaystyle=\left|\left\{\boldsymbol{\ell}\in\mathbb{Z}^{d}\setminus(N\cdot\mathbb{Z}^{d})\,\colon\,r_{2\alpha,\boldsymbol{\gamma}}(\boldsymbol{h}+\boldsymbol{\ell})\leq N_{*}^{2\alpha}\right\}\right| \displaystyle\leq\left|\left\{\boldsymbol{\ell}\in\mathbb{Z}^{d}\setminus\{\boldsymbol{0}\}\,\colon\,r_{2\alpha,\boldsymbol{\gamma}}(\boldsymbol{h}+\boldsymbol{\ell})\leq N_{*}^{2\alpha}\right\}\right| \displaystyle=\left|\left\{\boldsymbol{\ell}\in\mathbb{Z}^{d}\setminus\{\boldsymbol{h}\}\,\colon\,r_{2\alpha,\boldsymbol{\gamma}}(\boldsymbol{\ell})\leq N_{*}^{2\alpha}\right\}\right| \displaystyle\leq\frac{N-1}{1+\tau\log N_{*}}, where we have used the fact that r_{2\alpha,\boldsymbol{\gamma}}(\boldsymbol{h})\leq N_{*}^{2\alpha} for \boldsymbol{h}\in\mathcal{A}_{d}(N_{*}) . Therefore, the union bound argument shows \displaystyle\Pr(P_{N,\boldsymbol{z}_{r}}^{\perp}\cap\mathcal{B}_{\boldsymbol{h}}\neq\emptyset) \displaystyle=\Pr\left(\bigcup_{\boldsymbol{\ell}\in\mathcal{B}_{\boldsymbol{h}}}V_{\boldsymbol{\ell}}\right) \displaystyle\leq\sum_{\boldsymbol{\ell}\in\mathcal{B}_{\boldsymbol{h}}}\Pr(V_{\boldsymbol{\ell}}) \displaystyle\leq\frac{N-1}{1+\tau\log N_{*}}\cdot\frac{1}{N-1} \displaystyle=\frac{1}{1+\tau\log N_{*}}. (15) Now we apply Markov’s inequality to obtain \displaystyle\Pr\Big(|\widehat{f}_{N,\boldsymbol{z}_{r},\boldsymbol{\Delta}_{r}}(\boldsymbol{h})-\widehat{f}(\boldsymbol{h})|^{2}>\epsilon(\boldsymbol{h})^{2}\Big) \displaystyle=\Pr\Big(\{|\widehat{f}_{N,\boldsymbol{z}_{r},\boldsymbol{\Delta}_{r}}(\boldsymbol{h})-\widehat{f}(\boldsymbol{h})|^{2}>\epsilon(\boldsymbol{h})^{2}\}\cap\{P_{N,\boldsymbol{z}_{r}}^{\perp}\cap\mathcal{B}_{\boldsymbol{h}}\neq\emptyset\}\Big) \displaystyle\quad+\Pr\Big(\{|\widehat{f}_{N,\boldsymbol{z}_{r},\boldsymbol{\Delta}_{r}}(\boldsymbol{h})-\widehat{f}(\boldsymbol{h})|^{2}>\epsilon(\boldsymbol{h})^{2}\}\cap\{P_{N,\boldsymbol{z}_{r}}^{\perp}\cap\mathcal{B}_{\boldsymbol{h}}=\emptyset\}\Big) \displaystyle\leq\Pr(P_{N,\boldsymbol{z}_{r}}^{\perp}\cap\mathcal{B}_{\boldsymbol{h}}\neq\emptyset) \displaystyle\quad+\Pr\Big(\{\epsilon(\boldsymbol{h})^{-2}|\widehat{f}_{N,\boldsymbol{z}_{r},\boldsymbol{\Delta}_{r}}(\boldsymbol{h})-\widehat{f}(\boldsymbol{h})|^{2}>1\}\cap\{\boldsymbol{1}\{P_{N,\boldsymbol{z}_{r}}^{\perp}\cap\mathcal{B}_{\boldsymbol{h}}=\emptyset\}=1\}\Big) \displaystyle\leq\Pr(P_{N,\boldsymbol{z}_{r}}^{\perp}\cap\mathcal{B}_{\boldsymbol{h}}\neq\emptyset) \displaystyle\quad+\Pr\Big(\epsilon(\boldsymbol{h})^{-2}|\widehat{f}_{N,\boldsymbol{z}_{r},\boldsymbol{\Delta}_{r}}(\boldsymbol{h})-\widehat{f}(\boldsymbol{h})|^{2}\boldsymbol{1}\{P_{N,\boldsymbol{z}_{r}}^{\perp}\cap\mathcal{B}_{\boldsymbol{h}}=\emptyset\}>1\Big) \displaystyle\leq\frac{1}{1+\tau\log N_{*}}+\frac{1}{\epsilon(\boldsymbol{h})^{2}}\mathbb{E}\Big[|\widehat{f}_{N,\boldsymbol{z}_{r},\boldsymbol{\Delta}_{r}}(\boldsymbol{h})-\widehat{f}(\boldsymbol{h})|^{2}\boldsymbol{1}\{P_{N,\boldsymbol{z}_{r}}^{\perp}\cap\mathcal{B}_{\boldsymbol{h}}=\emptyset\}\Big]. (16) Here, the probability \Pr and expectation \mathbb{E} are taken over the random choices of \boldsymbol{z}_{r} and \boldsymbol{\Delta}_{r} . From the equality ( 14 ), the inclusion N\cdot\mathbb{Z}^{d}\subset P_{N,\boldsymbol{z}_{r}}^{\perp} , and the fact that \boldsymbol{\Delta}_{r} is independent of \boldsymbol{z}_{r} , we have \displaystyle\mathbb{E}\Big[|\widehat{f}_{N,\boldsymbol{z}_{r},\boldsymbol{\Delta}_{r}}(\boldsymbol{h})-\widehat{f}(\boldsymbol{h})|^{2}\boldsymbol{1}\{P_{N,\boldsymbol{z}_{r}}^{\perp}\cap\mathcal{B}_{\boldsymbol{h}}=\emptyset\}\Big] \displaystyle=\frac{1}{(N-1)^{d}}\sum_{\boldsymbol{z}_{r}\in\{1{:}(N-1)\}^{d}}\sum_{\boldsymbol{\ell}\in P_{N,\boldsymbol{z}_{r}}^{\perp}\setminus\{\boldsymbol{0}\}}|\widehat{f}(\boldsymbol{\ell}+\boldsymbol{h})|^{2}\boldsymbol{1}\{P_{N,\boldsymbol{z}_{r}}^{\perp}\cap\mathcal{B}_{\boldsymbol{h}}=\emptyset\} \displaystyle\leq\frac{1}{(N-1)^{d}}\sum_{\boldsymbol{z}_{r}\in\{1{:}(N-1)\}^{d}}\sum_{\boldsymbol{\ell}\in P_{N,\boldsymbol{z}_{r}}^{\perp}\setminus(N\cdot\mathbb{Z}^{d})}|\widehat{f}(\boldsymbol{\ell}+\boldsymbol{h})|^{2}\frac{r_{2\alpha,\boldsymbol{\gamma}}(\boldsymbol{h}+\boldsymbol{\ell})}{N_{*}^{2\alpha}} \displaystyle\quad+\frac{1}{(N-1)^{d}}\sum_{\boldsymbol{z}_{r}\in\{1{:}(N-1)\}^{d}}\sum_{\boldsymbol{\ell}\in N\cdot\mathbb{Z}^{d}\setminus\{\boldsymbol{0}\}}|\widehat{f}(\boldsymbol{\ell}+\boldsymbol{h})|^{2} \displaystyle=\sum_{\boldsymbol{\ell}\in\mathbb{Z}^{d}\setminus(N\cdot\mathbb{Z}^{d})}|\widehat{f}(\boldsymbol{\ell}+\boldsymbol{h})|^{2}\frac{r_{2\alpha,\boldsymbol{\gamma}}(\boldsymbol{h}+\boldsymbol{\ell})}{N_{*}^{2\alpha}}\left(\frac{1}{(N-1)^{d}}\sum_{\boldsymbol{z}_{r}\in\{1{:}(N-1)\}^{d}}\boldsymbol{1}\{\boldsymbol{\ell}\in P_{N,\boldsymbol{z}_{r}}^{\perp}\}\right) \displaystyle\quad+\sum_{\boldsymbol{\ell}\in N\cdot\mathbb{Z}^{d}\setminus\{\boldsymbol{0}\}}|\widehat{f}(\boldsymbol{\ell}+\boldsymbol{h})|^{2} \displaystyle=\frac{1}{N_{*}^{2\alpha}}\,\sum_{\boldsymbol{\ell}\in\mathbb{Z}^{d}\setminus(N\cdot\mathbb{Z}^{d})}|\widehat{f}(\boldsymbol{\ell}+\boldsymbol{h})|^{2}\,r_{2\alpha,\boldsymbol{\gamma}}(\boldsymbol{h}+\boldsymbol{\ell})\,\Pr(V_{\boldsymbol{\ell}})+\sum_{\boldsymbol{\ell}\in N\cdot\mathbb{Z}^{d}\setminus\{\boldsymbol{0}\}}|\widehat{f}(\boldsymbol{\ell}+\boldsymbol{h})|^{2} \displaystyle\leq\frac{\|f\|^{2}_{d,\alpha,\boldsymbol{\gamma}}}{N_{*}^{2\alpha}(N-1)}+\sum_{\boldsymbol{\ell}\in N\cdot\mathbb{Z}^{d}\setminus\{\boldsymbol{0}\}}|\widehat{f}(\boldsymbol{\ell}+\boldsymbol{h})|^{2}. The conclusion follows once we substitute the above upper bound into ( 16 ). ∎ The next lemma is about the probability amplification via the median trick. That is, in the previous lemma, we showed that each individual estimate is accurate with some probability. By applying the median trick to the aggregate estimate \widehat{f}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}}}(\boldsymbol{h}) , we can enhance the overall success probability as the number of repetitions R grows. Lemma 9 . Let f\in\mathcal{H}_{d,\alpha,\boldsymbol{\gamma}} , \tau>0 , and let N be prime such that N_{*}\geq 1 . Suppose that R is an odd number. Then, for any \boldsymbol{h}\in\mathcal{A}_{d}(N_{*}) , we have \Pr\Big(|\widehat{f}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}}}(\boldsymbol{h})-\widehat{f}(\boldsymbol{h})|^{2}>2\epsilon(\boldsymbol{h})^{2}\Big)\leq\,\left(\frac{4(1+\tau)}{1+\tau\log N_{*}}\right)^{\lceil R/2\rceil}. Proof. By Lemma 8 , for each r\in\{1{:}R\} , we have \displaystyle\Pr\Big(|\Re\widehat{f}_{N,\boldsymbol{z}_{r},\boldsymbol{\Delta}_{r}}(\boldsymbol{h})-\Re\widehat{f}(\boldsymbol{h})|^{2}>\epsilon(\boldsymbol{h})^{2}\Big) \displaystyle\leq \displaystyle\frac{1+\tau}{1+\tau\log N_{*}}. In order for |\Re\widehat{f}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}}}(\boldsymbol{h})-\Re\widehat{f}(\boldsymbol{h})|^{2}>\epsilon(\boldsymbol{h})^{2} to hold, at least \lceil R/2\rceil instances of the R estimates must satisfy |\Re\widehat{f}_{N,\boldsymbol{z}_{r},\boldsymbol{\Delta}_{r}}(\boldsymbol{h})-\Re\widehat{f}(\boldsymbol{h})|^{2}>\epsilon(\boldsymbol{h})^{2} . There are at most 2^{R} distinct subsets of \{1{:}R\} , so we obtain \displaystyle\Pr\Big(|\Re\widehat{f}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}}}(\boldsymbol{h})-\Re\widehat{f}(\boldsymbol{h})|^{2}>\epsilon(\boldsymbol{h})^{2}\Big) \displaystyle\leq 2^{R}\,\left(\frac{1+\tau}{1+\tau\log N_{*}}\right)^{\lceil R/2\rceil} \displaystyle=\,\frac{1}{2}\left(\frac{4(1+\tau)}{1+\tau\log N_{*}}\right)^{\lceil R/2\rceil}, where we used the fact that R is odd in the last step. A similar bound holds for the imaginary part, and the conclusion follows by applying the union bound. ∎ We now arrive at the main theoretical result of this paper. Theorem 10 . Let \tau>0 and \delta\in(0,1) be given, and let N be a prime sufficiently large that 1\leq N_{*}2\epsilon(\boldsymbol{h})^{2}\text{ for at least one }\boldsymbol{h}\in\mathcal{A}_{d}(N_{*})\Big) \displaystyle\leq\sum_{\boldsymbol{h}\in\mathcal{A}_{d}(N_{*})}\Pr\Big(|\widehat{f}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}}}(\boldsymbol{h})-\widehat{f}(\boldsymbol{h})|^{2}>2\epsilon(\boldsymbol{h})^{2}\Big) \displaystyle\leq|\mathcal{A}_{d}(N_{*})|\,\,\left(\frac{4(1+\tau)}{1+\tau\log N_{*}}\right)^{\lceil R/2\rceil} \displaystyle\leq\Big(1+\frac{N-1}{1+\tau\log N_{*}}\Big)\left(\frac{4(1+\tau)}{1+\tau\log N_{*}}\right)^{\lceil R/2\rceil}\leq\delta. Therefore, the aggregated estimate satisfies |\widehat{f}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}}}(\boldsymbol{h})-\widehat{f}(\boldsymbol{h})|^{2}\leq 2\epsilon(\boldsymbol{h})^{2} simultaneously for all \boldsymbol{h}\in\mathcal{A}_{d}(N_{*}) , with probability at least 1-\delta . When this event occurs, by Parseval’s identity, we have \displaystyle\|f-A^{\mathrm{rand}}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}},\mathcal{A}_{d}(N_{*})}(f)\|^{2}_{L_{2}} \displaystyle=\sum_{\boldsymbol{h}\notin\mathcal{A}_{d}(N_{*})}|\widehat{f}(\boldsymbol{h})|^{2}+\sum_{\boldsymbol{h}\in\mathcal{A}_{d}(N_{*})}|\widehat{f}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}}}(\boldsymbol{h})-\widehat{f}(\boldsymbol{h})|^{2} \displaystyle\leq\sum_{\boldsymbol{h}\notin\mathcal{A}_{d}(N_{*})}|\widehat{f}(\boldsymbol{h})|^{2}+2\sum_{\boldsymbol{h}\in\mathcal{A}_{d}(N_{*})}\epsilon(\boldsymbol{h})^{2} \displaystyle\leq\sum_{\boldsymbol{h}\notin\mathcal{A}_{d}(N_{*})}|\widehat{f}(\boldsymbol{h})|^{2}+2|\mathcal{A}_{d}(N_{*})|\,\frac{\tau^{-1}+\log N_{*}}{N-1}\,\frac{\|f\|^{2}_{d,\alpha,\boldsymbol{\gamma}}}{N_{*}^{2\alpha}} \displaystyle\quad+2(\tau^{-1}+\log N_{*})\sum_{\boldsymbol{h}\in\mathcal{A}_{d}(N_{*})}\sum_{\boldsymbol{\ell}\in N\cdot\mathbb{Z}^{d}\setminus\{\boldsymbol{0}\}}|\widehat{f}(\boldsymbol{\ell}+\boldsymbol{h})|^{2}. Again, by Corollary 6 , it holds that |\mathcal{A}_{d}(N_{*})|\,\frac{\tau^{-1}+\log N_{*}}{N-1}\leq\frac{\tau^{-1}+\log N_{*}}{N-1}+\tau^{-1}. Since P_{N}(\tau,d,\boldsymbol{\gamma})\geq 1 and N_{*}=(N-1)/(P_{N}(\tau,d,\boldsymbol{\gamma})\exp{(\tau^{-1})}) , we have \tau^{-1}+\log N_{*}=\log(N-1)-\log(P_{N}(\tau,d,\boldsymbol{\gamma}))\leq\log(N-1). Finally, \boldsymbol{h}\in\mathcal{A}_{d}(N_{*}) implies \boldsymbol{h}\in(-N/2,N/2)^{d} when N_{*}0 and \delta\in(0,1) be given. Denote by M=RN the total number of evaluations of f required by the algorithm A^{\mathrm{rand}}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}},\mathcal{A}_{d}(N_{*})} . Then, there exist choices of a prime number N and an odd integer R such that for any f\in\mathcal{H}_{d,\alpha,\boldsymbol{\gamma}} , with probability at least 1-\delta , \displaystyle\|f-A^{\mathrm{rand}}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}},\mathcal{A}_{d}(N_{*})}(f)\|^{2}_{L_{2}}\leq C_{N}(\tau,\delta,\alpha)\,\frac{\|f\|^{2}_{d,\alpha,\boldsymbol{\gamma}}}{M^{2\alpha}}\exp(2\alpha\tau^{-1})\,(P_{N}(\tau,d,\boldsymbol{\gamma}))^{2\alpha}, where \displaystyle C_{N}(\tau,\delta,\alpha) \displaystyle=\left(\frac{N}{N-1}\right)^{2\alpha}\left(2\log\left(1+\frac{N-1}{4e}\right)+2\log(\delta^{-1})+1\right)^{2\alpha} \displaystyle\quad\times\left(2\tau^{-1}+1+\frac{2N}{N-1}\log(N-1)\right). Proof. Choose c:=\exp(-1) , and a prime N such that ( 19 ) holds for this choice of c . This is possible for sufficiently large N because P_{N}(\tau,d,\boldsymbol{\gamma}) depends only logarithmically on N . Furthermore, with c=\exp(-1) , ( 20 ) is certainly satisfied if we choose the odd integer R such that 2\log\left(1+\frac{N-1}{4e}\right)+2\log(\delta^{-1})-1\leq R\leq 2\log\left(1+\frac{N-1}{4e}\right)+2\log(\delta^{-1})+1. (21) Next, we apply Theorem 10 for these choices of N and R and obtain, with probability at least 1-\delta , \displaystyle\|f-A^{\mathrm{rand}}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}},\mathcal{A}_{d}(N_{*})}(f)\|^{2}_{L_{2}} \displaystyle\leq\frac{\|f\|^{2}_{d,\alpha,\boldsymbol{\gamma}}}{N^{2\alpha}_{*}}\Big(2\tau^{-1}+1+\frac{2N\log(N-1)}{N-1}\Big) \displaystyle\leq\frac{\|f\|^{2}_{d,\alpha,\boldsymbol{\gamma}}}{(N-1)^{2\alpha}}\,\Big(2\tau^{-1}+1+\frac{2N\log(N-1)}{N-1}\Big)\,\exp(2\alpha\tau^{-1})\,(P_{N}(\tau,d,\boldsymbol{\gamma}))^{2\alpha} \displaystyle=\left(\frac{RN}{N-1}\right)^{2\alpha}\frac{\|f\|^{2}_{d,\alpha,\boldsymbol{\gamma}}}{M^{2\alpha}}\,\Big(2\tau^{-1}+1+\frac{2N\log(N-1)}{N-1}\Big)\,\exp(2\alpha\tau^{-1})\,(P_{N}(\tau,d,\boldsymbol{\gamma}))^{2\alpha}. The result of the corollary now follows by replacing R with the upper bound in ( 21 ). ∎ In the light of the (\epsilon,\delta) -approximation framework ( 3 ), Corollary 12 directly shows that we have \epsilon=\frac{1}{M^{\alpha}}(C_{N}(\tau,\delta,\alpha))^{1/2}\exp(\alpha\tau^{-1})\,(P_{N}(\tau,d,\boldsymbol{\gamma}))^{\alpha} for any \delta\in(0,1) . We remark that the upper bound obtained in Corollary 12 , along with the choices of N and R , generally depends on the dimension d . This issue will be addressed in the following section. 4 Dependence of the error bound on the dimension In this section, let us return, for given f\in\mathcal{H}_{d,\alpha,\boldsymbol{\gamma}} , to the approximation error of our median lattice-based algorithm, \mathrm{err}(f,L_{2},A^{\mathrm{rand}}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}},\mathcal{A}_{d}(N_{*})}):=\|f-A^{\mathrm{rand}}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}},\mathcal{A}_{d}(N_{*})}(f)\|_{L_{2}}, and examine under which circumstances we can overcome the curse of dimensionality, depending on the decay of the weights \boldsymbol{\gamma} . Let f\in\mathcal{H}_{d,\alpha,\boldsymbol{\gamma}} be given and fixed. By Corollary 12 , for a given \tau>0 and \delta\in(0,1) , we can choose R and N such that, with probability at least 1-\delta , \displaystyle[\mathrm{err}(f,L_{2},A^{\mathrm{rand}}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}},\mathcal{A}_{d}(N_{*})})]^{2} \displaystyle\qquad\leq\left\|f\right\|_{d,\alpha,\boldsymbol{\gamma}}^{2}\frac{C_{N}(\tau,\delta,\alpha)}{M^{2\alpha}}\exp(2\alpha\tau^{-1})(P_{N}(\tau,d,\boldsymbol{\gamma}))^{2\alpha}. We now choose \tau>0 , such that \tau^{-1}:=\eta^{-1}\,G_{d},\quad\mbox{where}\quad G_{d}:=2\sum_{j=1}^{d}\gamma_{j}^{1/(2\alpha)}, for some absolute constant \eta>0 . With this choice of \tau , we obtain \displaystyle P_{N}(\tau,d,\boldsymbol{\gamma}) \displaystyle=\prod_{j=1}^{d}\left(1+2\gamma_{j}^{1/(2\alpha)}(1+\eta\,G_{d}^{-1}\log N)\right) \displaystyle=\exp\left(\sum_{j=1}^{d}\log\left(1+2\gamma_{j}^{1/(2\alpha)}(1+\eta\,G_{d}^{-1}\log N)\right)\right) \displaystyle\leq\exp\left(\sum_{j=1}^{d}2\gamma_{j}^{1/(2\alpha)}(1+\eta\,G_{d}^{-1}\log N)\right) \displaystyle=\exp(\,G_{d})\,N^{\eta}. Hence, for a given \delta\in(0,1) , we can choose R and N such that, with probability at least 1-\delta , \displaystyle[\mathrm{err}(f,L_{2},A^{\mathrm{rand}}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}},\mathcal{A}_{d}(N_{*})})]^{2} \displaystyle\qquad\leq\left\|f\right\|_{d,\alpha,\boldsymbol{\gamma}}\frac{C_{N}(G^{-1}_{d}\eta,\delta,\alpha)}{M^{2\alpha}}\exp(2\alpha(\eta^{-1}+1)\,G_{d})N^{2\alpha\eta}. (22) Let us consider two special cases regarding the decay of the weights \boldsymbol{\gamma} . Case 1 . Suppose that \sum_{j=1}^{\infty}\gamma_{j}^{1/(2\alpha)}<\infty . In this case, we define G_{\infty}:=2\sum_{j=1}^{\infty}\gamma_{j}^{1/(2\alpha)} . Then, for all d\in\mathbb{N} we have G_{d}\leq G_{\infty} , and the bound ( 19 ) with c=\exp(-1) is satisfied if N\geq\exp\left(\,(4e\eta^{-1}+1)G_{\infty}+4e\right)\,N^{\eta}+1, which holds for sufficiently large N , independently of d , provided that \eta\in(0,1) . Moreover, with this choice of N , we can select an odd R according to ( 21 ), again independently of d . Finally, using G_{d}\leq G_{\infty} in ( 22 ), we find that the right-hand side of ( 22 ) can be bounded by a quantity that is independent of d , with a convergence rate that can be made arbitrarily close to M^{-2\alpha} by choosing \eta sufficiently small. Case 2 . Suppose that {\displaystyle\limsup_{d\to\infty}\left(\sum_{j=1}^{d}\gamma_{j}^{1/(2\alpha)}\right)/\log d<\infty} . Then, there exists a constant D>0 such that G_{d}\leq D\log d for sufficiently large d . In this setting, the condition ( 19 ) with c=\exp(-1) is satisfied if N\geq\exp\left(\,(4e\eta^{-1}+1)G_{d}+4e\right)\,N^{\eta}+1, which can be achieved by choosing N that grows at most polynomially with d . Using this choice of N , we can also choose an odd R satisfying ( 21 ), which then depends at most logarithmically on d . Finally, from the error bound ( 22 ), we observe that the dependence on G_{d} leads to a bound that depends at most polynomially on d . Moreover, the convergence rate can be made arbitrarily close to M^{-2\alpha} by selecting \eta sufficiently small. We summarize our findings in the following theorem. Theorem 13 . Let f\in\mathcal{H}_{d,\alpha,\boldsymbol{\gamma}} and \delta\in(0,1) be given. Denote by M=RN the total number of function evaluations used by the algorithm A^{\mathrm{rand}}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}},\mathcal{A}_{d}(N_{*})} . Then for any \eta\in(0,1) , the following statements hold: • If \sum_{j=1}^{\infty}\gamma_{j}^{1/(2\alpha)}<\infty , then there exist a prime N and an odd R , both independent of d (with R depending logarithmically on N ), such that with probability at least 1-\delta , \displaystyle[\mathrm{err}(f,L_{2},A^{\mathrm{rand}}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}},\mathcal{A}_{d}(N_{*})})]^{2} \displaystyle\qquad\leq\left\|f\right\|_{d,\alpha,\boldsymbol{\gamma}}\frac{C_{N}(G^{-1}_{\infty}\eta,\delta,\alpha)}{M^{2\alpha}}\exp(2\alpha(\eta^{-1}+1)G_{\infty})N^{2\alpha\eta}. This means that the error bound for the L_{2} -approximation problem using A^{\mathrm{rand}}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}},\mathcal{A}_{d}(N_{*})} does not depend on the dimension d . • If \displaystyle\limsup_{d\to\infty}\left(\sum_{j=1}^{d}\gamma_{j}^{1/(2\alpha)}\right)/\log d<\infty , then there exist a prime N that depends at most polynomially on d , and an odd R that depends at most logarithmically on d and N , such that with probability at least 1-\delta , \displaystyle[\mathrm{err}(f,L_{2},A^{\mathrm{rand}}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}},\mathcal{A}_{d}(N_{*})})]^{2} \displaystyle\qquad\leq\left\|f\right\|_{d,\alpha,\boldsymbol{\gamma}}\frac{C_{N}(G^{-1}_{d}\eta,\delta,\alpha)}{M^{2\alpha}}\,d^{2\alpha D(\eta^{-1}+1)}N^{2\alpha\eta}, for some constant D>0 independent of d and N . This means that the error bound for the L_{2} -approximation problem using A^{\mathrm{rand}}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}},\mathcal{A}_{d}(N_{*})} depends only polynomially on d . Remark 14 . When \sum_{j=1}^{\infty}\gamma_{j}^{1/(2\alpha)}<\infty , a slight modification of ( 8 , Lemma 3) shows that, for any \tau,\eta>0 , there exists a constant C(\boldsymbol{\gamma},\alpha,\tau,\eta) , independent of both d and N , such that P_{N}(\tau,d,\boldsymbol{\gamma})\leq C(\boldsymbol{\gamma},\alpha,\tau,\eta)N^{\eta}. In particular, this implies that the L_{2} -approximation problem using A^{\mathrm{rand}}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}},\mathcal{A}_{d}(N_{*})} has an error bound that is independent of d regardless of our choice of \tau . Remark 15 . The lower bound on N derived in this section is sub-optimal and is used solely for the purpose of analyzing the dependence on the dimension. For practical implementation, one should refer to Remark 11 for guidance on selecting N . Remark 16 . As suggested by the above analysis, one should choose \tau proportional to G_{d}^{-1} to avoid the curse of dimensionality, particularly when \sum_{j=1}^{d}\gamma_{j}^{1/(2\alpha)} diverges as d\to\infty . Given a computational budget M_{\max} for M=RN , one may choose \tau using the following procedure. First, estimate R via ( 21 ), and let N_{\max} be the largest prime N such that N\left(2\log\left(1+\frac{N-1}{4e}\right)+2\log(\delta^{-1})+1\right)\leq M_{\max}. (23) To ensure ( 19 ) holds with N=N_{\max} and c=\exp(-1) , we require \inf_{\tau>0}\exp\left(4e\tau^{-1}\right)\,P_{N_{\max}}(\tau,d,\boldsymbol{\gamma})\leq\exp(-4e)\left(N_{\max}-1\right). Since \tau\frac{d}{d\tau}\log\left(\exp\left(4e\tau^{-1}\right)P_{N_{\max}}(\tau,d,\boldsymbol{\gamma})\right)=-\frac{4e}{\tau}+\sum_{j=1}^{d}\frac{2\gamma_{j}^{1/(2\alpha)}\tau\log N_{\max}}{1+2\gamma_{j}^{1/(2\alpha)}(1+\tau\log N_{\max})} (24) is strictly increasing in \tau>0 , it has a unique zero \tau_{0} and we have \inf_{\tau>0}\exp\left(4e\tau^{-1}\right)P_{N_{\max}}(\tau,d,\boldsymbol{\gamma})=\exp\left(4e{\tau_{0}}^{-1}\right)P_{N_{\max}}(\tau_{0},d,\boldsymbol{\gamma}). We check whether ( 19 ) holds with \tau=\tau_{0} , N=N_{\max} , and c=\exp(-1) . If not, this suggests that M_{\max} is too small and must be increased. For sufficiently large M_{\max} and the corresponding N_{\max} , the equation \exp\left(4e\tau^{-1}\right)P_{N_{\max}}(\tau,d,\boldsymbol{\gamma})=\exp(-4e)\left(N_{\max}-1\right) admits two solutions \tau_{1}<\tau_{2} (or a degenerate solution \tau_{1}=\tau_{2}=\tau_{0} ), and ( 19 ) holds for any \tau\in[\tau_{1},\tau_{2}] . Next, to maximize N_{*} under N=N_{\max} and \tau\in[\tau_{1},\tau_{2}] , we choose \tau_{*}=\arg\max_{\tau\in[\tau_{1},\tau_{2}]}\frac{N_{\max}-1}{\exp(\tau^{-1})P_{N_{\max}}(\tau,d,\boldsymbol{\gamma})}=\arg\min_{\tau\in[\tau_{1},\tau_{2}]}\exp(\tau^{-1})P_{N_{\max}}(\tau,d,\boldsymbol{\gamma}). Since \tau\frac{d}{d\tau}\log\left(\exp\left(\tau^{-1}\right)P_{N_{\max}}(\tau,d,\boldsymbol{\gamma})\right)=-\frac{1}{\tau}+\sum_{j=1}^{d}\frac{2\gamma_{j}^{1/(2\alpha)}\tau\log N_{\max}}{1+2\gamma_{j}^{1/(2\alpha)}(1+\tau\log N_{\max})} (25) is strictly increasing in \tau>0 , it has a unique zero \tau^{\prime}_{0} . Comparing ( 24 ) and ( 25 ), we find \tau^{\prime}_{0}<\tau_{0}\leq\tau_{2} , and hence \tau_{*}=\max(\tau^{\prime}_{0},\tau_{1}) . Moreover, \frac{1}{\tau^{\prime}_{0}}=\sum_{j=1}^{d}\frac{2\gamma_{j}^{1/(2\alpha)}\tau^{\prime}_{0}\log N_{\max}}{1+2\gamma_{j}^{1/(2\alpha)}(1+\tau^{\prime}_{0}\log N_{\max})}d^{-1} . With this choice of \tau=\tau_{*} , N=N_{\max} , and R the odd integer satisfying ( 21 ), our proposed algorithm solves the L_{2} -approximation problem within the budget RN\leq M_{\max} , and achieves an error of order N^{-\alpha}_{*}\sqrt{2\tau^{-1}+1+\frac{2N}{N-1}\log(N-1)}\leq N^{-\alpha}_{*}\sqrt{2d+1+\frac{2N}{N-1}\log(N-1)} with probability at least 1-\delta . 5 Numerical experiments Here, we present numerical experiments. As proven in [ 1 ] , using a single rank-1 lattice rule with M points cannot achieve a convergence rate better than \mathcal{O}(M^{-\alpha/2}) for the worst-case L_{2} -approximation error in any dimension d\geq 2 . The main objective here is to observe the empirical performance of the proposed median lattice-based algorithm, with particular focus on whether it can attain a faster convergence rate in practice. To this end, we restrict our attention to the two-dimensional case, i.e., d=2 . We test the following two periodic functions, both of which are used in [ 2 ] : \displaystyle f_{1}(\boldsymbol{x}) \displaystyle=\prod_{j=1}^{d}\frac{121\sqrt{33}}{100}\max\left\{\frac{25}{121}-\left(x_{j}-\frac{1}{2}\right)^{2},0\right\}, \displaystyle f_{2}(\boldsymbol{x}) \displaystyle=\prod_{j=1}^{d}\left(x_{j}-\frac{1}{2}\right)^{2}\sin(2\pi x_{j}-\pi), with d=2 . The first test function, also used in [ 11 ] , is a scaled periodized kink function that belongs to the space \mathcal{H}_{d,3/2-\epsilon,\boldsymbol{\gamma}} for arbitrarily small \epsilon>0 . This means that the smoothness of this function is arbitrarily close to 3/2 . The second test function is smoother, belonging to the space \mathcal{H}_{d,5/2-\epsilon,\boldsymbol{\gamma}} for arbitrarily small \epsilon>0 , indicating that the smoothness of this function is arbitrarily close to 5/2 . To run Algorithm 1 , we set \alpha=3/2 for f_{1} and \alpha=5/2 for f_{2} . For both test functions, we use the same weight parameters, \gamma_{1}=\gamma_{2}=1 . The total computational budget M_{\max} is always chosen to be a power of 2. The number of points N used in each lattice rule, the number of repetitions R , and the parameter \tau are determined according to the procedure described in Remark 16 with \delta=0.01 . Specifically, N is set to the largest prime number satisfying ( 23 ), and \tau is set to \tau_{*} as defined in Remark 16 . The number of repetitions R is then taken to be the largest odd integer such that R\leq M_{\max}/N . Since we are working in the two-dimensional unweighted setting, these parameter choices may not be optimal, but they are adopted for the sake of consistency and objectivity. We do not check throughout whether the condition ( 19 ) with c=\exp(-1) is satisfied. Following [ 2 ] , we compute the squared L_{2} -approximation error exactly as \displaystyle\|f-A^{\mathrm{rand}}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}},\mathcal{A}_{d}(N_{*})}(f)\|^{2}_{L_{2}} \displaystyle=\sum_{\boldsymbol{h}\notin\mathcal{A}_{d}(N_{*})}|\widehat{f}(\boldsymbol{h})|^{2}+\sum_{\boldsymbol{h}\in\mathcal{A}_{d}(N_{*})}|\widehat{f}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}}}(\boldsymbol{h})-\widehat{f}(\boldsymbol{h})|^{2} \displaystyle=\|f\|_{L_{2}}^{2}-\sum_{\boldsymbol{h}\in\mathcal{A}_{d}(N_{*})}|\widehat{f}(\boldsymbol{h})|^{2}+\sum_{\boldsymbol{h}\in\mathcal{A}_{d}(N_{*})}|\widehat{f}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}}}(\boldsymbol{h})-\widehat{f}(\boldsymbol{h})|^{2}, where the L_{2} -norm and the Fourier coefficients of f\in\{f_{1},f_{2}\} are computed analytically in advance. With our choice \delta=0.01 , we expect that the error bound in Corollary 12 holds with probability at least 0.99 , so that we do not examine the stability of our algorithm by running it multiple times. We now present the results of our numerical experiments. Figure 1 shows the L_{2} -approximation error of our median lattice-based algorithm plotted against M on a log-log scale. In this plot, we set M=NR using the actual values of N and R , rather than using M=M_{\max} . The left and right panels correspond to the test functions f_{1} and f_{2} , respectively. Each panel includes three reference lines: M^{-\alpha/2} , M^{-3\alpha/4} , and M^{-\alpha} . The first line represents the optimal rate possibly achievable by a lattice-based algorithm with a single rank-1 lattice point set, while the third line indicates the best possible rate for any algorithm with M function evaluations. The second line lies between these two, serving as an intermediate reference. For both f_{1} and f_{2} , the observed convergence rate is approximately M^{-3\alpha/4} , which falls short of the expected, optimal rate M^{-\alpha} . Nevertheless, the decay is clearly faster than M^{-\alpha/2} . For f_{2} , we also observe non-asymptotic behavior: the error decays more slowly for small M , but gradually approaches the M^{-3\alpha/4} -rate as M increases. Figure 1: Results for the test functions f_{1} (left) and f_{2} (right): L_{2} -approximation error versus the total number of function evaluations M . To confirm that the observed suboptimal convergence rates result from finite-sample effects, we present Figure 2 and Figure 3 . Figure 2 shows the L_{2} -approximation error plotted against N_{*} , instead of M , on a log-log scale. Figure 3 displays N_{*} versus M , also on a log-log scale. Since we set \gamma_{1}=\gamma_{2}=1 , the value of N_{*} is independent of \alpha (see ( 5 )), and therefore the plots for f_{1} and f_{2} are identical. For this reason, we present only a single plot in Figure 3 . Note that, since Figure 3 only illustrates how N_{*} depends on M and does not involve computing the L_{2} -approximation error, we extend the range of M beyond that used in the other figures. We observe from Figure 2 that the convergence rate of N_{*}^{-\alpha} is achieved for both f_{1} and f_{2} . This agrees well with the theoretical result established in Theorem 10 . On the other hand, Figure 3 illustrates that the relationship between N_{*} and M is still suboptimal, which accounts for the slower convergence rate observed in Figure 1 . Ideally, as M increases, N_{*} should grow almost linearly with M . However, such behavior is not yet evident in the current range of M . For larger values of M , we expect N_{*} to depend almost linearly on M , which in turn yields the optimal convergence rate of the L_{2} -approximation error with respect to M . Figure 2: Results for the test functions f_{1} (left) and f_{2} (right): L_{2} -approximation error versus N_{*} . Figure 3: N_{*} versus the total number of function evaluations M . 6 Discussion Thus far, we have analyzed \mathrm{err}(f,L_{2},A^{\mathrm{rand}}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}},\mathcal{A}_{d}(N_{*})}) , the error for a fixed f\in\mathcal{H}_{d,\alpha,\boldsymbol{\gamma}} , with a particular emphasis on the (\epsilon,\delta) -approximation framework ( 3 ). Here, we first discuss how this result relates to the randomized error ( 2 ). Our choice of \tau,N,R from Remark 16 in fact implies a stronger bound on the failure probability. From ( 18 ) and ( 21 ), the failure probability in Theorem 10 is bounded by \displaystyle\Big(1+\frac{N-1}{1+\tau\log N_{*}}\Big)\left(\frac{4(1+\tau)}{1+\tau\log N_{*}}\right)^{\lceil R/2\rceil}\leq\delta\left(\frac{4e(1+\tau)}{1+\tau\log N_{*}}\right)^{\lceil R/2\rceil}. (26) Because \tau=\tau_{*} attains the maximum N_{*} over \tau\in[\tau_{1},\tau_{2}] while \tau_{0}\in[\tau_{1},\tau_{2}] , \displaystyle\frac{4e(1+\tau)}{1+\tau\log N_{*}}\leq \displaystyle\frac{4e(1+\tau)}{1+\tau\log(N-1)-\tau\log(P_{N}(\tau_{0},d,\boldsymbol{\gamma}))-\tau\tau^{-1}_{0}} \displaystyle\leq \displaystyle\frac{4e({\tau^{\prime}_{0}}^{-1}+1)}{\log(N-1)-\log(P_{N}(\tau_{0},d,\boldsymbol{\gamma}))}, where we have used \tau=\tau_{*}=\max(\tau^{\prime}_{0},\tau_{1})\leq\tau_{0} . As N=N_{\max} increases to infinity, ( 24 ) shows that \tau_{0} decreases to 4e/d , and ( 25 ) shows that \tau^{\prime}_{0} decreases to 1/d . Because R is proportional to \log N , the upper bound ( 26 ) asymptotically converges to 0 faster than any fixed polynomial rate in M=NR . We can use the improved bound to show that our algorithm achieves a nearly-optimal convergence rate in terms of the randomized L_{2} -approximation error, while keeping good tractability properties as shown in the previous section. For any f\in\mathcal{H}_{d,\alpha,\boldsymbol{\gamma}} , we see that \|f\|_{L_{2}}^{2}\leq\left\|f\right\|_{d,\alpha,\boldsymbol{\gamma}}^{2}\sup_{\boldsymbol{h}\in\mathbb{Z}^{d}}\frac{1}{r_{2\alpha,\boldsymbol{\gamma}}(\boldsymbol{h})}=\left\|f\right\|_{d,\alpha,\boldsymbol{\gamma}}^{2}. Moreover, by following ( 2 , Proof of Lemma 4.2) , it holds, for all \boldsymbol{h}\in\mathcal{A}_{d}(N_{*}) and any \boldsymbol{z}\in\{1{:}(N-1)\}^{d} and \boldsymbol{\Delta}\in[0,1)^{d} , that \displaystyle\left|\widehat{f}_{N,\boldsymbol{z},\boldsymbol{\Delta}}(\boldsymbol{h})\right|^{2}=\left|\sum_{\begin{subarray}{c}\boldsymbol{\ell}\in\mathbb{Z}^{d}\\ \boldsymbol{\ell}-\boldsymbol{h}\in P_{N,\boldsymbol{z}}^{\perp}\end{subarray}}\widehat{f}(\boldsymbol{\ell})\exp(2\pi\mathtt{i}(\boldsymbol{\ell}-\boldsymbol{h})\cdot\boldsymbol{\Delta})\right|^{2} \displaystyle\qquad\leq\sum_{\begin{subarray}{c}\boldsymbol{\ell}\in\mathbb{Z}^{d}\\ \boldsymbol{\ell}-\boldsymbol{h}\in P_{N,\boldsymbol{z}}^{\perp}\end{subarray}}\left|\widehat{f}(\boldsymbol{\ell})\exp(2\pi\mathtt{i}(\boldsymbol{\ell}-\boldsymbol{h})\cdot\boldsymbol{\Delta})\right|^{2}r_{2\alpha,\boldsymbol{\gamma}}(\boldsymbol{\ell})\sum_{\begin{subarray}{c}\boldsymbol{\ell}^{\prime}\in\mathbb{Z}^{d}\\ \boldsymbol{\ell}^{\prime}-\boldsymbol{h}\in P_{N,\boldsymbol{z}}^{\perp}\end{subarray}}\frac{1}{r_{2\alpha,\boldsymbol{\gamma}}(\boldsymbol{\ell}^{\prime})} \displaystyle\qquad\leq\left\|f\right\|_{d,\alpha,\boldsymbol{\gamma}}^{2}\sum_{\boldsymbol{\ell}^{\prime}\in\mathbb{Z}^{d}}\frac{1}{r_{2\alpha,\boldsymbol{\gamma}}(\boldsymbol{\ell}^{\prime})}=\left\|f\right\|_{d,\alpha,\boldsymbol{\gamma}}^{2}\prod_{j=1}^{d}\left(1+2\gamma_{j}\zeta(2\alpha)\right), where the first inequality follows from the Cauchy–Schwarz inequality. Thus, for any realization of A^{\mathrm{rand}}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}},\mathcal{A}_{d}(N_{*})} , the L_{2} -approximation error is always bounded by \displaystyle\|f-A^{\mathrm{rand}}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}},\mathcal{A}_{d}(N_{*})}(f)\|_{L_{2}} \displaystyle\qquad\leq\|f\|_{L_{2}}+\left(\sum_{\boldsymbol{h}\in\mathcal{A}_{d}(N_{*})}\left|\widehat{f}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}}}(\boldsymbol{h})\right|^{2}\right)^{1/2} \displaystyle\qquad\leq\left\|f\right\|_{d,\alpha,\boldsymbol{\gamma}}\left(1+\left(|\mathcal{A}_{d}(N_{*})|\,\prod_{j=1}^{d}\left(1+2\gamma_{j}\zeta(2\alpha)\right)\right)^{1/2}\right), where, according to Corollary 6 , the size of \mathcal{A}_{d}(N_{*}) is bounded by N . This means that, even for the worst realization of A^{\mathrm{rand}}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}},\mathcal{A}_{d}(N_{*})} , the corresponding L_{2} -approximation error grows at most like N^{1/2} . However, the failure probability converges to 0 faster than any fixed polynomial rate. In total, we have \sup_{\begin{subarray}{c}f\in\mathcal{H}_{d,\alpha,\boldsymbol{\gamma}}\\ \left\|f\right\|_{d,\alpha,\boldsymbol{\gamma}}\leq 1\end{subarray}}\left(\mathbb{E}\|f-A^{\mathrm{rand}}_{N,\boldsymbol{z}_{\{1{:}R\}},\boldsymbol{\Delta}_{\{1{:}R\}},\mathcal{A}_{d}(N_{*})}(f)\|^{2}_{L_{2}}\right)^{1/2}=O(M^{-\alpha+\varepsilon}) for any \varepsilon>0 , where the implied factor depends only polynomially on the dimension d , or is even independent of d , under the same summability conditions on the weights \gamma_{j} we showed in Section 4 . According to the literature, this order of convergence is known to be nearly optimal for the following reasons. In [ 19 ] , Novak proved that, in general separable Hilbert spaces, the optimal convergence rate of the randomized error coincides with that of the deterministic worst-case error, when algorithms are restricted to using (either random or deterministic) linear functionals as information. Later, in [ 13 ] , Krieg and Ullrich showed that, for the Korobov space, the optimal rate of the L_{2} -approximation error—namely, \mathcal{O}(M^{-\alpha}) —remains the same, up to logarithmic factors, whether algorithms use at most M linear functionals or M function evaluations. Combining these two results, we conclude that the rate \mathcal{O}(M^{-\alpha}) is indeed best possible for the randomized setting with function evaluations. Next, we discuss the worst-case error ( 1 ). Our main result, stated in Corollary 12 , shows that the median algorithm achieves an error bound of \mathcal{O}(M^{-\alpha+\varepsilon}) with high probability for individual functions. One might therefore expect that the same rate also holds for the worst-case error with high probability. However, this is not necessarily the case. This situation is different from what was studied for the integration problem in [ 6 ] , where a high-probability worst-case bound was established. The key obstacle lies in the fact that our result guarantees the existence of a set of good randomized lattice algorithms, but this set may depend on the specific function being approximated. To obtain a worst-case error bound, a single set of randomized lattice algorithms must perform well for all functions in the unit ball of \mathcal{H}_{d,\alpha,\boldsymbol{\gamma}} . Consequently, extending our result to a nearly optimal rate for the worst-case error is nontrivial; straightforward arguments only yield a deteriorated rate of convergence. Whether or not the proposed algorithm can achieve a nearly optimal rate for the worst-case error with high probability remains an open question for future work. A further limitation of our algorithm lies in its explicit dependence on the parameters \alpha and \gamma_{j} to determine N_{*} , as mentioned in Remark 3 . This dependency introduces a practical challenge: the convergence rate is heavily influenced by the choice of \alpha and \gamma_{j} . For instance, assuming a slower decay rate for \gamma_{j} than necessary leads to an overly conservative N_{*} , which in turn degrades the convergence rate. A more desirable solution would be a universal algorithm that simultaneously achieves near-optimal convergence rates of order \mathcal{O}(M^{-\alpha}) and dimension-independent convergence under suitable decay conditions on \gamma_{j} , all without requiring prior knowledge of \alpha and \gamma_{j} . Designing such an algorithm, however, poses a significant challenge, as it would need to adapt implicitly to the intrinsic smoothness and weight structure of the target function space. We leave this critical open problem for future investigation.