Partitions of $\mathbb{R}^d$ by implicit polynomial equations Given a polynomial
$p(x_1,x_2,\ldots,x_d)$ 
in $d$ variables, with maximum degree $k$,
what is the maximum number of 
components of $\mathbb{R}^d$ minus $p(\ldots)=0$?
In other words, into how many pieces can an implicit 
polynomial equation partition $\mathbb{R}^d$?
For example, the following three equations partition
$\mathbb{R}^2$ or $\mathbb{R}^3$ into $3$, $4$, and $2$ pieces
respectively
(I think!):
$$x^3 y^2+x^3 -3 x^2 y -y^2 +4 x y+x=0$$
$$x^6 y^8+x^3+4 x y-y=0$$
$$x^4+3
   \left(x^2+y^4+z\right)-
\left(x^2+y^2+z^2\right)^2+y^3+z^5 + 2 xy=3$$

   

Of course the answer is $k+1$ in $\mathbb{R}^1$.
I suspect this is well known for $\mathbb{R}^d$; 
if so, I would appreciate a pointer.  Thanks!
Update. Greg Martin's idea (from the comments), using the 5th Chebyshev polynomial of the first kind:

         

As Aaron Meyerowitz points out, here the degree $k=10$, and the plane is partitioned into $28$ pieces. But using Pietro Majer's line-arrangement idea leads to (now corrected:) $56$ pieces for a degree $10$ polynomial.
 A: In some contexts (for example, in the study of spherical harmonics), the connected components of the complement of the zero set of a polynomial are called nodal domains.
The maximum number of nodal domains in the real projective plane of a polynomial of degree $d$ (i.e. a homogeneous polynomial in $\mathbb{R}^3$) is bounded above by $d(d-1)+2.$ A nice exposition of this result can be found Leydold's paper On the number of nodal domains of spherical harmonics.
A related result is Harnack's curve theorem. It says that the number of connected components of the zero set of a polynomial in the real projective plane is bounded by $(d-1)(d-2)/2+1$.
A: You are asking for the number of components of the semialgebraic set defined by $P\geq 0.$ It is a classical result that the number of connected components is of order $O(k^d).$ In the below paper, the author gives all the relevant references, and extends the results to estimating higher Betti numbers. 
Basu, Saugata(1-GAIT-CC)
Different bounds on the different Betti numbers of semi-algebraic sets. (English summary) 
ACM Symposium on Computational Geometry (Medford, MA, 2001). 
EDIT In fact, the result is much stronger than a Big-O result: Milnor (in his paper
MR0161339 (28 #4547) Reviewed 
Milnor, J.
On the Betti numbers of real varieties)
Shows that in this situation the upper bound is $\frac12(2+k)(1+k)^{d-1}.$
A: A slightly more general result -- namely on the number of connected components of the non-zeros of a polynomial, restricted to the zeros of another polynomial -- where the degrees of the two polynomials could be different, can be deduced from the main theorem in the paper titled  
"Refined Bounds on the Number of Connected Components of Sign Conditions on a Variety" by Barone and Basu, 
DISCRETE & COMPUTATIONAL GEOMETRY
Volume 47, Number 3 (2012), 577-597, DOI: 10.1007/s00454-011-9391-3
Note that this is a bound only on the number of connected components and not on he higher Betti numbers. I don't know if the added generality is helpful to the original poster.
A: Your example of $f(x,y)=\left(y-T_5(x)\right)\left(x-T_5(y)\right)$ is $$  256\,{x}^{5}{y}^{5}-320\,{x}^{5}{y}^{3}-320\,{x}^{3}{y}^{5}-16\,{x}^{6
}+80\,{x}^{5}y+400\,{x}^{3}{y}^{3}+80\,  x{y}^{5}\\-16\,{y}^{6}+20\,{x}^{4
}-100\,{x}^{3}y-100\,x{y}^{3}+20\,{y}^{4}-5\,{x}^{2}+26\,xy-5\,{y}^{2}
 $$
If I count correctly, it has $28$ regions.
Would that qualify as maximum degree $10?$ If so, then as Pietro points out, $g(x,y)=\prod_{i=1}^{10}\left(a_ix+b_iy+c_i\right)$ will have $56$ regions (if $a_i,b_i,c_i$ are such that the $10$ lines are in general position: no two parallel and no three meeting at a common point). Similar things (as he says) can be done with hyperplane arrangements in higher dimension. You can color the regions $g \gt 0$ white and $g \lt 0$ black so that each region is bounded by regions of the opposite color.
If you want the curve itself to have many disjoint connected components then $g(x,y)+\epsilon$ and $g(x,y)-\epsilon$ are nice to look at. Then all the regions of one color fuse together but each of the others becomes a nicely bordered region. I think that (in the two variable case with a projective viewpoint, at any rate) these achieve that bound given by Harnack's theorem.
