Two examples, one with all simple knots while the other with multiple knots, will be discussed in some detail on this page.
The following table gives the result of all N_{i,1}(u)'s:
Basis Function | Range | Equation |
N_{0,1}(u) | [0, 0.25) | 4u |
[0.25, 0.5) | 2(1 - 2u) | |
N_{1,1}(u) | [0.25, 0.5) | 4u - 1 |
[0.5, 0.75) | 3 - 4u | |
N_{2,1}(u) | [0.5, 0.75) | 2(2u - 1) |
[0.75, 1) | 4(1 - u) |
The following shows the graphs of these basis functions. Since the internal knots 0.25, 0.5 and 0.75 are all simple (i.e., k = 1) and p = 1, there are p - k + 1 = 1 non-zero basis function and three knots. Moreover, N_{0,1}(u), N_{1,1}(u) and N_{2,1}(u) are C^{0} continuous at knots 0.25, 0.5 and 0.75, respectively.
From N_{i,1}(u)'s, one can compute the basis functions of degree 2. Since m = 4, p = 2, and m = n + p + 1, we have n = 1 and there are only two basis functions of degree 2: N_{0,2}(u) and N_{1,2}(u). The following table is the result:
Basis Function | Range | Equation |
N_{0,2}(u) | [0, 0.25) | 8u^{2} |
[0.25, 0.5) | -1.5 + 12u - 16 u^{2} | |
[0.5, 0.75) | 4.5 - 12u + 8 u^{2} | |
N_{1,2}(u) | [0.25, 0.5) | 0.5 - 4u + 8u^{2} |
[0.5, 0.75) | -1.5 + 8u - 8u^{2} | |
[0.75, 1) | 8(1 - u)^{2} |
The following figure shows the two basis functions. The three vertical blue lines indicate the positions of knots. Note that each basis function is a composite curve of three degree 2 curve segments. For example, N_{0,2}(u) is the green curve, which is the union of three parabolas defined on [0,0.25), [0.25, 0.5) and [0.5,0.75). These three curve segments join together forming a smooth bell shape. Please verify that N_{0,2}(u,) (resp., N_{1,2}(u)) is C^{1} continuous at its knots 0.25 and 0.5 (resp., 0.5 and 0.75). As mentioned on the previous page, at the knots, this composite curve is of C^{1} continuity.
Consider a knot vector U = { 0, 0, 0, 0.3, 0.5, 0.5, 0.6, 1, 1, 1 }. Thus, 0 and 1 are of multiplicity 3 (i.e., 0(3) and 1(3)) and 0.5 is of multiplicity 2 (i.e., 0.5(2)). As a result, m = 9 and the knot assignments are
u_{0} | u_{1} | u_{2} | u_{3} | u_{4} | u_{5} | u_{6} | u_{7} | u_{8} | u_{9} |
0 | 0 | 0 | 0.3 | 0.5 | 0.5 | 0.6 | 1 | 1 | 1 |
Let us compute N_{i,0}(u)'s. Note that since m = 9 and p = 0 (degree 0 basis functions), we have n = m - p - 1 = 8. As the table below shows, there are only four non-zero basis functions of degree 0: N_{2,0}(u), N_{3,0}(u), N_{5,0}(u) and N_{6,0}(u).
Basis Function | Range | Equation | Comments |
N_{0,0}(u) | all u | 0 | since [u_{0}, u_{1}) = [0,0) does not exist |
N_{1,0}(u) | all u | 0 | since [u_{1}, u_{2}) = [0,0) does not exist |
N_{2,0}(u) | [0, 0.3) | 1 | |
N_{3,0}(u) | [0.3, 0.5) | 1 | |
N_{4,0}(u) | all u | 0 | since [u_{4}, u_{5}) = [0.5,0.5) does not exist |
N_{5,0}(u) | [0.5, 0.6) | 1 | |
N_{6,0}(u) | [0.6, 1) | 1 | |
N_{7,0}(u) | all u | 0 | since [u_{7}, u_{8}) = [1,1) does not exist |
N_{8,0}(u) | all u | 0 | since [u_{8}, u_{9}) = [1,1) does not exist |
Then, we proceed to basis functions of degree 1. Since p is 1, n = m - p - 1 = 7. The following table shows the result:
Basis Function | Range | Equation |
N_{0,1(u) } | all u | 0 |
N_{1,1(u) } | [0, 0.3) | 1 - (10/3)u |
N_{2,1(u) } | [0, 0.3) | (10/3)u |
[0.3, 0.5) | 2.5(1 - 2u) | |
N_{3,1(u) } | [0.3, 0.5) | 5u - 1.5 |
N_{4,1(u) } | [0.5, 0.6) | 6 - 10u |
N_{5,1(u) } | [0.5, 0.6) | 10u - 5 |
[0.6, 1) | 2.5(1 - u) | |
N_{6,1(u) } | [0.6, 1) | 2.5u - 1.5 |
N_{7,1(u) } | all u | 0 |
The following figure shows the graphs of these basis functions.
Let us take a look at a particular computation, say N_{1,1}(u). It is computed with the following expression:
Plugging u_{1} = u_{2} = 0 and u_{3} = 0.3 into this equation yields the following:
Since N_{1,0}(u) is zero everywhere, the first term becomes 0/0 and is defined to be zero. Therefore, only the second term has an impact on the result. Since N_{2,0}(u) is 1 on [0,0.3), N_{1,1}(u) is 1 - (10/3)u on [0,0.3).
Next, let us compute all N_{i,2}(u)'s. Since p = 2, we have n = m - p - 1 = 6. The following table contains all N_{i,2}(u)'s:
Basis Function | Range | Equation |
N_{0,2}(u) | [0, 0.3) | (1 - (10/3)u)^{2 } |
N_{1,2}(u) | [0, 0.3) | (20/3)(u - (8/3)u^{2}) |
[0.3, 0.5) | 2.5(1 - 2u)^{2} | |
N_{2,2}(u) | [0, 0.3) | (20/3)u^{2} |
[0.3, 0.5) | -3.75 + 25u - 35u^{2} | |
N_{3,2}(u) | [0.3, 0.5) | (5u - 1.5)^{2} |
[0.5, 0.6) | (6 - 10u)^{2} | |
N_{4,2}(u) | [0.5, 0.6) | 20(-2 + 7u - 6u^{2}) |
[0.6, 1) | 5(1 - u)^{2} | |
N_{5,2}(u) | [0.5, 0.6) | 20u^{2} - 20u + 5 |
[0.6, 1) | -11.25u^{2} + 17.5u - 6.25 | |
N_{6,2}(u) | [0.6, 1) | 6.25u^{2} - 7.5u + 2.25 |
The following figure shows all basis functions of degree 2.
Let us pick a typical computation as an example, say N_{3,2}(u). The expression for computing it is
Plugging in u_{3} = 0.3, u_{4} = u_{5} = 0.5 and u_{6} = 0.6 yields
Since N_{3,1}(u) is non-zero on [0.3, 0.5) and is equal to 5u - 1.5, (5u - 1.5)^{2} is the non-zero part of N_{3,2}(u) on [0.3, 0.5). Since N_{4,1}(u) is non-zero on [0.5, 0.6) and is equal to 6 - 10u, (6 - 10u)^{2} is the non-zero part of N_{3,2}(u) on [0.5, 0.6).
Let us investigate the continuity issues at knot 0.5(2). Since its multiplicity is 2 and the degree of these basis functions is 2, basis function N_{3,2}(u) is C^{0} continuous at 0.5(2). This is why N_{3,2}(u) has a sharp angle at 0.5(2). For knots not at the two ends, say 0.3, C^{1} continuity is maintained since all of them are simple knots.