approximating with a class of indicator functions: any theorems? Let $G$ be a class of $\it{indicator}$ functions where $g\in G$ implies that $g : X \rightarrow \{0,1\}$, where the domain $X$ is a compact subset of $\mathbf{R}^n$. For example: 
$$ g(x) = 0 \text{ if } w_1x_1+\cdots+w_dx_d < \eta $$
$$ g(x) = 1 \text{ otherwise } $$
Note: I am not interested in this particular class. This is just an example.
Is there a theorem that would say something like below?
Theorem: Let $G$ be an arbitrary class of $\it{indicator}$ functions with properties IMPORTANT TEXT MISSING. Then for any $f : X \rightarrow \mathbf{R}$ which is NICELY BEHAVING IN SOME SENSE and any $\epsilon$ a linear combination $h=w_1g_1+\cdots+w_kg_k$ (of elements in $G$) can be found such that $\vert h(x)-f(x)\vert<\epsilon$ for all $x\in X$.
Any hint highly appreciated!  
EDIT: A possible answer might be found here but I am not sure. It all depends whether my understanding of the discussed theorem is correct.
 A: For sake of an answer, let's assume by nicely behaved you mean "piecewise continuous and bounded functions on a compact subset of $R^n$."
The metric you've stated an interest in is the uniform convergence metric.
Arbitrary indicator functions can approximate piece wise continuous functions uniformly.  For example, if you are interested in an $\epsilon$ approximation, create a partition $r_i$ of the real line with norm less than $\epsilon.$  Then let your indicator sets $A$ be $A_i = \{ x | r_{i-1} <= f(x) < r_i\}$.  
But, you seem to be interested in a space that's more restrictive than "half open / closed subsets of $R^n$"  (which is what is required for the above to work.)  
The space $G$ has to be able to generate arbitrarily small sets, that don't overlap (so half open intervals on the dyadics are a good example).  For continuous functions that is a sufficient characterization.  
For piece wise continuous functions, your space $G$ has to be able to "exactly" model the discontinuities.  So, for example, in $R^2$ if you have discontinuities on the line $y=x$, you cannot piecewise approximate it if the space of $G$ indicator functions is made up of half open rectangles.
