<p>A simple example of taking a the derivative of a B'ezier curve can be shown using a cubic curve.</p>
<p><span class="math-container">$$C_3(u) = \sum_{i=0}^3 B_{3,i}(u) P_i,$$</span> where <span class="math-container">$u \in [0,1]$</span> and <span class="math-container">$B_{n,i} = {n \choose i} u^i (1-u)^{n-i}$</span> is the <span class="math-container">$i$</span>-th Bernstein polynomial of degree <span class="math-container">$n$</span>. <span class="math-container">$P_i$</span> are the control points.</p>
<p>written out it is:</p>
<p><span class="math-container">$$C_3(u) = (1-u)^3 P_0 + 3(1-u)^2 u P_1 + 3 (1-u)u^2 P_2 + u^3 P_3$$</span></p>
<p>we can differentiate this with respect to u</p>
<p><span class="math-container">$$\frac{\partial}{\partial u} C_3(u) = -3(1-u)^2 P_0 - 6(1-u) u P_1 + 3(1-u)^2 P_1 - 3 u^2 P_2 + 6 (1-u)u P_2 + 3u^2 P_3. $$</span></p>
<p>Now we can rearrange the terms</p>
<p><span class="math-container">$$\frac{\partial}{\partial u} C_3(u) =  3 \left((1-u)^2 (P_1-P_0) + 2(1-u) u (P_2 - P_1)  +  u^2 (P_3 - P_2) \right), $$</span> or</p>
<p><span class="math-container">$$\frac{\partial}{\partial u} C_3(u) = 3 (\sum_{i=0}^2 B_{2,i}(u) (P_{i+1} - P_i))$$</span></p>
<p>We obtain a quadratic B'ezier curve where the control points are the vectors between the initial control points, scaled by a factor <span class="math-container">$3$</span>. Therefore the derivative of a Bezier curve of degree <span class="math-container">$n$</span> is a B'ezier curve of degree <span class="math-container">$n-1$</span>, where the control points are difference between initial control points scaled by <span class="math-container">$n$</span>.</p>
<p>so:</p>
<p><span class="math-container">$$\frac{\partial}{\partial u} \sum_{i=0}^n B_{n,i}(u) P_i = n (\sum_{i=0}^2 B_{n-1,i}(u) (P_{i+1} - P_i))$$</span></p>

CC BY-SA 4.0
2021-01-09T23:16:39.080Z
Can you explain what does `B_3` in the formulas mean?
user14063792468
CC BY-SA 4.0
2021-01-10T20:18:20.920Z
They are the cubic Bernstein polynomials. I added their definitions.
Reynolds
CC BY-SA 4.0
2021-01-10T20:43:02.207Z
@Reynolds the `wikipedia` page seem to have a wrong image for the formula. Or browser's `javascript` is broken. Anyway, thank you. Please reply with a `@`, so one will get notified about your reply.
user14063792468
CC BY-SA 4.0
2021-01-08T19:11:34.137Z
2021-01-11T18:54:44.863Z
2021-01-11T18:54:44.863Z
Reynolds
<p>I want to know how to take the derivative of a Bézier curve. I visited this website <a href="https://pages.mtu.edu/%7Eshene/COURSES/cs3621/NOTES/spline/Bezier/bezier-der.html" rel="nofollow noreferrer">https://pages.mtu.edu/~shene/COURSES/cs3621/NOTES/spline/Bezier/bezier-der.html</a>, but I am unable to figure out how they did it. Please help!</p>

<curve>
How to take the derivative of a Bézier curve?
anuj goyal
# How to take the derivative of a Bézier curve?

(Asked by: username_0 on 2021-01-08)

I want to know how to take the derivative of a Bézier curve. I visited this website [https://pages.mtu.edu/~shene/COURSES/cs3621/NOTES/spline/Bezier/bezier-der.html](https://pages.mtu.edu/%7Eshene/COURSES/cs3621/NOTES/spline/Bezier/bezier-der.html), but I am unable to figure out how they did it. Please help!

**Tags:** curve


---

## 1 answers

### Answer by username_1 on 2021-01-08. Score: 3

A simple example of taking a the derivative of a B'ezier curve can be shown using a cubic curve.

$$C\_3(u) = \sum\_{i=0}^3 B\_{3,i}(u) P\_i,$$ where $u \in [0,1]$ and $B\_{n,i} = {n \choose i} u^i (1-u)^{n-i}$ is the $i$-th Bernstein polynomial of degree $n$. $P\_i$ are the control points.

written out it is:

$$C\_3(u) = (1-u)^3 P\_0 + 3(1-u)^2 u P\_1 + 3 (1-u)u^2 P\_2 + u^3 P\_3$$

we can differentiate this with respect to u

$$\frac{\partial}{\partial u} C\_3(u) = -3(1-u)^2 P\_0 - 6(1-u) u P\_1 + 3(1-u)^2 P\_1 - 3 u^2 P\_2 + 6 (1-u)u P\_2 + 3u^2 P\_3. $$

Now we can rearrange the terms

$$\frac{\partial}{\partial u} C\_3(u) = 3 \left((1-u)^2 (P\_1-P\_0) + 2(1-u) u (P\_2 - P\_1) + u^2 (P\_3 - P\_2) \right), $$ or

$$\frac{\partial}{\partial u} C\_3(u) = 3 (\sum\_{i=0}^2 B\_{2,i}(u) (P\_{i+1} - P\_i))$$

We obtain a quadratic B'ezier curve where the control points are the vectors between the initial control points, scaled by a factor $3$. Therefore the derivative of a Bezier curve of degree $n$ is a B'ezier curve of degree $n-1$, where the control points are difference between initial control points scaled by $n$.

so:

$$\frac{\partial}{\partial u} \sum\_{i=0}^n B\_{n,i}(u) P\_i = n (\sum\_{i=0}^2 B\_{n-1,i}(u) (P\_{i+1} - P\_i))$$

> **Comments:**
> **username_2**: Can you explain what does `B_3` in the formulas mean?  
> **username_1**: They are the cubic Bernstein polynomials. I added their definitions.  
> **username_2**: @username_1 the `wikipedia` page seem to have a wrong image for the formula. Or browser's `javascript` is broken. Anyway, thank you. Please reply with a `@`, so one will get notified about your reply.  

---

