Collection of tools for programmation and modeling X
Project description
PMXUtils
Tools for ProgModX
Note that the package is in development and may undergo frequent updates
Install with python -m pip install pmxutils
for windows and python3 -m pip install pmxutils
for unix/linux
Table of content
Mathtools (pmxutils.mathtools
)
-
construct(expression, var=x)
Returns a function computing the given expression
expression
- The mathematical expression to compute, type = stringvar
- The variable used in the mathematical expression, defaults tp 'x', type = string
-
computeLists(function,low, high, step=1)
Returns a touple of two lists containing x values inbetween low and high, and the computed results for y. In the format of (x_list, y_list)
low
- The lower end of the function limit, type = numberhigh
- The upper end of the function limit, type = numberfunction
- The mathematical expression to use for y value computation, type = string or function from constructstep
- The step size in the x value list, defaults to '1', type = number
-
newton(function, derivative, limOne, limTwo, tolerance=1e-8, rounding = 3, iterations = 1000)
Uses Newtons way of finding the root of a function, using the function and its derivative, within the given limits.Returns None if it can't find a solution that satisfies the tolerance after the defined number of terations
function
- The target mathematical expression, type = string or function from constructderivative
- The derivative of the target mathematical expression, type = string or function from constructlimOne
- The lower end of the are which should be checked for roots, type = numberlimTwo
- The upper end of the are which should be checked for roots, type = numbertolerance
- The tolerance for error to speed up computation, defaults to '1e-8', type = numberrounding
- Rounds the x value for the root to the specified amount of decimals, defaults to '3', type = numberiterations
- The number of tries, after which the function will end early
-
isInbetween(number, limOne, limTwo)
Returns True if number is inbetween limOne and limTwo, returns False otherwise
number
- The number to be checked, type = numberlimOne
- The lower limit for which the number is checked, type = numberlimTwo
- The upper limit for which the number is checked, tyoe = number
Other (pmxutils.other
)
loading()
Loading class
-
start(flavor="loading")
Starts a loading sequence
flavor
- The message to be displayed during loading, defaults to 'loading', type = string
-
stop()
Stops the loading sequence
-
animate()
DO NOT USE, internal function
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
Hashes for pmxutils-0.0.3.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 06cda85774160d9d35f24aa97109be3ac96ab7f686d5b5780cf081747504d4c5 |
|
MD5 | c64ed8c4a0cd56f1f0753568bfe7f226 |
|
BLAKE2b-256 | d296d288274578078c9de9bff4bd108044643225844cefa4908bba68a7666810 |