Pseudorandomness via the discrete Fourier transform
Parikshit Gopalan, Daniel Kane, Raghu Meka
Introduction
A central goal of computational complexity is to understand the power that randomness adds to efficient computation. The main questions in this area are whether and , which respectively assert that randomness can be eliminated from efficient computation, at the price of a polynomial slowdown in time, and a constant blowup in space. It is known that proving will imply strong circuit lower bounds that seem out of reach of current techniques. In contrast, proving , could well be within reach. Indeed, bounded-space algorithms are a natural computational model for which we know how to construct strong pseudo-random generators, s, unconditionally.
Let denote the class of randomized algorithms with work space which can access the random bits in a read-once pre-specified order. Nisan [Nis92] devised a of seed length that fools with error . This generator was subsequently used by Nisan [Nis94] to show that and by Saks and Zhou [SZ99] to prove that can be simulated in space . Constructing s with the optimal seed length for this class and showing that is arguably the outstanding open problem in derandomization (which might not require a breakthrough in lower bounds). Despite much progress in this area [INW94, NZ96, RR99, Rei08, RTV06, BRRY14, BV10, KNP11, De11, GMR+12], there are few cases where we can improve on Nisan’s twenty year old bound of [Nis92].
We motivate the problem of constructing s for Fourier shapes by discussing how they capture a variety of well-studied classes like halfspaces (over general domains), combinatorial rectangles, modular tests and combinatorial shapes.
Halfspaces are functions that can be represented as
We show that a for -Fourier shapes with error also fools halfspaces with error . In particular, s fooling Fourier shapes with polynomially small error also fool halfspaces with small error.
s for -Fourier shapes give us s for halfspaces not just for the uniform distribution over the hypercube, but for a large class of distributions that have been studied in the literature. We can derive these results in a unified manner by considering the class of generalized halfspaces.
A generalized halfspace over is a function that can be represented as
A consequence of fooling generalized halfspaces is to derandomize Chernoff-Hoeffding type bounds for sums of independent random variables which are ubiquitous in the analysis of randomized algorithms. We state our result in the language of “randomness-efficient samplers” (cf. [Zuc97]). Let be independent random variables over a domain and let be arbitrary bounded functions. The classical Chernoff-Hoeffding bounds [Hoe63] say that
Combinatorial shapes were introduced in the work of [GMRZ13] as a generalization of combinatorial rectangles and to address fooling linear sums in statistical distance. These are functions of the form
for functions and a function . The best previous generators of [GMRZ13] and [De14] for combinatorial shapes achieve a seed-length of , ; in particular, the best previous seed-length for polynomially small error was . s for -Fourier shapes with error imply s for combinatorial shapes.
Combinatorial rectangles are a well-studied subset of combinatorial shapes [EGL+98, ASWZ96, LLSZ97, Lu02]. They are functions that can be written as for some arbitrary subsets . The best known due to [GMR+12, GY14] gives a seed-length of . Combinatorial rectangles are special cases of Fourier shapes so our for -Fourier shapes also fools combinatorial rectangles, but requires a slightly longer seed. The alphabet-reduction step in our construction is inspired by the generator of [GMR+12, GY14].
1.2 Achieving optimal error dependence via Fourier shapes.
We briefly explain why previous techniques based on limit theorems were unable to achieve polynomially small error with optimal seed-length, by considering the setting of halfspaces under the uniform distribution on . Fooling halfspaces is equivalent to fooling all linear functions in Kolmogorov or cdf distance. Previous work on fooling halfspaces [DGJ+09, MZ13] relies on the Berry-Esséen theorem, a quantiative form of the central limit theorem, to show that the cdf of regular linear functions is close to that of the Gaussian distribution, both under the uniform distribution and under the pseudorandom distribution. However, even for the majority function (which is the most regular linear function), the discreteness of means that the Kolmogorov distance from the Gaussian distribution is , even when is uniformly random. Approaches that show closeness in cdf distance by comparison to the Gaussian distribution seem unlikely to give polynomially small error with optimal seed-length.
We depart from the derandomized limit theorem approach taken by several previous works [DGJ+09, DKN10, GOWZ10, HKM12, GMRZ13, MZ13] and work directly with the Fourier transform. A crucial insight (that is formalized in Lemma 9.2) is that fooling the Fourier transform of linear forms to within polynomially small error implies polynomially small Kolmogorov distance.
2 Our results
There is an explicit generator that fools all -Fourier shapes with error , and has seed-length .
We now state various corollaries of our main result starting with fooling halfspaces.
There is an explicit generator that fools halfspaces over under the uniform distribution with error , and has seed-length .
The best previous generator due to [MZ13] had a seed-length of , which is for polynomially small error .
We also get a with similar parameters for generalized halfspaces.
There is an explicit generator that -fools generalized halfspaces over , and has seed-length .
The generator has seed-length .
This improves on the result of [GOWZ10] who obtained seedlength for this setting via a suitable modification of the generator from [MZ13].
The next corollary is a near-optimal derandomization of the Chernoff-Hoeffding bounds. To get a similar guarantee, the best known seed-length that follows from previous work [SSS95, MZ13, GOWZ10] was .
Let be independent random variables over the domain . Let be arbitrary bounded functions. There exists an explicit generator such that if where , then is distributed identically to and
has seed-length .
There is an explicit generator that fools all linear tests modulo for all with error , and has seed-length .
Finally, we get a generator with near-logarithmic seedlength for fooling combinatorial shapes. [GMRZ13] gave a for combinatorial shapes with a seed-length of . This was improved recently by De [De14] who gave a with seed-length ; in particular, the best previous seed-length for polynomially small error was .
There is an explicit generator that fools -combinatorial shapes to error and has seed-length .
3 Other related work
Starting with the work of Diakonikolas et al. [DGJ+09], there has been a lot of interest in constructing s for halfspaces and related classes such as intersections of halfspaces and polynomial threshold functions over the domain [DKN10, GOWZ10, HKM12, MZ13, Kan11b, Kan11a, Kan14]. Rabani and Shpilka [RS10] construct optimal hitting set generators for halfspaces over ; hitting set generators are weaker than s.
Another line of work gives s for halfspaces for the uniform distribution over the sphere (spherical caps) or the Gaussian distribution. For spherical caps, Karnin, Rabani and Shpilka [KRS12] gave a with a seed-length of . For the Gaussian distribution, [Kan14] gave a which achieves a seed-length of . Recently, [KM15] gave the first s for these settings with seedlength . Fooling halfspaces over the hypercube is known to be harder than the Gaussian setting or the uniform distribution on the sphere; hence our result gives a construction with similar parameters up to a factor. At a high level, [KM15] also uses a iterative dimension reduction approach like in [KMN11, CRSW13, GMR+12]; however, the final construction and its analysis are significantly different from ours.
Gopalan et al. [GOWZ10] gave a generator fooling halfspaces under product distributions with bounded fourth moments, whose seed-length is .
The present work completely subsumes a manuscript of the authors which essentially solved the special-case of derandomizing Chernoff bounds and a special class of halfspaces [GKM14].
Proof overview
We describe our for Fourier shapes as in Theorem 1.1. The various corollaries are derived from this Theorem using properties of the discrete Fourier transform of integer-valued random variables.
Let us first consider a very simple : -wise independent distributions over . At a glance, it appears to do very poorly as it is easy to express the parity of a subset of bits as a Fourier shape and parities are not fooled even by -wise independence. The starting point for our construction is that bounded independence does fool a special but important class of Fourier shapes, namely those with polynomially small total variance.
For a complex valued random variable , define the variance of as
To gain some intuition for why this is a natural quantity, note that gives an easy upper bound on the expectation of a Fourier shape:
To complement the above, we show that if the total-variance is very small, then generators based on limited independence do fairly well. Concretely, our main technical lemma says that limited independence fools products of bounded (complex-valued) random variables, provided that the sum of their variances is small.
On the other hand, if for a fixed constant , then choosing -wise independence is enough to get error while also achieving seed-length as desired. We exploit this observation by combining the use of limited independence with the recent iterative-dimension-reduction paradigm of [KMN11, CRSW13, GMR+12]. Our construction reduces the problem of fooling Fourier shapes with through a sequence of iterations to fooling Fourier shapes where the total variance is polynomially small in in each iteration and then uses limited independence in each iteration.
We construct a with seed-length which -fools -Fourier shapes when for some sufficiently large constant . We build the generator in two steps.
In the first step, we build a with seed-length which achieves constant error for -Fourier shapes with . In the second step, we drive the error down to as follows. We hash the coordinates into roughly buckets, so that for at least buckets, restricted to the coordinates within the bucket has total-variance at least . We use the with constant error within each bucket, while the seeds across buckets are recycled using a for small-space algorithms. This construction is inspired by the construction of small-bias spaces due to Naor and Naor [NN93]; the difference being that we use generators for space bounded algorithms for amplification, as opposed to expander random walks as done in [NN93].
2 Alphabet-reduction
The next building block in our construction is alphabet-reduction which helps us assume without loss of generality that the alphabet-size is polynomially bounded in terms of the dimension . This is motivated by the construction of [GMR+12].
Concretely, we show that constructing an - for -Fourier shapes can be reduced to that of constructing an - for -Fourier shapes for . The alphabet-reduction step consists of steps where in each step we reduce fooling -Fourier shapes for , to that of fooling -Fourier shapes, at the cost of random bits.
We now describe a single step that reduces the alphabet from to . Consider the following procedure for generating a uniformly random element in :
For , sample uniformly random subsets
Sample uniformly at random from .
Output , where .
Our goal is to derandomize this procedure. The key observation is that once the subsets are chosen, we are left with a -Fourier shape as a function of . So the choice of can be derandomized using a for Fourier shapes with alphabet , and it suffices to derandomize the choice of the ’s. A calculation shows that (because the ’s are uniformly random), derandomizing the choice of the ’s reduces to that of fooling a Fourier shape of total-variance . Lemma 2.1 implies that this can be done with limited independence.
3 Dimension-reduction for low-variance Fourier shapes
We first hash the coordinates into roughly buckets using a -wise independent hash function for . Note that this only requires random bits.
For the coordinates within each bucket we use a -wise independent string in for . We use true independence across buckets. Note that this requires independent seeds of length .
4 Main Technical Lemma
The lemma can be seen as a generalization of a similar result proved for real-valued random variables in [GY14](who also have an additional restriction on the means of the random variables ). However, the generalization to complex-valued variables is substantial and seems to require different proof techniques.
We then argue that can be approximated by a polynomial of degree less than with small expected error. The polynomial is obtained by truncating the Taylor series expansion of the function. Once, we have such a low-degree polynomial approximator, the claim follows as limited independence fools low-degree polynomials.
To handle the general case where ’s are not necessarily bounded, we use an inclusion-exclusion argument and exploit the fact that with high probability, not many of the ’s (say more than ) will deviate too much from their expectation. We leave the details to the actual proof.
Preliminaries
For a complex valued random variable ,
Unless otherwise stated denote universal constants.
Throughout we assume that is sufficiently large and that are sufficiently small.
For positive functions we write when .
For we say that a family of hash functions is -biased if for any distinct indices and ,
We say that such a family is -wise independent if the above holds with for all .
We say that a distribution over is -biased or -wise independent if the corresponding family of functions is.
Such families of functions can be generated efficiently using small seeds.
For , there exist explicit -biased families of hash functions that can be generated efficiently from a seed of length . There are also, explicit -wise independent families that can be generated efficiently from a seed of length .
Taking the pointwise sum of such generators modulo gives a family of hash functions that is both -biased and -wise independent generated from a seed of length .
We start with the simple observation that to -fool an -Fourier shape , we can assume the functions in have bit-precision . This observation will be useful when we use PRGs for small-space machines to fool Fourier shapes in certain parameter regimes.
If a -fools -Fourier shapes when ’s have bit precision , then fools all -Fourier shapes with error at most .
We collect some known results about pseudorandomness and prove some other technical results that will be used later.
We shall use s for small-space machines or read-once branching programs (ROBP) of Nisan [Nis92], [NZ96] and Impagliazzo, Nisan and Wigderson [INW94]. We extend the usual definitions of read-once branching programs to compute complex-valued functions; the results of [Nis92], [NZ96], [INW94] apply to this extended model readilyThis is because these results in fact give guarantees in terms of statistical distance..
An -ROBP is a layered directed graph with layers and vertices per layer with the following properties.
A vertex in layer , has edges to layer each labeled with an element of .
There exists an explicit which -fools -branching programs and has seed-length .
For all and , there exists an explicit which -fools -branching programs for and has seed-length .
Fooling products of low-variance random variables
We now show one of our main technical claims that products of complex-valued random variables are fooled by limited independence if the sum of variances of the random variables is small. The lemma is essentially equivalent to saying that limited independence fools low-variance Fourier shapes.
We start with the following standard bound on moments of bounded random variables whose proof is deferred to appendix B.
We also use some elementary properties of the (complex-valued) log and exponential functions:
Claims (1), (2) follow from the Taylor series expansions for the complex-valued log and exponential functions.
We prove Lemma 4.1 or equivalently, Equation (3) by proving a sequence of increasingly stronger claims. We begin by proving that Equation (3) holds if ’s have small absolute deviation, i.e., lie in a disk of small radius about a fixed point.
Therefore, by Lemma 4.2, the expression in (4) is at most
Next, we relax the conditions to handle the case where we only require the means of the ’s be far from zero.
We assume throughout that is less than a sufficiently small constant; otherwise, there is nothing to prove. Further, note that there can be at most different indices where . As even after conditioning on the values of the corresponding ’s, the remaining ’s are -independent, it suffices to prove the lemma when for all .
To apply Lemma 4.4, we consider a truncation of our random variables: define
We truncate the above expansion to only include terms corresponding to sets with for to be chosen later. Let
Note that the expectation above is the same as what it would be if the ’s were fully independent, in which case it is at most
Therefore, -wise independence fools to error .
On the other hand, the expectation of is
Taking yields a final error of . This completes our proof. ∎
Finally, we can extend our proof to cover the general case.
Note that it suffices to prove that Equation (3) holds. As before, it suffices to assume that and that for all .
On the one hand if , we note that for sufficiently large, the values of are independent of each other, and even after conditioning on them, the remaining ’s are still -wise independent. Thus, applying Lemma 4.5 to the expectation of the product of the remaining we find that the difference between the expectation of the product of ’s and product of ’s is as desired.
Notice that so long as at least of have absolute value less than , then
Therefore, it suffices to show that this occurs except with probability at most . Let be the number of so that Note that
A Generator for high-variance Fourier shapes
In this section, we construct a generator that fools Fourier shapes with high variance.
We start with the simple but crucial observation that Fourier shapes with large variance have small expectation.
We build the generator in two steps. We first build a generator with seed-length which achieves constant error for all with . In the second step, we reduce the error down to . This construction is inspired by a construction of Naor and Naor [NN93] of small-bias spaces.
Our goal in this subsection is get a generator with constant error for Fourier shapes where . We start by showing that when (instead of just ), -wise independence is enough to fool .
Let , . Now, by Lemma 4.1 applied to , we have,
Note that by taking to be a sufficiently large constant compared to , we can make the last bound arbitrary small.
for sufficiently large constant and some constant . ∎
We reduce the general case of to the case above where by using the Valiant-Vazirani technique of sub-sampling. For let . If we sample a random subset with in a pairwise independent manner, we will get with probability. Since we do not know , we sample subsets whose cardinalities are geometrically increasing; one of them is likely to satisfy the desired bound.
We set up some notation that will be used in the remainder of this section.
The proof of this lemma is standard and is deferred to Appendix C.
This naturally suggests using an -wise independent distribution within each bucket. But using independent strings across the buckets would require a seed of length . We analyze our generator assuming independence across distinct buckets, but then recycle the seeds using s for space bounded computation to keep the seed-length down to (rather than ).
We now prove the main claim of this subsection.
Let and let be an independent -wise independent string for a parameter to be chosen later. Define
In other words, the generator applies the string to the coordinates in bucket .
Observe that . Since the ’s are independent of each other
We next improve the seed-length of using the for ROBPs of Theorem 3.4. To this end, note that by Lemma 3.2 we can assume that every , and hence every , has bit precision at most bits (since our goal is to get error ). Further, each can be generated efficiently with random bits.
Thus, for a fixed permutation , the computation of can be done by a -ROBP where are and : for , the ROBP computes and multiplies it to the product computed so far, which can be done using bits of space. Let be the generator in Theorem 3.4 fooling -ROBPs as above with error . has seedlength . Let
2 Reducing the error
Our generator will partition into buckets , using a family of hash functions with the following spreading property:
We start by showing that the desired hash functions can be generated from a small-bias family of hash functions. We show that it satisfies the conditions of the lemma by standard moment bounds. The proof is in Appendix C
For all constants , there exist constants such that following holds. For all , there exists an explicit hash family , where which is -spreading and can be sampled efficiently with bits.
where is the constant from Lemma 5.3. By the spreading property of , with probability at least , . Therefore, for sufficiently large,
As in Lemma 5.5, we recycle the seeds for the various buckets using the PRGs for ROBPs. By Lemma 3.2, we may assume that has bit precision at most bits. Further note that
For a fixed hash function , this can be computed by a -ROBP where and , corresponding to the various possible seeds for . Let be a generator fooling -ROBPs as in Theorem 3.3 with error and define
The seed-length is dominated by the seed-length of , which is
Alphabet reduction for Fourier shapes
In this section, we describe our alphabet-reduction procedure, which reduces the general problem of constructing an -PRG for -Fourier shapes where could be much larger than , to that of constructing an -PRG for -Fourier shapes. This reduction is composed of steps where in each step we reduce fooling -Fourier shapes to fooling -Fourier shapes. Each of these steps in turn will cost random bits, so that the overall cost is . Concretely, we show the following:
Let and suppose that for some , for all there exists an explicit generator which -fools -Fourier shapes. For all , there exists an explicit generator which -fools -Fourier shapes with seed-length .
We prove the claim by showing that for , we can reduce -fooling -Fourier shapes to that of -fooling -Fourier shapes with additional random bits. The theorem follows by applying the claim until the alphabet size drops below when we can use . This costs a total of random bits, and gives error . The claim follows by replacing with .
Thus, suppose that and for , we have a generator which -fools -Fourier shapes. The generator works as follows:
Generate a matrix where
Each column of is from a pairwise independent distribution over .
The different columns are -wise independent for for some sufficiently large constant .
Generate for .
outputs where for .
Each column of can be generated using a seed of length . By using seeds for various columns that are -wise independent, generating requires seedlength (as ), while the number of bits needed to generate is .
Let be random variables distributed uniformly over and respectively. Let for , so that is uniform over and . Our goal is to show that and are close in expectation. We do this by replacing and by and respectively.
That we can replace with follows from the pseudorandomness of . For any fixed , as fools -Fourier shapes,
We now show that for truly random , one can replace by . Note that
The random variables are -wise independent. Further, we have
where the second to last inequality follows becase and , and the last holds for for a sufficiently big constant . Equation 9 now follows from Equations (11) and (10).
Dimension reduction for low-variance Fourier shapes
We next describe our dimension reduction step for low-variance Fourier shapes. We start with an -Fourier shape where and . We show how one can reduce the dimension to , at a price of a blowup in the alphabet size which now becomes for some (large) constant .
Let , and . There is a constant and such that the following holds: if there exists an explicit with seed-length which -fools -Fourier shapes, then there exists an explicit generator with seed-length which -fools -Fourier shapes with and .
We start by constructing an easy to analyze generator which hashes co-ordinates into buckets using -wise independence and then uses independent -wise independent strings within a bucket. Let
where will is a sufficiently large constant. Let be a -wise independent family of hash functions. Let be a -wise independent generator over . Define a new generator as:
We argue that fools -Fourier shapes with small total variance as in the theorem. Our analysis proceeds as follows:
With high probability over , each of the ’s has low variance except for a few heavy co-ordinates (roughly after dropping heavy coordinates).
Within each bin we have -wise independence, whereas the distributions across bins are independent. So even conditioned on the heavy co-ordinates in a bin, the remaining distribution in the bin is -wise independent. Hence each is fooled by Lemma 4.1.
For , to be chosen later, let denote the -large indices and denote the small indices. We call a hash function -good if the following two conditions hold for every bin where :
The bin does not have too many large indices: .
The small indices in the bin have small total variance:
Using standard moment bounds for -wise independent hash functions one can show that is -good with probability at least for and . We defer the proof of the following Lemma to Appendix D.
Let and let be a -wise independent family of hash functions for . Then is -good with probability .
We next argue that if is -good then, -wise independence is sufficient to fool for each .
Let be -good, and let . For -wise independent, and ,
Fix . By relabelling coordinates, let us assume that and , where . As is -wise independent, is uniformly distributed over . We couple and by taking for . Even after conditioning on these values, are -wise independent.
We use these lemmas to prove Theorem 7.1.
Recall that where for . Since the s are independent, so are the ’s. Hence,
By Lemma 7.3, for -good , if , then
Combining the above equations we get that for ,
where the last inequality holds by taking in Equation (12) to be a sufficiently large constant.
We next derandomize the choice of the ’s by using a PRG for appropriate Fourier shapes. Let be the seed-length of the generator obtained by setting as above, and let be such that . Let
respectively. Observe that is a Fourier shape, and
By assumption, we have an explicit generator which -fools -Fourier shapes. We claim that defined as
fools small-variance -Fourier shapes.
Since fools -Fourier shapes,
By Equation (16), whenever ,
The seed-length required for is for and for . ∎
Putting things together
We put the pieces together and prove our main theorem, Theorem 1.1. We show the following lemma which allows simultaneous reduction in both the alphabet and the dimension, going from fooling -Fourier shapes to fooling -Fourier shapes.
Let , for some sufficiently large constant , and . If there exists an explicit with seed-length which -fools -Fourier shapes for all , then there exists an explicit generator with seed-length which -fools -Fourier shapes.Comparing this to Theorem 7.1, the main difference is that we do not assume that is small. Further, the generator for small dimensions requires , and our goal is to fool Fourier shapes in dimensions with arbitrary alphabet size .
For any , define a new Fourier shape . Then, for any fixed , -fools as . Therefore,
Consider a fixing of and define . Then, for any fixed , -fools as . Therefore,
We prove Theorem 1.1 by repeated applications of this lemma.
Assume that the final error desired is . Let . Applying Lemma 8.1, by using random bits we reduce fooling -Fourier shapes to fooling -Fourier shapes for .
We now apply the lemma times to reduce to the case of fooling -Fourier shapes. This can be done by noting that by Lemma 3.2 it suffices to fool Fourier shapes with having bits of precision. Such Fourier shapes can be computed by width- ROBPs, and thus using the generator from Theorem 3.3, we can fool this case with seed length bits. Since each step requires random bits, the overall seedlength is bounded by
Applications of 𝖯𝖱𝖦𝖯𝖱𝖦{\mathsf{PRG}}s for Fourier shapes
In this Section, we show how Theorem 1.1 implies near optimal s for halfspaces, modular tests and combinatorial shapes. We first prove two technical lemmas relating closeness between Fourier transforms of integer valued random variables to closeness under other metrics. We define the Fourier distance, statistical distance and Kolmogorov distance between two integer-valued random variables respectively as
The first standard claim relates closeness in statistical distance and Fourier distance for bounded integer valued random variables.
Let be two integer-valued random variables supported on . Then,
Note that the distribution is supported on at most points. Therefore,
On the other hand, the Plancherel identity implies that
The second claim relates closeness in Kolmogorov distance to closeness in Fourier distance. The key is that unlike in Lemma 9.1, the dependence on is logarithmic. This difference is crucial to fooling halfspaces with polynomially small error (since there can exponential in the dimension ).
Let be two integer-valued random variables supported on . Then,
It is clear that . Further,
where is the distance between and the nearest integer. Therefore, we have
We combine Lemma 9.2 with Theorem 1.1 to derive Corollary 1.2, which gives s for halfspaces with polynomially small error from s for -Fourier shapes.
Let be a which -fools -Fourier shapes (here we identify $\{\pm 1\}\mathcal{G}\varepsilon=O(n\log(n)\delta)$.
Let be a halfspace given by . It is well known that we can assume the weights and the threshold to be integers bounded in the range for (cf. [LC67]). Let and for and , . Note that are bounded in the range .
then is a -Fourier shape. Hence,
Therefore, by Lemma 9.2 applied to , , . Finally, note that
The corollary now follows by picking a generator as in Theorem 1.1 for with error for sufficiently big . ∎
To prove Corollary 1.3, we need the following lemma about generalized halfspaces.
In Definition 3, we may assume that each is an integer of absolute value .
Let be a generalized halfspace where the s are arbitrary. Embed into by sending each to where if and otherwise. Note that
over the domain has a representation where the weights and are integers of size at most . Hence we can replace each in the defintion of with without changing its value at any point in . ∎
We now prove Corollary 1.3 giving s for generalized halfspaces over .
Letting and letting be obtained from a PRG for -Fourier shapes with error at most , we let and . By Lemma 9.2 that . Picking sufficiently small gives our generator for generalized halfspaces. ∎
Then there exists a discrete product distribution such that for every halfspace ,
Further, each can be sampled using random bits.
Note that the first and second moment conditions on can be obtained for any product distribution by an affine transformation. Hence we get Corollary 1.4 from combining Lemma 9.4 with Corollary 1.3. In particular, there exist generators that fool all halfspaces with error under the Gaussian distribution with seed-length . This nearly matches the recent result of [KM15] upto a factor. Further, it is known (see e.g [GOWZ10, Lemma 11.1]) that s for halfspaces under the Gaussian distribution imply s for halfspaces over the sphere.
We next prove Corollary 1.5 which derandomizes the Chernoff bound.
First note that we can assume without loss of generality that each can be sampled with bits (by ignoring elements which happen with smaller probability). In particular, let each have the same distribution as for where (here we identify with ) and some function . Let be a PRG which -fools -generalized halfspaces. Now, let , where for .
Note that can be sampled with random bits. We claim that satisfies the required guarantees. To see this, define the generalized halfspaces
From the Chernoff-Hoeffding bound [Hoe63], we have
We next prove Corollary 1.6 about fooling modular tests.
Let be a which fools -Fourier shapes with error . We claim that fools modular tests with error at most .
Let be a modular test, let and for . In order to fools modular tests, it suffices that
On the other hand, since both these random variables are bounded in the range , by Lemma 9.1
where the last inequality uses the fact that the Fourier transforms of both random variables are -Fourier shapes by Equation (20). ∎
Next we prove Corollary 1.7 giving s from combinatorial shapes.
Recall that a combinatorial shape is a function
where and . Since , it suffices to fool the generalized halfspaces
for each with error . Hence the claim follows from Corollary 1.3 about fooling generalized halfspaces. ∎
References
Appendix A Proofs from Section 3
Let be the indicator function of the event that . Note that Therefore,
Let be if for some but one of or equals or and otherwise be equal to where is the number of distinct values taken by or . Notice that by the -biasedness of that
for fixed values of . We claim that it is at most where is again the number of distinct elements of the form or that appear in this way an odd number of times. Letting be the number of distinct elements of the form or , the expression in question is times the number of choices of so that each value of or appears with only one value of . In other words this is times the number of functions so that for all . This last relation splits into equivalence classes given by the transitive closure of the operation that if and for some . We note that any that appears an odd number of times as an or must be in an equivalence class of size at least because it must appear at least once with some other element. Therefore, the number of equivalence classes, is at least . Thus, the sum in question is at most . Therefore, we have that
Note that the second line above comes from taking to be the multiset
Let denote the indicator random variable which is if and otherwise. Let . Now, if were a truly random hash function, then, by Hoeffding’s inequality,
Therefore, for a truly random hash function and even integer , . Therefore, for a -biased hash family, we get . Hence, by Markov’s inequality, for any ,
Appendix B Proofs from Section 4
First we note that since for any complex random variable, , that
and , it suffices to prove our lemma when is a real-valued random variable.
We can now compute the expectation of by expanding out the polynomial in question and computing the expectation of each term individually. In particular, we have that
Next we group the terms above by the set of indices that occur as for some . Thus, we get
We note that the expectation in question is 0 unless for each , occurs at least twice in the product. Therefore, the expectation is 0 unless and overall is at most . Thus, the expectation in question is at most
Next, note that by expanding out we find that Therefore, the expectation in question is at most
Appendix C Proofs from Section 5
By the pairwise independence of ,
In particular, with probability at least , . ∎
for a suitable choice of the constant and .
Appendix D Proofs from Section 7
Note that . Since is -wise independent, for any index ,
By Lemma 3.6 applied to , we get that for any ,