Let f(x) be a polynomial satisfying $\lim_{x \to\infty} \frac{x^4f(x)}{x^8+1}=3,$ $f(2)=5 $ and $f(3)=10$, $f(-1)=2$ and $f(-6)=37$ Let f(x) be a  polynomial satisfying $\lim_{x \to\infty} \frac{x^4f(x)}{x^8+1}=3,$ $f(2)=5 $ and $f(3)=10$, $f(-1)=2$ and $f(-6)=37$ .
And then there are some question related to this.
In the solution it is given that according to the given information, $f(x)$ is a polynomial of degree 4 with leading coefficient 3.
$f(x)=3(x-2)(x-3)(x+1)(x+6)+(x^2+1)$
Now what i think is that he got the coefficient 3 using the limits and the rest of the terms$[(x-2)(x-3)(x+1)(x+6)]$ from the respective $f(x)$ values from what was given and also the $(x^2+1)$ was added for the remainders, as they satisfy all the values that have been given to us in the question. I just wanted to know if my approach is right? or is there another elegant way to do it?.
 A: Consider the limit
$$\lim_{x \to\infty} \frac{x^4f(x)}{x^8+1}$$
$$\lim_{x \to\infty}\frac{f(x)}{x^4+\frac{1}{x^4}}$$
Since limit is finite and is equal to 3,we observe that $f(\infty) \rightarrow \infty $
Also $f^2(\infty)\rightarrow \infty$ , $f^3(\infty)\rightarrow \infty$
But after diffrentiating four times (L` Hospital rule),we see that $f^4(\infty)=72$ which implies that $ f(x)$ must be four degree polynomial
Given that $f(2)=5,f(3)=10,f(-1)=2,f(-6)=37$
Observe that output of function is input squared plus 1, so we must have $x^2+1$ involving in function
Let $f(x)=k(x-2)(x-3)(x+1)(x+6)+x^2+1$, since we don't know leading cofficient
Using, $f^4(\infty)=72$ ,we got $k=3 $
A: Another possibility is to use Lagrange polynomials, and express $f(x)$ as a function that has the given four values in the given points plus a term that produces the given leading term coefficient, but vanishes in all four points:
\begin{align}
f(x)=\ 
&y_1\frac{(x-x_2)(x-x_3)(x-x_4)}{(x_1-x_2)(x_1-x_3)(x_1-x_4)}+\\
&y_2\frac{(x-x_1)(x-x_3)(x-x_4)}{(x_2-x_1)(x_2-x_3)(x_2-x_4)}+\\
&y_3\frac{(x-x_1)(x-x_2)(x-x_4)}{(x_3-x_1)(x_3-x_2)(x_3-x_4)}+\\
&y_4\frac{(x-x_1)(x-x_2)(x-x_3)}{(x_4-x_1)(x_4-x_2)(x_4-x_3)}+\\
&a(x-x_1)(x-x_2)(x-x_3)(x-x_4)\\
=\ 
&-\frac{5}{24}(x-3)(x+1)(x+6)+\\
&+\frac{5}{18}(x-2)(x+1)(x+6)+\\
&+\frac{1}{30}(x-2)(x-3)(x+6)+\\
&-\frac{37}{360}(x-2)(x-3)(x+1)+\\
&3(x-2)(x-3)(x+1)(x+6)
\end{align}
A: the correct and precise reason for writing f(x)=3(x−2)(x−3)(x+1)(x+6)+(x^2+1) is as follows (I am assuming you have understood why f(x) will be a 4th deg polynomial and how its leading coeff shall be 3 from other answers):
consider g(x)= f(x)-(x^2+1)
clearly, deg(g(x))= 4
now, g(2)= f(2)-(2^2+1)= 0
similarly, g(3)=g(-1)=g(-6)= 0
hence, we have 4 roots of g(x) as 2, 3, -1, -6.
hence, by factor theorem g(x)= A(x−2)(x−3)(x+1)(x+6) where A is a constant.
or f(x)-(x^2+1)= A(x−2)(x−3)(x+1)(x+6)
or f(x)= A(x−2)(x−3)(x+1)(x+6)+x^2+1
but A=3 (already seen).
hence f(x)=3(x−2)(x−3)(x+1)(x+6)+(x^2+1)
