3

I read a little about NURBS curves (specifically from http://www.cs.mtu.edu/~shene/COURSES/cs3621/NOTES/), and I have a couple of questions about the motivation behind the choices made in designing the basis functions.

My current understanding is that, given input knot vector, weights, control points (say we are 1-dimensional as the generalization to higher dimensional curves or surfaces doesn't appear to be a difficulty) and degree, we have basis functions $B_{1},\ldots,B_{n}$ such that each basis function looks like a bump function and the basis functions are a partition of unity. Furthermore, if we assume that knot vector doesn't have multiplicity, then each basis function is in class $C^{d}$, where $d$ is the degree.

My questions are below:

1) The notes say that the support of $B_{i}$ is going to be $d$ intervals in the knot vector. So the support of $B_{i}$ is going to be increasing in the degree $d$. In particular, this seems to me like the curve produced is going to be less local in its dependence on the control points.

By this, I mean that if I move a control point $x_{i}$, then the curve near $x_{i-\lfloor d/2\rfloor},\ldots,x_{i+\lfloor d/2\rfloor}$ are all going to move (whatever the precisely statement is, the interval of control points grows linearly in $d$). Now, this seems like a bad thing, as I would assume we want to have the curve closely approximate the control points and making the curve depend on an interval of control points instead of the closest control point makes this harder.

However, it doesn't seem like a difficult task to make the support of $B_{i}$ smaller, say only two intervals in the knot vector, while still maintaining that it is in class $C^{d}$. I'm sure somebody has thought about this, but I can't find this easily. Why don't people do this?

2) There are examples of bump functions in basic analysis that are $C^{\infty}$. These won't be rational functions like the NURBS basis functions, but why don't we use $C^{\infty}$ bump functions as basis functions? It seems to me that when we increase the degree of the NURBS basis functions, we approximate the control points less closely so we have more regularity (differentiability). But if we use $C^{\infty}$ bump functions, we get a smooth curve.

Thanks for your time.

DCT
  • 3,415

2 Answers2

1

You are right -- increasing degree makes the support of the basis functions wider, so editing becomes more global, less local. This isn't necessarily a bad thing. In fact, people who design very high quality curves typically use Bezier curves (curves that have only one b-spline segment; order = number of control points). With these curves, moving a control point will move every point of the curve (except maybe the end-points). If the system lets you make local edits, then it's very easy to introduce "bumps", i.e. localized regions where the curvature is very different from what it is elsewhere. For high quality curve design, this is highly undesirable, obviously.

Why don't people use (non-polynomial) $C^{\infty}$ basis functions? Well, the basis functions used in the Bezier curves I mentioned above are $C^{\infty}$, because they are polynomials (Bernstein polynomials, actually). In the CAD industry (which is where NURBS are used most, I guess), you can't just make up your own new types of curves, with new types of basis functions. People who use CAD systems often have to exchange data with other people who use other CAD systems, and NURBS are the standard exchange medium -- every system uses them. The benefits of standardisation and easy data exchange far out-weigh any benefits that could be gained by using some exotic new form of curve.

So, people who develop CAD software focus on new/better ways to construct NURBS curves and surfaces, not on making up new types of geometry.

bubba
  • 44,617
  • I'm guessing the $C^{\infty}$ basis functions the OP is asking about are $C^{\infty}$ everywhere, whereas the Bernstein basis functions you're claiming are $C^{\infty}$ are sections of Bernstein polynomials, making them only piecewise $C^{\infty}$, right? So that part of your answer seems a bit misdirected. – Don Hatch Dec 12 '18 at 12:01
  • The Bernstein basis functions are Bernstein polynomials, so they are $C^\infty$ everywhere. Saying it another way, a Bezier curve is a parametric polynomial curve, and so it's $C^\infty$. Maybe you're thinking about spline curves that are constructed by stringing together Bezier curves. These are only piecewise $C^\infty$, certainly. – bubba Dec 17 '18 at 08:32
  • Yes, I'm certainly thinking about spline curves that are constructed by stringing together pieces of Bezier curves. If I understand correctly, that's what a NURBS curve is, so that's what this question is about. Am I missing something? – Don Hatch Dec 18 '18 at 02:42
  • I think I shouldn't have gone along with the words "Bernstein basis functions". What I meant to be referring to is what I believe the OP was asking about-- that is, the bump function for a given control point of a NURBS curve. That function, derived from Bernstein polynomials, is certainly only piecewise $C^{\infty}$, so the OP's question about it seems reasonable: why don't we commonly use a bump function that is $C^{\infty}$ instead? – Don Hatch Dec 18 '18 at 07:11
  • So, maybe the question is : are there basis functions that look like b-splines (compact support, non-negaitive, partition of unity) and are $C^\infty$? I suppose there are, but they are not piecewise polynomials, so they would cause data exchange problems in CAD/CAM. As I said in my answer, people who want $C^\infty$ curves use Bezier curves. – bubba Dec 18 '18 at 11:06
  • I've posted an answer that shows such a scheme. The very interesting question of its merit relative to NURBS and Bezier curves remains unanswered (other than the mundane concerns of backwards compatibility and data exchange). – Don Hatch Dec 26 '18 at 05:40
1

The following four terms are often conflated in the spline curve literature and in many peoples' minds:

  • (1) lower quality / higher quality (an ambiguous term, maybe best avoided)
  • (2) more local control / more global control
  • (3) less smooth / more smooth (an ambiguous term, maybe best avoided)
  • (4) number of continuous derivatives

This conflation might be, at least in part, due to the fact that, for the particular cases of B-Spline and NURBS curves, (2) and (4), and at least one definition of (3) and (1), happen to be the same; that is, as we move to higher degree polynomials, we simultaneously get more global control, more continuous derivatives (i.e. "smoother", at least for one definition of the word) and higher quality (again, for at least one definition of the word). Another contributer to the conflation is that the words "smoother" and "smooth" can mean, informally, "higher quality", or it can mean, formally, "has a relatively high number of continuous derivatives" and "$C^{\infty}$" respectively. This all ends up being quite misleading and confusing.

So I'll avoid talking about (1) since the words "high quality" are really meaningless by themselves; really any criterion at all could be considered high quality, depending on the application one has in mind, so I think anyone who uses those words ought to first define them and explain their rationale. I won't attempt to do so here.

Likewise, I'll avoid the words "smoother" and "smooth" since the misleading ambiguity of these words seems to be a big contributor to all of these concepts getting tangled up, as I already said.

So that leaves (2) and (4), which definitely aren't the same. To show they aren't the same, I'll just give an example of a scheme that yields $C^{\infty}$ curves and yet has local control; I think this is pretty much what you had in mind. I don't claim this result is "high quality" in any sense, and I probably wouldn't use it for anything, although I can't put my finger on exactly what about it seems bad.

My example has the same definition as the B-spline basis functions for NURBS curves, except that $f_{i,1}$ and $g_{i,1}$, instead of rising/falling linearly from $0$ to $1$, follow a $C^{\infty}$ transition function from $0$ to $1$ or from $1$ to $0$ respectively.

For comparison, here are the standard NURBS basis functions of various degrees with nine knots $0,1,2,3,4,4.1,5.1,6.1,7.1$, as in the wikipedia article: [IMAGE 1]

And here are the modified NURBS basis functions, constructed with modified $f_{i,1}$ and $g_{i,1}$ as described above: [IMAGE 2] (There is an interactive version of the above pictures, where you can add, move, and delete knots, here on codepen.)

These modified basis functions satisfy the following properties:

  • non-negative
  • compact support
  • partition of unity (true for order 2 since it's true for the modified $f_{i,1}$ and $g_{i,1}$, and can be proved by induction for higher orders, just like for NURBS)
  • for order >= 2, the basis functions, and therefore the resulting curves, are $C^{\infty}$ everywhere (unlike NURBS)

Your question "why aren't schemes such as this used" remains unanswered, but maybe at least the question is clearer now.

It's a very interesting question. I would be interested to know what the advantages and disadvantages are of such modified NURBS (or any other such $C^{\infty}$ variation). Aside from uninteresting issues of non-compatibility with existing software, does a scheme such as this have merit or not? It seems like these modified NURBS have all the usual advantages of NURBS, plus $C^{\infty}$ continuity, which is often touted as a good thing, but at this point I'm not sure why.

There's certainly something not-so-nice about these curves-- they seem rather bumpy and unattractive compared to NURBS, although I can't quantify this statement. Can it be quantified reasonably, in a way that makes it clear that NURBS is objectively better? And is there perhaps a variation that is not as bumpy, and more attractive?

I'd like to understand these things better.

Don Hatch
  • 1,277
  • If you'd like to understand what "smooth" means in design/engineering/manufacturing, then you might benefit from reading this answer: https://math.stackexchange.com/questions/2496490/motivation-of-splines/2499704#2499704 – bubba Dec 27 '18 at 06:45
  • Compatibility and data exchange issues cannot be trivilialized. They have a major impact on the adoption of new technologies in many industries. In other words, they form a large part of the answer to the "why don't people use ..." question. The geometry types used in design/engineering/manufacturing has been pretty stable for the last 3 decades, and this has made data exchange feasible. New types of geometry will probably not be adopted unless they have huge benefits over current forms. – bubba Dec 27 '18 at 06:50
  • @bubba, thanks for the smoothness references. I don't see anything surprising there-- the theme seems to be that various degrees of smoothness, in the sense of multiple-differentiability, are important and necessary for some purposes. This simple $C^{\infty}$ NURBS variant I've described meets all those criteria-- it's $C^0$, $C^1$, $C^2$, $G^0$, $G^1$, $G^2$, etc. So the question remains: is it any good? Clearly not, but why not? – Don Hatch Dec 27 '18 at 17:23
  • @bubba Regarding data exchange issues, yes, I believe you that everyone's done it this way for 30 years and will probably continue to do it this way, but come on, do you really think that's the point of this math question? I, like the OP, am very interested in "the motivation behind the choices made in designing the basis functions", in particular, whether this (or any other) low-order small-support $C^{\infty}$ NURBS variant can compete in terms of merit, independent of the obvious backward compatibility issues. Can we talk about that? – Don Hatch Dec 27 '18 at 17:31
  • Thanks for the pictures and the website! I found them very interesting. I still know nothing about this field (learned about NURBS years ago to try to help an engineering friend with software), but is it possible the higher derivatives of the $C^{\infty}$ NURBS variant you used are larger (maximum absolute value) than the derivatives of the usual NURBS basis functions? – DCT Dec 27 '18 at 19:17
  • 1
    @DCT Yes, and I guess that's unavoidable-- if I'm reading the answers to these questions correctly, the derivatives of any such function grow extremely fast. https://math.stackexchange.com/questions/1590123/does-a-smooth-transition-function-with-bounded-derivatives-exist and https://math.stackexchange.com/questions/1768732/do-there-exist-bump-functions-with-uniformly-bounded-derivatives – Don Hatch Dec 28 '18 at 01:32