Abstract
For any finite field \(\mathcal{F}\) and \(k<\ell \), we consider the task of testing whether a function \(f:\mathcal{F}^\ell \rightarrow \{0,1\}\) is the indicator function of an \((\ell -k)\)-dimensional affine space. For the case of \(\mathcal{F}=\mathrm{GF}(2)\), an optimal tester for this property was presented by Parnas, Ron, and Samorodnitsky (SIDMA 2002), by mimicking the celebrated linearity tester of Blum, Luby and Rubinfeld (JCSS 1993) and its analysis. We show that the former task (i.e., testing \((\ell -k)\)-dimensional affine spaces) can be efficiently reduced to testing the linearity of a related function \(g:\mathcal{F}^\ell \rightarrow \mathcal{F}^k\). This reduction yields an almost optimal tester for affine spaces (represented by their indicator function).
Recalling that Parnas, Ron, and Samorodnitsky used testing \((\ell -k)\)-dimensional affine spaces as the first step in a two-step procedure for testing k-monomials, we also show that the second step in their procedure can be reduced to testing whether the foregoing function g depends on k of its variables.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Notes
- 1.
- 2.
Actually, the density of suitable k-long sequences in H is \(\prod _{i\in [k]}(1-{|\mathcal{F}|}^{-i})>1/4\).
- 3.
Alternatively, if \(g(x+x')=g(x)+g(x')\) for every \(x,x'\in \mathcal{F}^\ell \), then \(x,x'\in H\) implies \(x+x'\in H\) (for every \(x,x'\in \mathcal{F}^\ell \)), since \(g(x)=g(x')=0^k\) implies \(g(x+x')=0^k\). Hence, \(H=g^{-1}(0^k)\) is a linear subspace. Lastly, we note that this subspace has dimension \(\ell -k\), since the image of g equals \(\mathcal{F}^k\) and \(|g^{-1}(0^k)|=|g^{-1}(c)|\) holds for every \(c\in \mathcal{F}^k\).
- 4.
First note that there is no need to check the cases in which \(c_i=0\). As for the other cases, by linearity of H, it holds that \(\sum _{j\in [i]}c_jv^{(j)}\in H\) if and only if \(\sum _{j\in [i]}(c_j/c_i)v^{(j)}\in H\).
- 5.
This observation was missed in prior versions of this work, leading to unnecessary checks in the original testers.
- 6.
Needless to say, we would welcome a one-sided error reduction. Recall that the case \(\epsilon \ge 4\cdot {|\mathcal{F}|}^{-k}\) can be handled by density estimation. A complexity improvement for the main case (of \(\epsilon <4\cdot {|\mathcal{F}|}^{-k}\)) appears in Sect. 3.3.
- 7.
- 8.
That is, we requires that this subspace has the form
$$\left\{ 1^\ell +\sum _{j\in ([\ell ]\setminus \{i\})}c_je_j: c_1,...,c_\ell \in \{0,1\}\right\} $$where \(e_1,...,e_\ell \in \{0,1\}^\ell \) are the \(\ell \) unit vectors (i.e., vectors of Hamming weight 1).
- 9.
Recall that if \(\epsilon <2^{-k+2}\), then \(O(2^k)=O(1/\epsilon )\), and otherwise (i.e., for \(\epsilon \ge 2^{-k+2}\)) testing affinity of H reduces to estimating the density of \(h^{-1}(1)\).
- 10.
Note that \(x,y\not \in H\) does not determine whether or not \(x-y\) is in the linear space \(H-H\), let alone that a negative answer does not allow to related \(h(x-y+z)\) to h(z). In contrast, \(x,y\in H\) implies that \(h(x-y+z)=h(z)\) for every \(z\in \{0,1\}^\ell \).
- 11.
In some previous versions of this work it was stated that \(h'\) describes an axis-parallel linear space if and only if \(g'\) is a projection function (i.e., \(g'(x)=x_I\) for some k-subset I). As shown next, this statement is wrong.
- 12.
We can set the values of the variables in \(\overline{S}\) arbitrarily since we are testing a linear function. In contrast, when testing for k-junta (as in [5]) it is essential to assign the variables in \(\overline{S}\) at random, and perform this test of influence many times.
- 13.
In the general case, these expectations may not be satisfied, but such violation provides statistical evidence for rejection.
References
Bellare, M., Goldreich, O., Sudan, M.: Free bits, PCPs and non-approximability - towards tight results. SIAM J. Comput. 27(3), 804–915 (1998). Extended abstract in 36th FOCS (1995)
Blais, E.: Testing juntas nearly optimally. In: 41st ACM Symposium on the Theory of Computing, pp. 151–158 (2009)
Blum, M., Luby, M., Rubinfeld, R.: Self-testing/correcting with applications to numerical problems. J. Comput. Syst. Sci. 47(3), 549–595 (1993). Extended abstract in 22nd STOC (1990)
Chakraborty, S., Garcia-Soriano, D., Matsliah, A.: Nearly tight bounds for testing function isomorphism. In: 22nd ACM-SIAM Symposium on Discrete Algorithms, pp. 1683–1702 (2011)
Fischer, E., Kindler, G., Ron, D., Safra, S., Samorodnitsky, A.: Testing juntas. J. Comput. Syst. Sci. 68(4), 753–787 (2004). Extended abstract in 44th FOCS (2002)
Goldreich, O.: Computational Complexity: A Conceptual Perspective. Cambridge University Press, Cambridge (2008)
Goldreich, O.: Introduction to Property Testing. Cambridge University Press, Cambridge (2017)
Goldreich, O., Levin, L.A.: A hard-core predicate for all one-way functions. In: The Proceedings of 21st ACM Symposium on the Theory of Computing, pp. 25–32 (1989)
Parnas, M., Ron, D., Samorodnitsky, A.: Testing basic Boolean formulae. SIAM J. Discrete Math. Algorithm 16(1), 20–46 (2002)
Acknowledgements
I am grateful to Roei Tell for reading prior versions of this text and pointing out numerous inaccuracies and gaps. I also wish to thank Clement Canonne and Tom Gur for their comments. Lastly, I am grateful to Eric Blais for helpful discussions regarding the problem of testing k-linearity, and for permission to include his ideas in the appendix. This research was partially supported by the Israel Science Foundation (grant No. 671/13).
Author information
Authors and Affiliations
Corresponding author
Editor information
Editors and Affiliations
Appendix: On Testing k-Linearity
Appendix: On Testing k-Linearity
For an arbitrary finite field \(\mathcal{F}\) and integers \(k,\ell ,m\in \mathbb N\), we say that \(f:\mathcal{F}^\ell \rightarrow \mathcal{F}^m\) is k-linear if f is a linear function that depends on at most k (out of its \(\ell \)) variables. Assuming that the tested function f is linear, we present a simple test that always accepts k-linear functions and rejects (w.h.p.) linear functions that are not k-linear.
The tester uses the key idea of the k-junta test of Fischer et al. [5], which is to randomly partition the \(\ell \) variables to \(O(k^2)\) sets, hoping that (in the case of a yes-instance) each set contains at most one variable that influences the function’s value, and detecting which of the sets contain such a variable, hereafter called an influential variable. We accept if and only if at most k sets are detected as containing influential variables. To check whether a set \(S\subset [\ell ]\) contains influential variables, we select an arbitrary (e.g., random) assignment to the variables in \({\overline{S}}=[\ell ]\setminus S\) and two random (and independent) assignments to the variables in S, and check whether the function’s value is the same under both assignments.Footnote 12
Given that the tested function is linear, the analysis of this procedure is quite straightforward (and, indeed, much simpler than in [5]): If S contains some influential variables of f, then the function’s value changes with probability at least \(1-|\mathcal{F}|^{-1}\) (e.g., it is exactly \(1-|\mathcal{F}|^{-1}\) in case \(m=1\)), whereas the value does not change if S contains no influential variable. The complexity of this procedure is \(\varOmega (k^2)\), but we can improve it by using two levels of partitions. Specifically, we suggest the following procedure (where the stated expectations refer to the case that the function is O(k)-linear).Footnote 13
-
1.
Select a random partition of \([\ell ]\) into \(t = k/\log k\) parts, expecting \(O(\log k)\) influential variables in each part.
-
2.
For each part S in this t-partition, perform the following (three-step) trial for \(t'=O(\log k)\) times.
-
(a)
Select a random partition of S to \(O(\log k)^2\) sub-parts, expecting at most a single influential variable in each sub-part.
-
(b)
For each sub-part, check whether it contains influential variables (by selecting two random assignments as described above). Actually, we perform this check \(O(\log k)\) times such that a sub-part that contains influential variables is detected to be so with probability at least \(1-o(1/k)\).
-
(c)
Set the vote of the current trial to equal the number of sub-parts that were detected as containing influential variables.
(Note that if the sub-partition selected in Step (a) is good (i.e., each sub-part contains at most one influential variable) and all relevant sub-parts were detected as containing influential variables, then the current vote equals the number of influential variables in S.)
For each S, set the verdict for number of influential variables in S to equal the largest vote obtained in the \(t'\) corresponding trials, expecting the answer to be correct with probability \(1-o(1/t)\).
-
(a)
-
3.
Accept if and only if the sum of the verdicts is at most k.
The foregoing test has complexity \(t \cdot t'\cdot O(\log k)^3={\widetilde{O}}(k)\), but this can be improved using an adaptive procedure. Specifically, the following recursive procedure was suggested to us by Eric Blais.
-
1.
Select a random partition of \([\ell ]\) into k parts, expecting \(\varOmega (k)\) parts with a single variable.
-
2.
For each part S in this k-partition, determine whether it contains exactly one variable by performing the following (two-step) trial for \(t'=O(\log k)\) times.
-
(a)
Select a random 2-partition of S and check whether each sub-part contains influential variables. (We stress that each of these two checks is performed once.)
-
(b)
Set the vote of the current trial to equal the number of sub-parts that were detected as containing influential variables.
For each S, declare this part as having a single influential variable if and only if the maximum vote for it equals 1.
(Note that, with probability \(1-o(1/k)\), the declaration regarding S is correct; that is, S is declared as having a single influential variable if and only if this is actually the case.)
-
(a)
-
3.
Let U be the union of the parts declared to have a single influential variable, and \(k'\) be their number. If more than k parts were found to contain influential variables (e.g., \(k'>k\)) then reject; if \(k'\le k\) and no part was found to contain more than one influential variable then accept. Otherwise, recurse with the function restricted to \([\ell ]\setminus U\) and \(k\leftarrow k-k'\).
Observing that for k-linear functions, with high probability, the number of parts in all recursion calls is O(k), it follows that this procedure has complexity \(O(k\log k)\).
Rights and permissions
Copyright information
© 2020 Springer Nature Switzerland AG
About this chapter
Cite this chapter
Goldreich, O. (2020). Reducing Testing Affine Spaces to Testing Linearity of Functions. In: Goldreich, O. (eds) Computational Complexity and Property Testing. Lecture Notes in Computer Science(), vol 12050. Springer, Cham. https://doi.org/10.1007/978-3-030-43662-9_13
Download citation
DOI: https://doi.org/10.1007/978-3-030-43662-9_13
Published:
Publisher Name: Springer, Cham
Print ISBN: 978-3-030-43661-2
Online ISBN: 978-3-030-43662-9
eBook Packages: Computer ScienceComputer Science (R0)