(1+ax)/(1+bx)
= 1+(a-b)x+(b^2-ab)x^2
is this correct upto x^2 terms?
thanks
$\displaystyle \frac{(1+ax)}{(1+bx)}=$
$\displaystyle =(1+ax) * (1+bx)^{-1}$
Now we expand $\displaystyle =(1+bx)^{-1}$
$\displaystyle =1+\frac{-1}{1} * (bx)^1 + \frac{(-1) * (-2)}{1 * 2} * (bx)^2$
$\displaystyle =1-bx + b^2 * x^2$
Hence, your initial expression will be:
$\displaystyle =(1+ax) * (1-bx + b^2 x^2)$
$\displaystyle =1-bx+b^2x^2 +ax-abx^2$
$\displaystyle =1+(a-b)x+(b^2-ab)x^2 $
So yes, your expansion is correct.
It's correct! I happen to find the following method to be better than the binomial theorem:
$\displaystyle \begin{aligned}\displaystyle \frac{1+ax}{1+bx} & = (1+ax)\sum_{k\ge 0}(-1)^kb^kx^k = \sum_{k\ge 0}(-1)^k\left(ab^kx^{k+1}+b^kx^k\right) \\& = (ax+1)-(abx^2+bx)+(ab^2x^3+b^2x^2)- \cdots \\& = 1+(a-b)x+(b^2-ab)x^2+\cdots\end{aligned} $