A spline is a type of piecewise polynomial function. In mathematics, splines are often used in a type of interpolation known as spline interpolation. Spline curves are also used in computer graphics and computer-aided design (CAD) to approximate complex shapes.
Interpolation is used when there is a set of discrete data points and it is necessary to estimate other points of the same type of data from the given points. Polynomial interpolation is commonly used for small numbers of data points; this is a method that fits an n order polynomial function to n + 1 data points. When the number of points becomes larger, however, polynomial interpolations often do not fit the data well. In these cases, spline interpolation is often used instead.
While polynomial interpolation fits a curve through all the data points at once, spline interpolation approximates a curve between each proximate pair of data points and adds all the curves together to create the final approximation. This is why splines are piecewise functions rather than smooth curves. Commonly used spline interpolation techniques include linear, quadratic, and cubic interpolation.
Linear spline interpolation simply fits straight lines through each consecutive pair of data points. Each line section may have a similar or very different slope from the other section, depending on the distribution of the data. To find the y value on a Cartesian coordinate system for a given x value between two data points, the slope between the given points is multiplied by the distance between the x value for which the y value is desired and the x value for the point to its left. This number is then added to the y value to the left of the desired location to obtain the approximation for the y value between the two points.
Quadratic spline interpolation approximates the data between consecutive points by a quadratic polynomial. To find the coefficients of these quadratic equations, a number of methods for solving simultaneous equations may be applied. Linear algebra techniques or solving by use of computer software are some of the more common techniques used. An interpolated y value on a quadratic spline is found by using the general quadratic equation, y = a*x_{2} + b*x + c, with the a, b, and c coefficients previously determined.
Cubic spline interpolation uses a cubic, or third order, polynomial function to approximate the data between consecutive points. This type of spline is usually calculated using computer software or a graphing calculator. A special type of cubic spline interpolation, called clamped or complete spline interpolation, uses slopes given at the ends of the curve to help compute the function.
exception 'Exception' with message 'error writing captcha: Duplicate entry '2147483647' for key 'PRIMARY'' in /ssd/www/wisegeek/public_html/_core/classes/public/Captcha.php:44 Stack trace: #0 /ssd/www/wisegeek/public_html/_core/controls/public/ControlDiscussionPostBox.php(324): Captcha->createCaptcha() #1 /ssd/www/wisegeek/public_html/framework/classes/Control.php(104): ControlDiscussionPostBox->preRender(false) #2 /ssd/www/wisegeek/public_html/framework/classes/Control.php(149): Control->render() #3 /ssd/www/wisegeek/public_html/tpl/default-nocustom-lu/pages/public/article/article.htm(526): Control->__toString() #4 /ssd/www/wisegeek/public_html/framework/classes/Control.php(300): require('/ssd/www/wisege...') #5 /ssd/www/wisegeek/public_html/framework/classes/Control.php(309): Control->requireTpl('pages/public/ar...', Object(PageArticleCom), true) #6 /ssd/www/wisegeek/public_html/framework/classes/Control.php(131): Control->renderTpl('pages/public/ar...', Object(PageArticleCom)) #7 /ssd/www/wisegeek/public_html/framework/classes/FormDataControl.php(87): Control->renderTemplate() #8 /ssd/www/wisegeek/public_html/framework/classes/Control.php(109): FormDataControl->renderTemplate() #9 /ssd/www/wisegeek/public_html/framework/classes/ScriptPage.php(50): Control->render(false) #10 /ssd/www/wisegeek/public_html/framework/classes/Control.php(149): ScriptPage->render() #11 /ssd/www/wisegeek/public_html/framework/classes/Page.php(97): Control->__toString() #12 /ssd/www/wisegeek/public_html/_core/classes/public/PublicFrontController.php(443): Page->processRequest() #13 /ssd/www/wisegeek/public_html/_core/classes/public/PublicFrontController.php(7): PublicFrontController->renderPage() #14 /ssd/www/wisegeek/public_html/index.php(11): PublicFrontController::run() #15 {main}