unknown-numbers
What does this repo do ?
This repo allows you to create exponential terms using unknown numbers comfortably. You can do various math applications using this repository. Like binomial expansion, derivative, integral...
How do you install this package ?
pip install unknown-terms
How do you use ?
from unknown_terms.alpha_term import *
# In this way, you can use every class on the package.
Quick Note: If you don't want this project as a package you had to change this lines in alpha_term.py
from .multiple_alpha_term import MultipleAlphaTerm
from .printer import TermPrinter
to
from multiple_alpha_term import MultipleAlphaTerm
from printer import TermPrinter
AlphaTerm class
You can create a term with a single unknown.
term1 = AlphaTerm(2, "x", 3) # Created AlphaTerm object
term2 = AlphaTerm(3, "y", 2)
term3 = AlphaTerm(0, "z", 2)
term4 = AlphaTerm(3, "t", 0)
term5 = AlphaTerm(0, "a", 0)
term6 = AlphaTerm() # AlphaTerm(1, "x", 1)
# METHODS
print(term1, term5, term4, sep=" , ")
# prints irregular term -> 2.0x³ , 0.0a⁰ , 3.0t⁰
# TermPrinter.print method returns regular term
print(TermPrinter.print(term1)) # 2x³
print(TermPrinter.print(term5)) # (nothing)
print(TermPrinter.print(term4)) # 3t
# Multiplication
mterm = term1 * term2
print(mterm) # 6.0x³y² -> This is a MultipleAlphaTerm object
print(TermPrinter.print(mterm)) # 6x³y²
# Division
mterm = term2 / term4
print(mterm) # 1.0y²t⁰
print(TermPrinter.print(mterm)) # y²
# Exponentiation
new_term = term2 ** 2
print(new_term) # prints 9y⁴
# Turn to known
number = term1.turn_to_known(value=5)
print(number) #prints 250
- NOT: Operations such as exponentiation, division, multiplication can also be applied to objects in the MultipleAlpaTerm class.
Metadata
Release files for unknown-terms 1.0.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| unknown-terms-1.0.2.tar.gz | 7.6 kB | Without provenance | Details for unknown-terms-1.0.2.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| unknown_terms-1.0.2-py3-none-any.whl | Python 3 | none | any | Details for unknown_terms-1.0.2-py3-none-any.whl |
Total release size: 15.0 kB
Release files / unknown-terms-1.0.2.tar.gz
| Download URL | unknown-terms-1.0.2.tar.gz |
|---|---|
| Size | 7.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
6b67756ee3a9f8dcb0cd3a293d8b523844982cab58bf1f2d8771d91912b9ec98
|
|
BLAKE2b-256 checksum How to use checksums |
fda6a087bdca931950b9ac144dc6a1fae27e847b8f6c29fb419646ea3aa7e0a0
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.8.3
|
Release files / unknown_terms-1.0.2-py3-none-any.whl
| Download URL | unknown_terms-1.0.2-py3-none-any.whl |
|---|---|
| Size | 7.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
efcab25a7cf4135a001496de1d304b48b19ba794d10956438c02e101a3ea3e19
|
|
BLAKE2b-256 checksum How to use checksums |
3b3414edfa21dee849122acf86464e3d747269c3e271ff1fee7fafb35abda6d6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.8.3
|
Security for unknown-terms 1.0.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.