This paper presents an elementary proof of the following theorem: Given {$r$_{$j$}}_{$j$}^{$m$}=1 with m=d+1, fix $$fix R \geqslant \sum\nolimits_{j = 1}^m {r_j } $$ and let Q=[−R, R]^{d}. Then any f∈ L^{2}(Q) is completely determined by its averages over cubes of side r_{j}that are completely contained in Q and have edges parallel to the coordinate axes if and only if r_{j}/r_{k}is irrational for j≠k. When$d$=2 this theorem is known as the local three squares theorem and is an example of a Pompeiu-type theorem. The proof of the theorem combines ideas in multisensor deconvolution and the theory of sampling on unions of rectangular lattices having incommensurate densities with a theorem of Young on sequences biorthogonal to exact sequences of exponentials.