Automatically generates sign charts for polynomial functions.
Project description
signchart
signchart is a Python package for plotting sign charts for polynomial functions. It is designed to be simple to use to generate beautiful sign charts for polynomial functions.
Basic examples
Example 1
import signchart
f = "(x**2 + 1)**2 * (x - 1)**2 * (x + 1)"
signchart.plot(f=f, include_factors=True)
signchart.savefig(
dirname="dirname",
fname="fname",
)
signchart.show()
This will generate the following sign chart:
Example 2
import signchart
f = "x**2 - x - 6"
signchart.plot(
f=f,
include_factors=True,
color=True, # Includes colored lines.
fn_name="g(x)", # Names the function g(x)
)
signchart.savefig(
dirname="figures",
fname="example_2.svg",
)
signchart.show()
This will generate the following sign chart:
Example 3
import signchart
f = "-2 * x**2 + 2 * x + 12"
signchart.plot(
f=f,
include_factors=True,
color=True, # Includes colored lines.
fn_name="h(x)", # Names the function h(x)
)
signchart.savefig(
dirname="figures",
fname="example_3.svg",
)
signchart.show()
This will generate the following sign chart:
Example 4
import signchart
f = "-3 * (t - 1) * (t + 3)" # Uses 't' as variable in place of 'x'
signchart.plot(
f=f,
include_factors=False, # excludes linear factors in the polynomial
color=False, # sign lines are black (uncolored)
fn_name="x(t)", # Names the function x(t)
)
signchart.savefig(
dirname="figures",
fname="example_4.svg",
)
signchart.show()
This will generate the following sign chart:
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file signchart-0.1.13.tar.gz.
File metadata
- Download URL: signchart-0.1.13.tar.gz
- Upload date:
- Size: 6.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
80a98e431c50ba173dcdbb448a5e09089e847f3bfcb47c8eb5353ee350979d94
|
|
| MD5 |
c365364e7e2dfa7c6317c9a3847a70f1
|
|
| BLAKE2b-256 |
12b2c2d13f04835adb444f25ce1848afe99feb013591c6860898f0ca872c5d08
|
File details
Details for the file signchart-0.1.13-py3-none-any.whl.
File metadata
- Download URL: signchart-0.1.13-py3-none-any.whl
- Upload date:
- Size: 6.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1ff803025457e449b814a3f62cf915deaf3c0b49c40b2873f4e448f2643320ed
|
|
| MD5 |
5c1e27ee4978c7c7e927670e6ef58402
|
|
| BLAKE2b-256 |
f7b0c515089366c190e49102b25b7dd1a05f317290e60f2dbcf639852a10f700
|