A simple expansion Where I am doing wrong? if any one can tell!!!
I have done this equation as
$$y ={x\over 1+(x-x^4+x^7)^3} = x [1+(x-x^4+x^7)^3]^{-1}$$
$$y= x[ 1-(x-x^4+x^7)^3+...]$$
$$y= x[ 1-(x^3+x^{12}+x^{21}-3x^6+3x^{9}+3x^9+3x^{15}+3x^{15}-3x^{18})+...] $$ 
$$y= x[ 1-x^3-x^{12}-x^{21}+3x^6-3x^9-3x^9-3x^{15}-3x^{15}+3x^{18}+...]$$
$$y= x-x^4+3x^7+...$$
But in book it is written as,
$$y= x-x^4+4x^7+...$$

Since $\frac1{1+x}=1-x+x^2-x^3+\dots$, we need to include at least one more term to get the series correct to $x^7$.
$$
\frac{x}{1+\left(x-x^4+x^7\right)^3}=x-x^4+4x^7+O\left(x^{10}\right)
$$
Using two terms, that is, $\frac1{1+x}=1-x$, we get
$$
x\left(1-\left(x-x^4+x^7\right)^3\right)=x-x^4+3x^7+O\left(x^{10}\right)
$$
However, if we include three terms, that is, $\frac1{1+x}=1-x+x^2$, we get
$$
x\left(1-\left(x-x^4+x^7\right)^3+\left(x-x^4+x^7\right)^6\right)=x-x^4+4x^7+O\left(x^{10}\right)
$$
