File:Cubic graph special points repeated.svg
From Wikimedia Commons, the free media repository
Jump to navigation
Jump to search
Size of this PNG preview of this SVG file: 512 × 512 pixels. Other resolutions: 240 × 240 pixels | 480 × 480 pixels | 768 × 768 pixels | 1,024 × 1,024 pixels | 2,048 × 2,048 pixels.
Original file (SVG file, nominally 512 × 512 pixels, file size: 7 KB)
File information
Structured data
Captions
Summary
[edit]DescriptionCubic graph special points repeated.svg | Graphs showing the relationship between the roots, and turning, stationary and inflection points of a cubic polynomial, and its first and second derivatives by CMG Lee. Thanks to en:user:GalacticShoe for an algorithm to exactly draw a cubic polynomial segment with a cubic Bezier. | |
Source | Own work | |
Author | Cmglee | |
Other versions |
|
Python script to find distinct non-zero integer values
[edit]#!/usr/bin/env python
import re
def eval_at(x): return a * x ** 3 + b * x ** 2 + c * x + d
def is_integer(x): return abs(x - int(x)) < 1e-5
def print_keyval(dic, re_key):
print('\t'.join(sorted(['%s=%s' % (key, dic[key])
for key in dic if re.search(re_key, key)])))
## http://wolframalpha.com/input?i=expand+%28x-r1%29%28x-r2%29%5E2
## http://wolframalpha.com/input?i=differentiate+(x-r1)(x-r2)(x-r2)
## http://wolframalpha.com/input?i=solve+2r1*r2-2r1*x%2Br2^2-4r2*x%2B3x^2%3D0+for+x
## http://wolframalpha.com/input?i=differentiate+(x-r2)(x-(2r1%2Br2)%2F3)
## http://wolframalpha.com/input?i=solve+2x-2r1%2F3-4r2%2F3%3D0+for+x
## http://wolframalpha.com/input?i=y%3D(x-4)(x-1)^2
## http://www.wolframalpha.com/input?i=factorise+3x^2-12x%2B9
## Cubic bezier control points from left to right, to be populated
pts = [[-1,None], [None,None], [None,None], [5,None]]
n = 4 ## search range = [-n, n]
for r2 in range(n, -1 - n, -1):
for r1 in range(n, r2 , -1):
if r1 * r2 == 0: continue
r_1 = (2 * r1 + r2) / 3.0
r_2 = r2
if is_integer(r_1) and r_1 != 0: r_1 = int(r_1)
else: continue
r__ = (r1 + 2 * r2) / 3.0
if is_integer(r__) and r__ != 0: r__ = int(r__)
else: continue
if len(set([r1, r_1, r__])) < 3: continue
a = 1
b = -2 * r2 - r1
c = r2 * (2 * r1 + r2)
d = -r1 * r2 * r2
p = pts[0][0]
q = pts[3][0]
pts[0][1] = eval_at(p)
pts[3][1] = eval_at(q)
pts[1][0] = (2 * p + q) / 3.0
pts[1][1] = a * p * p * q + b * (p * p + 2 * p * q) / 3.0 + c * (2 * p + q) / 3.0 + d
pts[2][0] = (p + 2 * q) / 3.0
pts[2][1] = a * p * q * q + b * (q * q + 2 * p * q) / 3.0 + c * (p + 2 * q) / 3.0 + d
print_keyval(locals(), r'^(r_*\d?|[abcd]|pts)$')
Licensing
[edit]I, the copyright holder of this work, hereby publish it under the following licenses:
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.
Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is included in the section entitled GNU Free Documentation License.http://www.gnu.org/copyleft/fdl.htmlGFDLGNU Free Documentation Licensetruetrue |
You may select the license of your choice.
File history
Click on a date/time to view the file as it appeared at that time.
Date/Time | Thumbnail | Dimensions | User | Comment | |
---|---|---|---|---|---|
current | 04:21, 4 February 2024 | 512 × 512 (7 KB) | Cmglee (talk | contribs) | Shrink font and simplify labels // Editing SVG source code using c:User:Rillke/SVGedit.js | |
04:00, 4 February 2024 | 512 × 512 (7 KB) | Cmglee (talk | contribs) | Align text // Editing SVG source code using c:User:Rillke/SVGedit.js | ||
01:43, 4 February 2024 | 512 × 512 (6 KB) | Cmglee (talk | contribs) | Assorted improvements | ||
15:47, 3 February 2024 | 512 × 512 (6 KB) | Cmglee (talk | contribs) | Fix missing dots // Editing SVG source code using c:User:Rillke/SVGedit.js | ||
15:19, 3 February 2024 | 512 × 512 (6 KB) | Cmglee (talk | contribs) | {{Information |Description=Graphs showing the relationship between the roots, and turning, stationary and inflection points of a cubic polynomial, and its first and second derivatives by CMG Lee. |Source={{own}} |Date= |Author= Cmglee |Permission= |other_versions={{source thumb|cubic_graph_special_points.svg}} }} Category:Cubic functions Category:Differential calculus |
You cannot overwrite this file.
File usage on Commons
The following 2 pages use this file:
File usage on other wikis
The following other wikis use this file:
Metadata
This file contains additional information such as Exif metadata which may have been added by the digital camera, scanner, or software program used to create or digitize it. If the file has been modified from its original state, some details such as the timestamp may not fully reflect those of the original file. The timestamp is only as accurate as the clock in the camera, and it may be completely wrong.
Short title | cubic graph special points repeated |
---|---|
Image title | Graphs showing the relationship between the roots, and turning, stationary and inflection points of a cubic polynomial, and its first and second derivatives by CMG Lee. |
Width | 100% |
Height | 100% |