MATLAB Programming B-spline curve in Matlab from scratch

Click For Summary
The discussion revolves around a coding problem related to implementing B-spline curves. The user is trying to understand how to calculate the basis functions for each value of u, while also considering the control points and the order of the spline. There is confusion about the placement of the blending function P(u) within the code, particularly regarding its position in relation to the inner loop for u. Another participant confirms that they have tested the user's code and found it functional, while also requesting a MATLAB code example for plotting the B-spline curve using the basis functions. The conversation highlights the need for clarity in code structure and the sharing of resources for better understanding and implementation of B-spline curves.
roldy
Messages
206
Reaction score
2
I decided to write my problem and attach as a separate document so that everything was included and would leave room here to discuss my problem.

From what I understand from the equations is that for each value of u I calculate the value of the basis function for each basis function i. Then this is multiplied by the control point. This is done for each order k. The thing that I don't understand is that how can I pull this off if u is the inner most loop? I'm not sure the proper placement of the blending function P(u).

Could someone take a look at my code and logic and see if there is another way of doing this or shoot me some pointers? It would be greatly appreciated.
 

Attachments

Physics news on Phys.org
hi my friend, :)
I see your code.
I test it and it works good,but did you write a MATLAB code for using Basis-function to plot B-spline curve?!
could you upload it for me?
thanks.
 

Similar threads

  • · Replies 2 ·
Replies
2
Views
3K
  • · Replies 2 ·
Replies
2
Views
3K
  • · Replies 32 ·
2
Replies
32
Views
4K
  • · Replies 1 ·
Replies
1
Views
12K
  • · Replies 10 ·
Replies
10
Views
3K
  • · Replies 22 ·
Replies
22
Views
4K
  • · Replies 9 ·
Replies
9
Views
4K
  • · Replies 1 ·
Replies
1
Views
3K
  • · Replies 8 ·
Replies
8
Views
2K
  • · Replies 1 ·
Replies
1
Views
2K