# Derive Equation from the set of values

I have a set of values

$$\begin{array}{|c|c|} \hline\text{X} & \text{Y} \\ \hline 1 & 2 \\ \hline 2 & 10 \\ \hline 3 & 30 \\ \hline 4 & 68 \\ \hline \end{array}$$

Looking at the above numbers, I have done trial and error options and found the formula $Y=X^3 + X$ to get the value for $X=5$ to be 130.

Is there any mathematical theorem or algebraic way to find the above value without trial and error method. what is the best way to get the above formula mathematically? Any pointers to related subjects using which we can derive the equation would be very helpful.

Thanks,

Rajesh.

• Look up regression and interpolation. – Batman Mar 30 '15 at 17:06
• If you're interested in math, try to prove that there is an unique polynomial of grade at least $n$ that $f(x_0)=y_0 \ldots f(x_n)=y_n$ for given $x_i$s and $y_i$s. – Leonhardt von M Mar 30 '15 at 17:21
• I will edit your answer because writing "$1=02$", "$2=10$" is nonsense. – JP McCarthy Apr 27 '15 at 10:35

If a finite number (the first few) of terms of a sequence are given and if that sequence is:-

(1) in Arithmetic Progression; or

(2) in Geometric Progression; or

(3) in some nicely behaved pattern (like a Harmonic Progression or a Fibonacci Sequence ),

then answer is YES – a formula for the general term can be found.

Otherwise is NO, because the values of the first few terms can come up from nowhere without any specific pattern.

Furthermore, there is a bad news for some and unfairness to those who are required to guess the pattern. This is because even if that formula has been eventually "guessed correctly", it is still not unique.

To see why, refer to my answer in

Technique for finding the nth term