File:Bernstein Polynomials.svg
From testwiki
Jump to navigation
Jump to search
Original file (SVG file, nominally 396 × 390 pixels, file size: 41 KB)
Contents
This file is from Wikimedia Commons and may be used by other projects. The description on its file description page there is shown below.
Summary
| DescriptionBernstein Polynomials.svg |
English: Plot of Bernstein polynomial functions up to degree 4 with summation of all four functions to show characteristic of partition of one. Deutsch: Druck von Funktionen der Bernstein Polynome bis Grad 4 mit Summe über alle vier Funktionen zur Verdeutlichung der Partition der Eins. |
| Date | |
| Source | Own work |
| Author | VisorZ |
Code in https://cloud.sagemath.com/projects (with bug fix):
# adapted from file without sum of Bernstein Polynomials by Kilom691
# http://commons.wikimedia.org/wiki/File:Bernstein_poly_4.svg
N = 4
rnb = rainbow(N + 1)
pt1 = sum(
plot(
binomial(N, i) * x ** i * (1 - x) ** (N - i),
0, 1,
legend_label=r'$B^{}_{}(u)$'.format(N, i),
color=rnb[i],
thickness=3,
aspect_ratio=1
)
for i in range(N + 1)
)
almostOne = 0.99999 # bug in sagemath, put it to 1.0 and BSum plot will vanish
var('i')
BSum = sum( binomial(N, i) * x ** i * (1 - x) ** (N - i), i, 0, 3 ) \
+ binomial(N, 4) * x ** 4 * (1 - x) ** (N - 4) * almostOne
pt2 = plot(
BSum,
0, 1,
legend_label='$\sum_{i=0}^{4} \, B^{4}_{i}(u)$', # code between $ .. $ uses LaTeX math commands to format equation
color='orange',
thickness=3
)
pt2.set_legend_options(loc=(0.37,0.5))
show( pt1 + pt2, figsize=6 )
Licensing
I, the copyright holder of this work, hereby publish it under the following license:
This file is licensed under the Creative Commons Attribution-Share Alike 4.0 International license.
- You are free:
- to share – to copy, distribute and transmit the work
- to remix – to adapt the work
- Under the following conditions:
- attribution – You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.
- share alike – If you remix, transform, or build upon the material, you must distribute your contributions under the same or compatible license as the original.
Captions
Add a one-line explanation of what this file represents
Items portrayed in this file
depicts
some value
11 May 2015
image/svg+xml
05d26e0ea9c03c3bfe1e5213bad8953d6000c663
42,149 byte
390 pixel
396 pixel
File history
Click on a date/time to view the file as it appeared at that time.
| Date/Time | Thumbnail | Dimensions | User | Comment | |
|---|---|---|---|---|---|
| current | 10:51, 11 May 2015 | 396 × 390 (41 KB) | wikimediacommons>VisorZ | Put summation equation to bottom of legend for a better logical order. |
File usage
There are no pages that use this file.