Questions tagged [spline]

A smooth piecewise-defined curve formed by joining segments together, end-to-end. The segments are usually described by polynomial or rational functions. Splines are typically used for approximation or data fitting.

A spline is a special function defined piecewise by polynomials. In interpolating problems, spline interpolation is often preferred to polynomial interpolation because it yields similar results, even when using low degree polynomials, while avoiding Runge's phenomenon for higher degrees.

In the computer science subfields of computer-aided design and computer graphics, the term spline more frequently refers to a piecewise polynomial (parametric) curve. Splines are popular curves in these subfields because of the simplicity of their construction, their ease and accuracy of evaluation, and their capacity to approximate complex shapes through curve fitting and interactive curve design.

644 questions
33
votes
3 answers

What is the relationship between cubic B-splines and cubic splines?

What is the relationship between cubic B-splines and cubic splines?
23
votes
11 answers

What equation produces this curve?

I'm working on an engineering project, and I'd like to be able to input an equation into my CAD software, rather than drawing a spline. The spline is pretty simple - a gentle curve which begins and ends horizontal. Is there a simple equation for…
16
votes
2 answers

How to calculate interpolating splines in 3D space?

I'm trying to model a smooth path between several control points in three dimensions, the problem is that there doesn't appear to be an explanation on how to use splines to achieve this. Are splines a subset of other types of curves such as Bezier…
Saras
  • 263
14
votes
1 answer

Implementation of Monotone Cubic Interpolation

I'm in need to implement Monotone Cubic Interpolation for interpolate a sequence of points. The information I have about the points are x,y and timestamp. I'm much more an IT guy rather than a mathematical person, so I'm looking for an example of…
14
votes
2 answers

Weighting a cubic hermite spline

I am trying to figure out a function behind the software's curve drawing algorithm. Originally, each node comes with 3 parameters : time, value, and tangent. I have found that it fits cubic Hermite spline, and confirmed that using the equation from…
5argon
  • 315
14
votes
10 answers

Motivation of Splines

What is the motivation of splines, in particular cubic splines. For example, why does it matter that they have any type of smoothness at the knots.
user109871
  • 1,517
13
votes
2 answers

Difference between Bezier segment and B-spline

I am currently learning about Bezier curves and splines in computer graphics. What is the difference between a B-spline curve and a curve that consists of Bezier curves as segments? I have read in many sources that B-splines have better properties…
Jag
  • 305
12
votes
2 answers

Convert a B-Spline into Bezier curves

I have a B-Spline curve. I have all the knots, and the x,y coordinates of the Control Points. I need to convert the B-Spline curve into Bezier curves. My end goal is to be able to draw the shape on an html5 canvas element. The B-Spline is coming…
TimSum
  • 221
10
votes
1 answer

Natural cubic splines vs. Piecewise Hermite Splines

Recently, I was reading about a "Natural Piecewise Hermite Spline" in Game Programming Gems 5 (under the Spline-Based Time Control for Animation). This particular spline is used for generating a C2 Hermite spline to fit some given data. I kinda…
10
votes
0 answers

What is the maximum overshoot of interpolating splines in $d$ dimensions?

Consider cubic splines $s( x, y )$ which interpolate values $y = \{ y_0, y_1, \dots,y_n \}$, on the uniform grid $\{ 0, 1,\dots, n \}$. Fix $s''(0) = s''(n) = 0$ (natural splines). How big can $$\operatorname{overshoot}( s; y ) \equiv \max_{0\le…
denis
  • 961
10
votes
2 answers

Bézier approximation of archimedes spiral?

As part of an iOS app I’m making, I want to draw a decent approximation of an Archimedes spiral. The drawing library I’m using (CGPath in Quartz 2D, which is C-based) supports arcs as well as cubic and quadratic Bézier curves. What is a good method…
10
votes
5 answers

Why do we choose cubic polynomials when we make a spline?

Good morning, I want to learn more about cubic splines but unfortunately my class goes pretty quickly and we really only get the high level overview of why they're important and why they work. To me it's clear why we dont use linear functions, we…
John
  • 169
  • 1
  • 1
  • 11
9
votes
2 answers

Cubic B-Spline interpolation

The equation for B-spline with control points $(P_0, P_1,\dots,P_n)$ is \begin{equation} P(t)=\sum_{i=0}^n B_{i,k}(t)P_i \end{equation} If I have the following knots: $1,2,3,4$ and the following control points: $P_1=0$, $P_2=-1$, $P_3=1$ and…
9
votes
3 answers

Measure of curve smoothness

Could someone please give me the intuition behind using integral of squared second derivative as a measure of curve smoothness? I was thinking that since curvature measures how fast a curve changes, should we not be integrating the square of…
Innocent
  • 619
8
votes
1 answer

Clamped B-spline: repeat knots or control points

When we want a B-spline that reaches its first and last control points (clamped B-spline or open uniform B-spline), we can play on the multiplicity of the first and last knot of the knot vector $u = (u_0,...,u_{m})$ for a B-spline of order $k$…
BenC
  • 183
1
2 3
42 43