Find the next number puzzles

For the discussion of math. Duh.

Moderators: gmalivuk, Moderators General, Prelates

Find the next number puzzles

Postby mchainmail » Wed Dec 21, 2011 5:54 pm UTC

For problems such as "what's the next number in the sequence: ...", I know it is possible to create an nth degree polynomial that satisfies all points. Does anyone have more information on this, or how to go about creating the polynomial?
mchainmail
 
Posts: 10
Joined: Fri Jul 03, 2009 3:21 am UTC

Re: Find the next number puzzles

Postby Qaanol » Wed Dec 21, 2011 6:09 pm UTC

mchainmail wrote:For problems such as "what's the next number in the sequence: ...", I know it is possible to create an nth degree polynomial that satisfies all points. Does anyone have more information on this, or how to go about creating the polynomial?

This should have what you’re looking for. There’s a brief discussion of the matter on Wikipedia as well.
Small Government Liberal
User avatar
Qaanol
 
Posts: 2234
Joined: Sat May 09, 2009 11:55 pm UTC

Re: Find the next number puzzles

Postby Tirian » Wed Dec 21, 2011 8:11 pm UTC

That wikipedia page is a little light on describing or even linking to the most practical method for generating the interpolation polynomial, so here's another link to the Lagrange technique.
Tirian
 
Posts: 1512
Joined: Fri Feb 15, 2008 6:03 pm UTC

Re: Find the next number puzzles

Postby Qaanol » Wed Dec 21, 2011 11:07 pm UTC

Also, if you’re looking at that type of “puzzle”, you’ll probably want the next entry to be an integer. You can either just pick an arbitrary value of your choice and find the polynomial interpolating that, or you can leave that y as a variable to come up with a general expression.
Small Government Liberal
User avatar
Qaanol
 
Posts: 2234
Joined: Sat May 09, 2009 11:55 pm UTC

algorithm for calculating first coefficient

Postby tomtom2357 » Fri Dec 23, 2011 11:40 am UTC

I don't know how to figure out the remaining coefficients of the interpolating polynomial, but here is a (sort of) easy way to find the first coefficient. Let the function f(x1,y1,x2,y2,...) evaluate the first coefficient of the interpolating polynomial between said points (this may seem circular, but recursion is needed to calculate this for more than two points). For two points this is easy f(x1,y1,x2,y2)=(y2-y1)/(x2-x1), now for the recursion bit, f(x1,y1,x2,y2,...,xn-1,yn-1,xn,yn)=(f(x2,y2,x3,y3,...,xn,yn)-f(x1,y1,x2,y2,...xn-1,yn-1))/(xn-x1)
tomtom2357
 
Posts: 426
Joined: Tue Jul 27, 2010 8:48 am UTC


Return to Mathematics

Who is online

Users browsing this forum: GuetraGma and 6 guests