B-Spline basis function

Started by
6 comments, last by ryt 15 years, 9 months ago
This is basis function of a B-Spline: Look at the second term. See the Bj+1,n-1(t). J is the control point and N is order. Lets say we have 4 control points and we want to compute a Point at some value of t. Imagine we did some calculations and we need compute basis function for 4-th control point. We start to look for j+1, n-1. N-1 is ok since we have calculated lower orders before. But what abaut j+1, we are at 4-th control point, and j+1 is 5-th control point. How we can solve for 5-th control point since it does not exist? It is out of bounds. Did I understand something wrong or this is some wierd way?
Advertisement
No, The basis functions doesn’t depends on control points but on knots. Every B-Spline of degree d is defined by a sequence of m+1 non-decreasing real numbers and n+1 control points where m = n + d + 1. t0...tm are the knots and not the control points. bj,n-1, bj+1,n-1 are the basis functions of a B-Spline of one degree less than the basis function you are calculating.
The B-spline is then defined by: sum_{i=0}^{n} bibi,d(t) where the bi are the control points.

Look at the The de Boor algorithm for a different way to calculate points on the curve (similar to the de Casteljau algorithm for Bézier curve).
Yes, but we have one basis function for every control point.
Bi are the basis functions for every control point, and in recursive formula for finding basis function the Bj+1,n-1 is indexing into j+1 n-1 wich means "for this control point (bi) + 1, on a previous degree (n-1)".
But how (bi) + 1 if we are calculating for 4-th control point, than this means 4+1 = 5.
The basis functions have nothing to do with the control points. If you apply the formula you gave to the general formula you will see that the basis function Bi+1,d-1 is multiplied by the ith control point even if his index is i+1.
mmm, Ill have to go step by step and see how it calculates
The formula become:

sum{i=0}{n} bi(αi,dBi,d-1 + βi,dBi+1,d-1)

where
αj,n = (t - tj)/(tj+n - tj)
βj,n = (tj+n+1 - t)/(tj+n+1 - tj+1)
@ryt: I think you're just forgetting that there are going to be more knots than control points, and that the basis function operates on knots. For a cubic B-spline, you will have 2 additional knots on both ends of the vector (for a total of d + 1 extra).
yeah, I knew that but I forgot, apatriarca mentiond it but I havent realize it, thx

This topic is closed to new replies.

Advertisement