Understanding B-spline Intervals: Solving for Control Points and Knots

  • Thread starter basty
  • Start date
In summary, the control points are five and they are:b0 = (0,0)b1 = (1,3)b2 = (3,0)b3 = (4,3)b4 = (6,0)The degree d is 2.The number of knots t are 8 and they are:t0 = 0t1 = 1t2 = 2t3 = 3t4 = 4t5 = 5t6 = 6t7 = 7What is the next step to solve this b-spline?The next step to solve this b-spline is to define
  • #1
basty
95
0
Moved from a technical math section
Hi all,

The control points are five and they are:

b0 = (0,0)
b1 = (1,3)
b2 = (3,0)
b3 = (4,3)
b4 = (6,0)

The degree d is 2.

The number of knots t are 8 and they are:

t0 = 0
t1 = 1
t2 = 2
t3 = 3
t4 = 4
t5 = 5
t6 = 6
t7 = 7

What is the next step to solve this b-spline?

Thank you
 
Physics news on Phys.org
  • #2
It's not clear what you mean when you say, "What is the next step to solve this b-spline?"
 
  • #3
You should see the theory to understand what I'm asking about:

B_spline.png
 
  • #4
Looks to me like that's a lot of algebra to crank thru.
 
  • #5
Step 1: define your ##N_{i,0}## basis functions.
Step 2: define your ##N_{i,1}## basis functions in terms of your ##N_{i,0}## basis functions.
Step 3: define your ##N_{i,2}## basis functions in terms of your ##N_{i,1}## basis functions.
Step 4: sum them up to make your ##\mathbf{B}## spline.
If you are comfortable with linear algebra, this looks like something a computer would do a lot faster.
 
  • #6
What I suppose to do with the below equation (the example 8.3)?

##N_{0,1}(t) = \frac{t-t_{0}}{t_{1}-t_{0}}N_{0,0}(t)+\frac{t_{2}-t}{t_{2}-t_{1}}N_{1,0}(t)##
##= \frac{t-2}{4-2}N_{0,0}(t)+\frac{5-t}{5-4}N_{1,0}(t)##
##= \frac{t-2}{2}N_{0,0}(t)+\frac{5-t}{1}N_{1,0}(t)##
##= \frac{t-2}{2}N_{0,0}(t)+(5-t)N_{1,0}(t)##

I can't multiply them because of the ##N_{0,0}(t)## and ##N_{1,0}(t)##.

What is the value of the ##N_{0,0}(t)## and ##N_{1,0}(t)##?

For example, if the value of the ##N_{0,0}(t)## and ##N_{1,0}(t)## is 3 and 4 respectively, then the equation will be:

##\frac{t-2}{2}N_{0,0}(t)+(5-t)N_{1,0}(t)##
##= (\frac{t-2}{2})3+(5-t)4##
##= \frac{3t-6}{2}+(20-4t)##

btw, honestly, this is not a homework.
 
  • #7
First, define all your ##N_{i,0}## functions. Notice that these are only non-zero over the single unit ##[t_i,t_{i+1}]## and on that unit they are 1.
Then, define your ##N_{i,1}## functions.
For example, ##N_{0,1} =\frac{t-0}{1-0}N_{0,0}+\frac{2-t}{2-1}N_{1,0}=t \text{ on }[0,1), = 2-t \text{ on }[1,2)##.
Notice that these are continuous linear functions interpolating your points.
Also, ##N_{1,1} =\frac{t-1}{2-1}N_{1,0}+\frac{3-t}{3-2}N_{2,0}=t-1 \text{ on }[1,2), = 3-t \text{ on }[2,3)##.
Moving on the the ##N_{i,2} ## quadratic basis functions, you have:
##N_{0,2} =\frac{t-0}{2-0}N_{0,1}+\frac{3-t}{3-1}N_{1,1}=\frac{t^2}{2} \text{ on }[0,1), = \frac{2t-t^2}{2}+\frac{(3-t)^2}{2} \text{ on }[1,2)##.
If you are doing this with a computer, it should be much faster than doing it by hand.
Just pay attention to where the functions are non-zero and sum the pieces appropriately.
 
  • #8
Why ##\frac{1}{6}(7-t)^2(1,2)+\frac{1}{3}(-t^2+12t-34)(3,5)+\frac{1}{6}(t-5)^2(6,2)## on ##5≤t<7##?

Why not

##5<t≤7##

or

##5≤t≤7##

or

##2≤t≤4##

or

##?≤t≤?##

and so on?

spl.png
 
  • #9
All the functions should be equal at the nodes, so it is just a matter of only defining each point once. Though for implementation it doesn't impact the method.
 
  • #10
RUber said:
All the functions should be equal at the nodes, so it is just a matter of only defining each point once. Though for implementation it doesn't impact the method.

I am sorry but I still do not understand. Please use a basic english which is easy to understand as english is not my native language.

Why chose 5 <= t < 7 and 7 <= t < 8 (see the image below) for the final step?

proxy.php?image=http%3A%2F%2Fs29.postimg.org%2Fikdekeok7%2Fspl.png
 
  • #11
It does not matter. Both should be equal at t=7.
 
  • #12
RUber said:
It does not matter.

What is does not matter?

RUber said:
Both should be equal at t=7.

Why?
 
  • #13
Does not matter means the result will be te same either way.
A spline is designed to be a continuous function. If they were different at t=7, it would not be continuous.
In any case, if you find it easier to define the point by the right function rather than the left, there should be no problems.
 
  • #14
Why the final answer is 5 <= t < 7 and 7 <= t <= 8?
 
  • #15
Reading definition 8.2 in the material posted above, it says that the final answer will be defined from ##t_d## to ##t_{n-d}##.
Since in this example (8.3), d=2, your interval for the spline will be from ##t_2## to ##t_{6-2}##, which covers the points 5, 7, and 8.
Was this the heart of your misunderstanding?
 

FAQ: Understanding B-spline Intervals: Solving for Control Points and Knots

What is a B-spline?

A B-spline is a mathematical curve that is commonly used in computer graphics and geometric modeling. It is defined by a set of control points and a degree, and is used to create smooth and continuous curves.

How do B-splines help with solving problems?

B-splines are useful for solving a variety of problems in computer graphics and geometric modeling. They can be used to create smooth and continuous curves, which are essential for creating visually pleasing graphics. They are also helpful in approximating complex shapes and curves, and can be used for data interpolation and curve fitting.

What is the process for solving B-spline problems?

The process for solving B-spline problems involves defining the control points and degree of the curve, and then using mathematical algorithms to calculate the curve's shape. This is typically done using computer software, which allows for precise control and manipulation of the curve.

What are the advantages of using B-splines over other curve-fitting methods?

B-splines offer several advantages over other curve-fitting methods. They can accurately approximate complex shapes and curves, and can be easily manipulated and adjusted. They also have a smooth and continuous nature, making them ideal for creating visually appealing graphics.

Are there any limitations to using B-splines?

While B-splines have many advantages, they also have some limitations. They are typically more complex and require more computational power than other curve-fitting methods. Additionally, they may not be suitable for all types of curves, and may not accurately represent sharp or angular features.

Back
Top