$ \lim_{x \to \infty} [\frac{x^2+1}{x+1}-ax-b]=0 \ $ then show that $ \ a=1, \ b=-1 \ $ $ \lim_{x \to \infty} [\frac{x^2+1}{x+1}-ax-b]=0 \ $ then show that $ \ a=1, \ b=-1 \ $
Answer:
$ \lim_{x \to \infty} [\frac{x^2+1}{x+1}-ax-b]=0 \\ \Rightarrow  \lim_{x \to \infty} [\frac{x^2+1-ax^2-ax-bx-b}{x+1}]=0 \\ \Rightarrow \lim_{x \to \infty} \frac{2x-2ax-a-b}{1}=0 \\ \Rightarrow 2x-2ax-a-b=0  \ \ (?)  $ 
Comparing both sides , we get 
$ 2-2a=0 \\ a+b=0 \ $
Solving , we get 
$ a=1 , \ b=-1 \ $
But I am not sure about the above line where question mark is there.
Can you help me?

Let $f(x)=\dfrac{x^2+1}{x+1}$. If
$$
\lim_{x\to\infty}(f(x)-ax-b)=0
$$
then also
$$
\lim_{x\to\infty}\frac{f(x)-ax-b}{x}=0
$$
Thus we must have
$$
\lim_{x\to\infty}\left(\frac{x^2+1}{x(x+1)}-a\right)=0
$$
and therefore $a=1$. Now
$$
\frac{x^2+1}{x+1}-x=\frac{x^2+1-x^2-x}{x+1}=\frac{-x}{x+1}
$$
so
$$
\lim_{x\to\infty}(f(x)-x-b)=-1-b
$$
and therefore $b=-1$.
