PyPyNum 1.16.0__tar.gz → 1.16.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (53) hide show
  1. {pypynum-1.16.0 → pypynum-1.16.2}/PKG-INFO +93 -80
  2. {pypynum-1.16.0 → pypynum-1.16.2}/PyPyNum.egg-info/PKG-INFO +93 -80
  3. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/README.md +92 -79
  4. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/__init__.py +1 -1
  5. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/arrays.py +92 -34
  6. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/chars.py +10 -1
  7. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/dists.py +2 -2
  8. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/maths.py +11 -11
  9. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/multiprec.py +2 -2
  10. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/seqs.py +2 -1
  11. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/special.py +277 -3
  12. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/tensors.py +3 -15
  13. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/tools.py +182 -1
  14. pypynum-1.16.2/pypynum/vectors.py +102 -0
  15. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/zh_cn.py +6 -6
  16. {pypynum-1.16.0 → pypynum-1.16.2}/setup.py +1 -1
  17. pypynum-1.16.0/pypynum/vectors.py +0 -93
  18. {pypynum-1.16.0 → pypynum-1.16.2}/PyPyNum.egg-info/SOURCES.txt +0 -0
  19. {pypynum-1.16.0 → pypynum-1.16.2}/PyPyNum.egg-info/dependency_links.txt +0 -0
  20. {pypynum-1.16.0 → pypynum-1.16.2}/PyPyNum.egg-info/top_level.txt +0 -0
  21. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/PyPyNum.png +0 -0
  22. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/ciphers.py +0 -0
  23. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/consts.py +0 -0
  24. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/crandom.py +0 -0
  25. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/dataproc.py +0 -0
  26. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/equations.py +0 -0
  27. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/fft.py +0 -0
  28. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/files.py +0 -0
  29. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/geoms.py +0 -0
  30. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/graphs.py +0 -0
  31. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/groups.py +0 -0
  32. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/images.py +0 -0
  33. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/interp.py +0 -0
  34. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/kernels.py +0 -0
  35. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/logics.py +0 -0
  36. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/matrices.py +0 -0
  37. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/networks.py +0 -0
  38. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/numbers.py +0 -0
  39. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/plotting.py +0 -0
  40. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/polys.py +0 -0
  41. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/pprinters.py +0 -0
  42. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/quats.py +0 -0
  43. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/random.py +0 -0
  44. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/regs.py +0 -0
  45. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/stattest.py +0 -0
  46. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/symbols.py +0 -0
  47. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/test.py +0 -0
  48. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/this.py +0 -0
  49. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/trees.py +0 -0
  50. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/types.py +0 -0
  51. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/ufuncs.py +0 -0
  52. {pypynum-1.16.0 → pypynum-1.16.2}/pypynum/utils.py +0 -0
  53. {pypynum-1.16.0 → pypynum-1.16.2}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: PyPyNum
3
- Version: 1.16.0
3
+ Version: 1.16.2
4
4
  Summary: PyPyNum is a Python library for math & science computations, covering algebra, calculus, stats, with data structures like matrices, vectors, tensors. It offers numerical tools, programs, and supports computational ops, functions, processing, simulation, & visualization in data science & ML, crucial for research, engineering, & data processing.
5
5
  Home-page: https://github.com/PythonSJL/PyPyNum
6
6
  Author: Shen Jiayi
@@ -234,7 +234,7 @@ processing.</font><font color = red>[Python>=3.4]</font>
234
234
  [![Downloads](https://static.pepy.tech/badge/pypynum/month)](https://pepy.tech/project/pypynum)
235
235
  [![Downloads](https://static.pepy.tech/badge/pypynum/week)](https://pepy.tech/project/pypynum)
236
236
 
237
- ## Version -> 1.16.0 | PyPI -> https://pypi.org/project/PyPyNum/ | Gitee -> https://www.gitee.com/PythonSJL/PyPyNum | GitHub -> https://github.com/PythonSJL/PyPyNum
237
+ ## Version -> 1.16.2 | PyPI -> https://pypi.org/project/PyPyNum/ | Gitee -> https://www.gitee.com/PythonSJL/PyPyNum | GitHub -> https://github.com/PythonSJL/PyPyNum
238
238
 
239
239
  ![LOGO](PyPyNum.png)
240
240
 
@@ -247,6 +247,15 @@ The logo cannot be displayed on PyPI, it can be viewed in Gitee or GitHub.
247
247
  + Update versions periodically to add more practical features
248
248
  + If you need to contact, please add QQ number 2261748025 (Py𝙿𝚢𝚝𝚑𝚘𝚗-水晶兰), or through my email 2261748025@qq.com
249
249
 
250
+ ```
251
+ +++++++++++++++++++++++++++++++++++++++++
252
+ + Tip: +
253
+ + Have suggestions or feature requests? +
254
+ + Feel free to share them with us. +
255
+ + Your feedback is highly appreciated! +
256
+ +++++++++++++++++++++++++++++++++++++++++
257
+ ```
258
+
250
259
  ### Name and Function Introduction of Submodules
251
260
 
252
261
  | Submodule Name | Function Introduction |
@@ -327,81 +336,69 @@ Python interpreter and run it!
327
336
  ```
328
337
  !=!=!=!=!=!=!=!=!=!=!=!=!=!=!=!=
329
338
 
330
- The submodule 'consts' has added
331
- a large number of mathematical
332
- and scientific constants,
333
- currently totaling 128.
339
+ <<< Here are the newly added functions >>>
334
340
 
335
- This module defines a collection
336
- of constants representing
337
- various physical, mathematical,
338
- and unit conversion factors.
339
341
 
340
- These constants are commonly
341
- used in scientific and
342
- engineering calculations.
342
+ kmp_table(pattern: Union[list, tuple, str]) -> list
343
+ Introduction
344
+ ==========
345
+ Generate the KMP (Knuth-Morris-Pratt) table for a given pattern.
343
346
 
344
- If you want to know information
345
- about each constant, you can
346
- execute 'help(consts)' to
347
- obtain it.
347
+ The KMP table is used to efficiently find occurrences of a pattern within a sequence by avoiding unnecessary
348
+ comparisons after a mismatch. This table determines how many characters can be skipped after a mismatch.
348
349
 
349
- !=!=!=!=!=!=!=!=!=!=!=!=!=!=!=!=
350
+ Example
351
+ ========
352
+ >>> kmp_table("AGCTGATCGTACGTAAGCTAGCTA")
353
+ [0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 1, 1, 2, 3, 4, 1, 2, 3, 4, 1]
354
+ >>>
355
+ :param pattern: The pattern for which to generate the KMP table.
356
+ :return: A list representing the KMP table for the given pattern.
350
357
 
351
358
 
352
- <<< Here are the newly added functions >>>
359
+ findall(seq: Union[list, tuple, str], pat: Union[list, tuple, str]) -> list
360
+ Introduction
361
+ ==========
362
+ Find all indices of the subsequence 'pat' in 'seq'.
353
363
 
364
+ This function is designed to handle sequences such as lists, tuples, or strings and find all indices
365
+ of specified subsequences. It allows overlapping matches.
354
366
 
355
- PyPyNum
356
- ├── special
357
- │ └── FUNCTION
358
- │ ├── qbinomial(n: typing.Union[int, float, complex], m: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
359
- │ │ # Calculate the q-binomial coefficient of n and m with parameter q.
360
- │ ├── qfactorial(n: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
361
- │ │ # Compute the q-factorial of n with parameter q.
362
- │ ├── qgamma(n: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
363
- │ │ # Calculate the q-gamma function of n with parameter q.
364
- │ └── qpochhammer(a: typing.Union[int, float, complex], q: typing.Union[int, float, complex], n: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
365
- │ # Compute the q-Pochhammer symbol for given a, q, and n.
366
- ├── multiprec
367
- │ └── FUNCTION
368
- │ ├── mp_catalan(sigfigs: int) -> decimal.Decimal
369
- │ # Calculate the Catalan's constant with a specified number of significant figures using multiprecision arithmetic.
370
- ├── seqs
371
- │ └── FUNCTION
372
- │ ├── padovan(n: int, single: bool) -> typing.Union[int, list]
373
- │ │ # Generate the Padovan sequence up to the nth term.
374
- │ ├── pelllucas(n: int, single: bool) -> typing.Union[int, list]
375
- │ │ # Generate the Pell-Lucas sequence up to the nth term.
376
- │ ├── perrin(n: int, single: bool) -> typing.Union[int, list]
377
- │ │ # Generate the Perrin sequence up to the nth term.
378
- │ └── sylvester(n: int, single: bool) -> typing.Union[int, list]
379
- │ # Generate the Sylvester sequence up to the nth term.
380
- ├── tools
381
- │ └── FUNCTION
382
- │ ├── lcsubseq(x: typing.Union[list, tuple, str], y: typing.Union[list, tuple, str]) -> list
383
- │ │ # Find the longest common subsequence between two sequences x and y.
384
- │ └── lcsubstr(x: typing.Union[list, tuple, str], y: typing.Union[list, tuple, str]) -> list
385
- │ # Find the longest common substring between two sequences x and y.
386
- ├── matrices
387
- │ ├── CLASS
388
- │ │ └── Matrix(pypynum.arrays.Array)/__init__(self: Any, data: Any, check: Any) -> Any
389
- │ │ # Initialize a Matrix object from a given data array.
390
- │ └── FUNCTION
391
- │ ├── perm_mat(num_rows: int, num_cols: int, row_swaps: typing.Union[list, tuple], col_swaps: typing.Union[list, tuple], rtype: typing.Callable) -> typing.Any
392
- │ │ # Create a permutation matrix based on specified row and column swaps.
393
- │ └── perm_mat_indices(num_rows: int, num_cols: int, row_swaps: typing.Union[list, tuple], col_swaps: typing.Union[list, tuple]) -> tuple
394
- │ # Compute the indices for a permutation matrix based on specified row and column swaps.
367
+ Example
368
+ ========
369
+ >>> findall([2, 1, 2, 1, 2, 1, 2, 1], [1, 2, 1, 2])
370
+ [1, 3]
371
+ >>>
372
+ :param seq: The sequence in which to find the subsequence.
373
+ :param pat: The subsequence to be found.
374
+ :return: A list of starting indices where the subsequence is found.
395
375
 
396
376
 
397
- !=!=!=!=!=!=!=!=!=!=!=!=!=!=!=!=
377
+ ---------------------------------------------------------------------------------------
378
+ | q-functions generalize classical math functions by introducing parameter q. |
379
+ | They are key in combinatorics and special functions, widely applied. |
380
+ | As q approaches 1, they revert to classical forms. |
381
+ | Examples include q-factorials, q-binomial coefficients, Jackson q-Bessel functions. |
382
+ | These functions are crucial in fractals, chaotic systems, quantum groups. |
383
+ | They provide tools for solving complex mathematical challenges effectively. |
384
+ ---------------------------------------------------------------------------------------
385
+
386
+
387
+ Here are the 12 new q-functions added in the current version (adding the previous 4 makes a total of 16):
388
+
398
389
 
399
- Other functions and classes have
400
- also undergone certain
401
- modifications, such as adding a
402
- "reduce" parameter to the "qr"
403
- function to determine whether to
404
- crop the matrix.
390
+ qbeta(a: Union[int, float, complex], b: Union[int, float, complex], q: Union[int, float, complex]) -> Union[int, float, complex]
391
+ qcos_large(x: Union[int, float, complex], q: Union[int, float, complex]) -> Union[int, float, complex]
392
+ qcos_small(x: Union[int, float, complex], q: Union[int, float, complex]) -> Union[int, float, complex]
393
+ qcosh_large(x: Union[int, float, complex], q: Union[int, float, complex]) -> Union[int, float, complex]
394
+ qcosh_small(x: Union[int, float, complex], q: Union[int, float, complex]) -> Union[int, float, complex]
395
+ qexp_large(z: Union[int, float, complex], q: Union[int, float, complex]) -> Union[int, float, complex]
396
+ qexp_small(z: Union[int, float, complex], q: Union[int, float, complex]) -> Union[int, float, complex]
397
+ qpi(q: Union[int, float, complex]) -> Union[int, float, complex]
398
+ qsin_large(x: Union[int, float, complex], q: Union[int, float, complex]) -> Union[int, float, complex]
399
+ qsin_small(x: Union[int, float, complex], q: Union[int, float, complex]) -> Union[int, float, complex]
400
+ qsinh_large(x: Union[int, float, complex], q: Union[int, float, complex]) -> Union[int, float, complex]
401
+ qsinh_small(x: Union[int, float, complex], q: Union[int, float, complex]) -> Union[int, float, complex]
405
402
 
406
403
  !=!=!=!=!=!=!=!=!=!=!=!=!=!=!=!=
407
404
  ```
@@ -439,15 +436,16 @@ PyPyNum
439
436
  │ ├── asarray(data: Any) -> Any
440
437
  │ ├── aslist(data: Any) -> Any
441
438
  │ ├── boolarray(data: Any) -> Any
442
- │ ├── fill(shape: Any, sequence: Any, repeat: Any, pad: Any, rtype: Any) -> Any
443
- │ ├── full(shape: Any, fill_value: Any, rtype: Any) -> Any
444
- │ ├── full_like(a: Any, fill_value: Any, rtype: Any) -> Any
439
+ │ ├── fill(shape: typing.Union[list, tuple], sequence: typing.Union[list, tuple], repeat: bool, pad: typing.Any, rtype: typing.Callable) -> typing.Any
440
+ │ ├── full(shape: typing.Union[list, tuple], fill_value: typing.Any, rtype: typing.Callable) -> typing.Any
441
+ │ ├── full_like(a: typing.Any, fill_value: typing.Any, rtype: typing.Callable) -> typing.Any
445
442
  │ ├── get_shape(data: Any) -> Any
446
443
  │ ├── is_valid_array(_array: Any, _shape: Any) -> Any
447
- │ ├── ones(shape: Any, rtype: Any) -> Any
448
- │ ├── ones_like(a: Any, rtype: Any) -> Any
449
- │ ├── zeros(shape: Any, rtype: Any) -> Any
450
- └── zeros_like(a: Any, rtype: Any) -> Any
444
+ │ ├── ones(shape: typing.Union[list, tuple], rtype: typing.Callable) -> typing.Any
445
+ │ ├── ones_like(a: typing.Any, rtype: typing.Callable) -> typing.Any
446
+ │ ├── tensorproduct(tensors: pypynum.arrays.Array) -> pypynum.arrays.Array
447
+ ├── zeros(shape: typing.Union[list, tuple], rtype: typing.Callable) -> typing.Any
448
+ │ └── zeros_like(a: typing.Any, rtype: typing.Callable) -> typing.Any
451
449
  ├── chars
452
450
  │ ├── CLASS
453
451
  │ └── FUNCTION
@@ -501,7 +499,7 @@ PyPyNum
501
499
  │ ├── gamma_pdf(x: Any, shape: Any, scale: Any) -> Any
502
500
  │ ├── geometric_pmf(k: Any, p: Any) -> Any
503
501
  │ ├── hypergeom_pmf(k: Any, mg: Any, n: Any, nt: Any) -> Any
504
- │ ├── inv_gauss_pdf(x: Any, mu: Any, lambda_: Any, alpha: Any) -> Any
502
+ │ ├── invgauss_pdf(x: Any, mu: Any, lambda_: Any, alpha: Any) -> Any
505
503
  │ ├── levy_pdf(x: Any, c: Any) -> Any
506
504
  │ ├── log_logistic_cdf(x: Any, alpha: Any, beta: Any) -> Any
507
505
  │ ├── log_logistic_pdf(x: Any, alpha: Any, beta: Any) -> Any
@@ -647,7 +645,7 @@ PyPyNum
647
645
  │ ├── cosh(x: typing.Union[int, float]) -> typing.Union[int, float]
648
646
  │ ├── cot(x: typing.Union[int, float]) -> typing.Union[int, float]
649
647
  │ ├── coth(x: typing.Union[int, float]) -> typing.Union[int, float]
650
- │ ├── cov(x: typing.Union[list, tuple], y: typing.Union[list, tuple], dof: int) -> typing.Union[int, float, complex]
648
+ │ ├── cov(x: typing.Union[list, tuple], y: typing.Union[list, tuple], ddof: int) -> typing.Union[int, float, complex]
651
649
  │ ├── crt(n: typing.Union[list, tuple], a: typing.Union[list, tuple]) -> int
652
650
  │ ├── csc(x: typing.Union[int, float]) -> typing.Union[int, float]
653
651
  │ ├── csch(x: typing.Union[int, float]) -> typing.Union[int, float]
@@ -695,13 +693,13 @@ PyPyNum
695
693
  │ ├── sinh(x: typing.Union[int, float]) -> typing.Union[int, float]
696
694
  │ ├── skew(data: typing.Union[list, tuple]) -> float
697
695
  │ ├── square_mean(numbers: typing.Union[list, tuple]) -> typing.Union[int, float, complex]
698
- │ ├── std(numbers: typing.Union[list, tuple], dof: int) -> typing.Union[int, float, complex]
696
+ │ ├── std(numbers: typing.Union[list, tuple], ddof: int) -> typing.Union[int, float, complex]
699
697
  │ ├── sumprod(arrays: typing.Union[list, tuple]) -> typing.Union[int, float, complex]
700
698
  │ ├── tan(x: typing.Union[int, float]) -> typing.Union[int, float]
701
699
  │ ├── tanh(x: typing.Union[int, float]) -> typing.Union[int, float]
702
700
  │ ├── totient(n: int) -> int
703
701
  │ ├── upper_gamma(s: typing.Union[int, float, complex], x: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
704
- │ ├── var(numbers: typing.Union[list, tuple], dof: int) -> typing.Union[int, float, complex]
702
+ │ ├── var(numbers: typing.Union[list, tuple], ddof: int) -> typing.Union[int, float, complex]
705
703
  │ ├── xlogy(x: typing.Union[int, float, complex], y: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
706
704
  │ └── zeta(alpha: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
707
705
  ├── matrices
@@ -848,10 +846,22 @@ PyPyNum
848
846
  │ ├── hyp1f1(a0: typing.Union[int, float, complex], b0: typing.Union[int, float, complex], z: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
849
847
  │ ├── hyp2f1(a0: typing.Union[int, float, complex], a1: typing.Union[int, float, complex], b0: typing.Union[int, float, complex], z: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
850
848
  │ ├── hyppfq(a: typing.Union[list, tuple], b: typing.Union[list, tuple], z: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
849
+ │ ├── qbeta(a: typing.Union[int, float, complex], b: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
851
850
  │ ├── qbinomial(n: typing.Union[int, float, complex], m: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
851
+ │ ├── qcos_large(x: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
852
+ │ ├── qcos_small(x: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
853
+ │ ├── qcosh_large(x: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
854
+ │ ├── qcosh_small(x: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
855
+ │ ├── qexp_large(z: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
856
+ │ ├── qexp_small(z: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
852
857
  │ ├── qfactorial(n: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
853
858
  │ ├── qgamma(n: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
854
- └── qpochhammer(a: typing.Union[int, float, complex], q: typing.Union[int, float, complex], n: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
859
+ ├── qpi(q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
860
+ │ ├── qpochhammer(a: typing.Union[int, float, complex], q: typing.Union[int, float, complex], n: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
861
+ │ ├── qsin_large(x: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
862
+ │ ├── qsin_small(x: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
863
+ │ ├── qsinh_large(x: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
864
+ │ └── qsinh_small(x: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
855
865
  ├── stattest
856
866
  │ ├── CLASS
857
867
  │ └── FUNCTION
@@ -870,8 +880,7 @@ PyPyNum
870
880
  │ │ └── Tensor(pypynum.arrays.Array)/__init__(self: Any, data: Any, check: Any) -> Any
871
881
  │ └── FUNCTION
872
882
  │ ├── ten(data: list) -> pypynum.tensors.Tensor
873
- ├── tensor_and_number(tensor: Any, operator: Any, number: Any) -> Any
874
- │ └── tensorproduct(tensors: pypynum.tensors.Tensor) -> pypynum.tensors.Tensor
883
+ └── tensor_and_number(tensor: Any, operator: Any, number: Any) -> Any
875
884
  ├── test
876
885
  │ ├── CLASS
877
886
  │ └── FUNCTION
@@ -882,10 +891,13 @@ PyPyNum
882
891
  │ ├── CLASS
883
892
  │ └── FUNCTION
884
893
  │ ├── classify(array: typing.Union[list, tuple]) -> dict
894
+ │ ├── cos_sim(seq1: typing.Union[list, tuple, str], seq2: typing.Union[list, tuple, str], is_vector: bool) -> float
885
895
  │ ├── dedup(iterable: typing.Union[list, tuple, str]) -> typing.Union[list, tuple, str]
886
896
  │ ├── fast_pow(a: typing.Any, n: int, init: typing.Any, mul: typing.Callable) -> typing.Any
897
+ │ ├── findall(seq: typing.Union[list, tuple, str], pat: typing.Union[list, tuple, str]) -> list
887
898
  │ ├── frange(start: typing.Union[int, float], stop: typing.Union[int, float], step: float) -> list
888
899
  │ ├── geomspace(start: typing.Union[int, float], stop: typing.Union[int, float], number: int) -> list
900
+ │ ├── kmp_table(pattern: typing.Union[list, tuple, str]) -> list
889
901
  │ ├── lcsubseq(x: typing.Union[list, tuple, str], y: typing.Union[list, tuple, str]) -> list
890
902
  │ ├── lcsubstr(x: typing.Union[list, tuple, str], y: typing.Union[list, tuple, str]) -> list
891
903
  │ ├── levenshtein(x: typing.Union[list, tuple, str], y: typing.Union[list, tuple, str]) -> int
@@ -894,6 +906,7 @@ PyPyNum
894
906
  │ ├── primality(n: int, iter_num: int) -> bool
895
907
  │ ├── prime_factors(integer: int, dictionary: bool, pollard_rho: bool) -> typing.Union[list, dict]
896
908
  │ ├── primes(limit: int) -> list
909
+ │ ├── replace(seq: typing.Union[list, tuple], old: typing.Union[list, tuple], new: typing.Union[list, tuple], count: int) -> typing.Union[list, tuple]
897
910
  │ ├── semiprimes(limit: int) -> list
898
911
  │ ├── split(iterable: typing.Union[list, tuple, str], key: typing.Union[list, tuple], retain: bool) -> list
899
912
  │ └── twinprimes(limit: int) -> list
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: PyPyNum
3
- Version: 1.16.0
3
+ Version: 1.16.2
4
4
  Summary: PyPyNum is a Python library for math & science computations, covering algebra, calculus, stats, with data structures like matrices, vectors, tensors. It offers numerical tools, programs, and supports computational ops, functions, processing, simulation, & visualization in data science & ML, crucial for research, engineering, & data processing.
5
5
  Home-page: https://github.com/PythonSJL/PyPyNum
6
6
  Author: Shen Jiayi
@@ -234,7 +234,7 @@ processing.</font><font color = red>[Python>=3.4]</font>
234
234
  [![Downloads](https://static.pepy.tech/badge/pypynum/month)](https://pepy.tech/project/pypynum)
235
235
  [![Downloads](https://static.pepy.tech/badge/pypynum/week)](https://pepy.tech/project/pypynum)
236
236
 
237
- ## Version -> 1.16.0 | PyPI -> https://pypi.org/project/PyPyNum/ | Gitee -> https://www.gitee.com/PythonSJL/PyPyNum | GitHub -> https://github.com/PythonSJL/PyPyNum
237
+ ## Version -> 1.16.2 | PyPI -> https://pypi.org/project/PyPyNum/ | Gitee -> https://www.gitee.com/PythonSJL/PyPyNum | GitHub -> https://github.com/PythonSJL/PyPyNum
238
238
 
239
239
  ![LOGO](PyPyNum.png)
240
240
 
@@ -247,6 +247,15 @@ The logo cannot be displayed on PyPI, it can be viewed in Gitee or GitHub.
247
247
  + Update versions periodically to add more practical features
248
248
  + If you need to contact, please add QQ number 2261748025 (Py𝙿𝚢𝚝𝚑𝚘𝚗-水晶兰), or through my email 2261748025@qq.com
249
249
 
250
+ ```
251
+ +++++++++++++++++++++++++++++++++++++++++
252
+ + Tip: +
253
+ + Have suggestions or feature requests? +
254
+ + Feel free to share them with us. +
255
+ + Your feedback is highly appreciated! +
256
+ +++++++++++++++++++++++++++++++++++++++++
257
+ ```
258
+
250
259
  ### Name and Function Introduction of Submodules
251
260
 
252
261
  | Submodule Name | Function Introduction |
@@ -327,81 +336,69 @@ Python interpreter and run it!
327
336
  ```
328
337
  !=!=!=!=!=!=!=!=!=!=!=!=!=!=!=!=
329
338
 
330
- The submodule 'consts' has added
331
- a large number of mathematical
332
- and scientific constants,
333
- currently totaling 128.
339
+ <<< Here are the newly added functions >>>
334
340
 
335
- This module defines a collection
336
- of constants representing
337
- various physical, mathematical,
338
- and unit conversion factors.
339
341
 
340
- These constants are commonly
341
- used in scientific and
342
- engineering calculations.
342
+ kmp_table(pattern: Union[list, tuple, str]) -> list
343
+ Introduction
344
+ ==========
345
+ Generate the KMP (Knuth-Morris-Pratt) table for a given pattern.
343
346
 
344
- If you want to know information
345
- about each constant, you can
346
- execute 'help(consts)' to
347
- obtain it.
347
+ The KMP table is used to efficiently find occurrences of a pattern within a sequence by avoiding unnecessary
348
+ comparisons after a mismatch. This table determines how many characters can be skipped after a mismatch.
348
349
 
349
- !=!=!=!=!=!=!=!=!=!=!=!=!=!=!=!=
350
+ Example
351
+ ========
352
+ >>> kmp_table("AGCTGATCGTACGTAAGCTAGCTA")
353
+ [0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 1, 1, 2, 3, 4, 1, 2, 3, 4, 1]
354
+ >>>
355
+ :param pattern: The pattern for which to generate the KMP table.
356
+ :return: A list representing the KMP table for the given pattern.
350
357
 
351
358
 
352
- <<< Here are the newly added functions >>>
359
+ findall(seq: Union[list, tuple, str], pat: Union[list, tuple, str]) -> list
360
+ Introduction
361
+ ==========
362
+ Find all indices of the subsequence 'pat' in 'seq'.
353
363
 
364
+ This function is designed to handle sequences such as lists, tuples, or strings and find all indices
365
+ of specified subsequences. It allows overlapping matches.
354
366
 
355
- PyPyNum
356
- ├── special
357
- │ └── FUNCTION
358
- │ ├── qbinomial(n: typing.Union[int, float, complex], m: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
359
- │ │ # Calculate the q-binomial coefficient of n and m with parameter q.
360
- │ ├── qfactorial(n: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
361
- │ │ # Compute the q-factorial of n with parameter q.
362
- │ ├── qgamma(n: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
363
- │ │ # Calculate the q-gamma function of n with parameter q.
364
- │ └── qpochhammer(a: typing.Union[int, float, complex], q: typing.Union[int, float, complex], n: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
365
- │ # Compute the q-Pochhammer symbol for given a, q, and n.
366
- ├── multiprec
367
- │ └── FUNCTION
368
- │ ├── mp_catalan(sigfigs: int) -> decimal.Decimal
369
- │ # Calculate the Catalan's constant with a specified number of significant figures using multiprecision arithmetic.
370
- ├── seqs
371
- │ └── FUNCTION
372
- │ ├── padovan(n: int, single: bool) -> typing.Union[int, list]
373
- │ │ # Generate the Padovan sequence up to the nth term.
374
- │ ├── pelllucas(n: int, single: bool) -> typing.Union[int, list]
375
- │ │ # Generate the Pell-Lucas sequence up to the nth term.
376
- │ ├── perrin(n: int, single: bool) -> typing.Union[int, list]
377
- │ │ # Generate the Perrin sequence up to the nth term.
378
- │ └── sylvester(n: int, single: bool) -> typing.Union[int, list]
379
- │ # Generate the Sylvester sequence up to the nth term.
380
- ├── tools
381
- │ └── FUNCTION
382
- │ ├── lcsubseq(x: typing.Union[list, tuple, str], y: typing.Union[list, tuple, str]) -> list
383
- │ │ # Find the longest common subsequence between two sequences x and y.
384
- │ └── lcsubstr(x: typing.Union[list, tuple, str], y: typing.Union[list, tuple, str]) -> list
385
- │ # Find the longest common substring between two sequences x and y.
386
- ├── matrices
387
- │ ├── CLASS
388
- │ │ └── Matrix(pypynum.arrays.Array)/__init__(self: Any, data: Any, check: Any) -> Any
389
- │ │ # Initialize a Matrix object from a given data array.
390
- │ └── FUNCTION
391
- │ ├── perm_mat(num_rows: int, num_cols: int, row_swaps: typing.Union[list, tuple], col_swaps: typing.Union[list, tuple], rtype: typing.Callable) -> typing.Any
392
- │ │ # Create a permutation matrix based on specified row and column swaps.
393
- │ └── perm_mat_indices(num_rows: int, num_cols: int, row_swaps: typing.Union[list, tuple], col_swaps: typing.Union[list, tuple]) -> tuple
394
- │ # Compute the indices for a permutation matrix based on specified row and column swaps.
367
+ Example
368
+ ========
369
+ >>> findall([2, 1, 2, 1, 2, 1, 2, 1], [1, 2, 1, 2])
370
+ [1, 3]
371
+ >>>
372
+ :param seq: The sequence in which to find the subsequence.
373
+ :param pat: The subsequence to be found.
374
+ :return: A list of starting indices where the subsequence is found.
395
375
 
396
376
 
397
- !=!=!=!=!=!=!=!=!=!=!=!=!=!=!=!=
377
+ ---------------------------------------------------------------------------------------
378
+ | q-functions generalize classical math functions by introducing parameter q. |
379
+ | They are key in combinatorics and special functions, widely applied. |
380
+ | As q approaches 1, they revert to classical forms. |
381
+ | Examples include q-factorials, q-binomial coefficients, Jackson q-Bessel functions. |
382
+ | These functions are crucial in fractals, chaotic systems, quantum groups. |
383
+ | They provide tools for solving complex mathematical challenges effectively. |
384
+ ---------------------------------------------------------------------------------------
385
+
386
+
387
+ Here are the 12 new q-functions added in the current version (adding the previous 4 makes a total of 16):
388
+
398
389
 
399
- Other functions and classes have
400
- also undergone certain
401
- modifications, such as adding a
402
- "reduce" parameter to the "qr"
403
- function to determine whether to
404
- crop the matrix.
390
+ qbeta(a: Union[int, float, complex], b: Union[int, float, complex], q: Union[int, float, complex]) -> Union[int, float, complex]
391
+ qcos_large(x: Union[int, float, complex], q: Union[int, float, complex]) -> Union[int, float, complex]
392
+ qcos_small(x: Union[int, float, complex], q: Union[int, float, complex]) -> Union[int, float, complex]
393
+ qcosh_large(x: Union[int, float, complex], q: Union[int, float, complex]) -> Union[int, float, complex]
394
+ qcosh_small(x: Union[int, float, complex], q: Union[int, float, complex]) -> Union[int, float, complex]
395
+ qexp_large(z: Union[int, float, complex], q: Union[int, float, complex]) -> Union[int, float, complex]
396
+ qexp_small(z: Union[int, float, complex], q: Union[int, float, complex]) -> Union[int, float, complex]
397
+ qpi(q: Union[int, float, complex]) -> Union[int, float, complex]
398
+ qsin_large(x: Union[int, float, complex], q: Union[int, float, complex]) -> Union[int, float, complex]
399
+ qsin_small(x: Union[int, float, complex], q: Union[int, float, complex]) -> Union[int, float, complex]
400
+ qsinh_large(x: Union[int, float, complex], q: Union[int, float, complex]) -> Union[int, float, complex]
401
+ qsinh_small(x: Union[int, float, complex], q: Union[int, float, complex]) -> Union[int, float, complex]
405
402
 
406
403
  !=!=!=!=!=!=!=!=!=!=!=!=!=!=!=!=
407
404
  ```
@@ -439,15 +436,16 @@ PyPyNum
439
436
  │ ├── asarray(data: Any) -> Any
440
437
  │ ├── aslist(data: Any) -> Any
441
438
  │ ├── boolarray(data: Any) -> Any
442
- │ ├── fill(shape: Any, sequence: Any, repeat: Any, pad: Any, rtype: Any) -> Any
443
- │ ├── full(shape: Any, fill_value: Any, rtype: Any) -> Any
444
- │ ├── full_like(a: Any, fill_value: Any, rtype: Any) -> Any
439
+ │ ├── fill(shape: typing.Union[list, tuple], sequence: typing.Union[list, tuple], repeat: bool, pad: typing.Any, rtype: typing.Callable) -> typing.Any
440
+ │ ├── full(shape: typing.Union[list, tuple], fill_value: typing.Any, rtype: typing.Callable) -> typing.Any
441
+ │ ├── full_like(a: typing.Any, fill_value: typing.Any, rtype: typing.Callable) -> typing.Any
445
442
  │ ├── get_shape(data: Any) -> Any
446
443
  │ ├── is_valid_array(_array: Any, _shape: Any) -> Any
447
- │ ├── ones(shape: Any, rtype: Any) -> Any
448
- │ ├── ones_like(a: Any, rtype: Any) -> Any
449
- │ ├── zeros(shape: Any, rtype: Any) -> Any
450
- └── zeros_like(a: Any, rtype: Any) -> Any
444
+ │ ├── ones(shape: typing.Union[list, tuple], rtype: typing.Callable) -> typing.Any
445
+ │ ├── ones_like(a: typing.Any, rtype: typing.Callable) -> typing.Any
446
+ │ ├── tensorproduct(tensors: pypynum.arrays.Array) -> pypynum.arrays.Array
447
+ ├── zeros(shape: typing.Union[list, tuple], rtype: typing.Callable) -> typing.Any
448
+ │ └── zeros_like(a: typing.Any, rtype: typing.Callable) -> typing.Any
451
449
  ├── chars
452
450
  │ ├── CLASS
453
451
  │ └── FUNCTION
@@ -501,7 +499,7 @@ PyPyNum
501
499
  │ ├── gamma_pdf(x: Any, shape: Any, scale: Any) -> Any
502
500
  │ ├── geometric_pmf(k: Any, p: Any) -> Any
503
501
  │ ├── hypergeom_pmf(k: Any, mg: Any, n: Any, nt: Any) -> Any
504
- │ ├── inv_gauss_pdf(x: Any, mu: Any, lambda_: Any, alpha: Any) -> Any
502
+ │ ├── invgauss_pdf(x: Any, mu: Any, lambda_: Any, alpha: Any) -> Any
505
503
  │ ├── levy_pdf(x: Any, c: Any) -> Any
506
504
  │ ├── log_logistic_cdf(x: Any, alpha: Any, beta: Any) -> Any
507
505
  │ ├── log_logistic_pdf(x: Any, alpha: Any, beta: Any) -> Any
@@ -647,7 +645,7 @@ PyPyNum
647
645
  │ ├── cosh(x: typing.Union[int, float]) -> typing.Union[int, float]
648
646
  │ ├── cot(x: typing.Union[int, float]) -> typing.Union[int, float]
649
647
  │ ├── coth(x: typing.Union[int, float]) -> typing.Union[int, float]
650
- │ ├── cov(x: typing.Union[list, tuple], y: typing.Union[list, tuple], dof: int) -> typing.Union[int, float, complex]
648
+ │ ├── cov(x: typing.Union[list, tuple], y: typing.Union[list, tuple], ddof: int) -> typing.Union[int, float, complex]
651
649
  │ ├── crt(n: typing.Union[list, tuple], a: typing.Union[list, tuple]) -> int
652
650
  │ ├── csc(x: typing.Union[int, float]) -> typing.Union[int, float]
653
651
  │ ├── csch(x: typing.Union[int, float]) -> typing.Union[int, float]
@@ -695,13 +693,13 @@ PyPyNum
695
693
  │ ├── sinh(x: typing.Union[int, float]) -> typing.Union[int, float]
696
694
  │ ├── skew(data: typing.Union[list, tuple]) -> float
697
695
  │ ├── square_mean(numbers: typing.Union[list, tuple]) -> typing.Union[int, float, complex]
698
- │ ├── std(numbers: typing.Union[list, tuple], dof: int) -> typing.Union[int, float, complex]
696
+ │ ├── std(numbers: typing.Union[list, tuple], ddof: int) -> typing.Union[int, float, complex]
699
697
  │ ├── sumprod(arrays: typing.Union[list, tuple]) -> typing.Union[int, float, complex]
700
698
  │ ├── tan(x: typing.Union[int, float]) -> typing.Union[int, float]
701
699
  │ ├── tanh(x: typing.Union[int, float]) -> typing.Union[int, float]
702
700
  │ ├── totient(n: int) -> int
703
701
  │ ├── upper_gamma(s: typing.Union[int, float, complex], x: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
704
- │ ├── var(numbers: typing.Union[list, tuple], dof: int) -> typing.Union[int, float, complex]
702
+ │ ├── var(numbers: typing.Union[list, tuple], ddof: int) -> typing.Union[int, float, complex]
705
703
  │ ├── xlogy(x: typing.Union[int, float, complex], y: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
706
704
  │ └── zeta(alpha: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
707
705
  ├── matrices
@@ -848,10 +846,22 @@ PyPyNum
848
846
  │ ├── hyp1f1(a0: typing.Union[int, float, complex], b0: typing.Union[int, float, complex], z: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
849
847
  │ ├── hyp2f1(a0: typing.Union[int, float, complex], a1: typing.Union[int, float, complex], b0: typing.Union[int, float, complex], z: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
850
848
  │ ├── hyppfq(a: typing.Union[list, tuple], b: typing.Union[list, tuple], z: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
849
+ │ ├── qbeta(a: typing.Union[int, float, complex], b: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
851
850
  │ ├── qbinomial(n: typing.Union[int, float, complex], m: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
851
+ │ ├── qcos_large(x: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
852
+ │ ├── qcos_small(x: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
853
+ │ ├── qcosh_large(x: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
854
+ │ ├── qcosh_small(x: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
855
+ │ ├── qexp_large(z: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
856
+ │ ├── qexp_small(z: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
852
857
  │ ├── qfactorial(n: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
853
858
  │ ├── qgamma(n: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
854
- └── qpochhammer(a: typing.Union[int, float, complex], q: typing.Union[int, float, complex], n: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
859
+ ├── qpi(q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
860
+ │ ├── qpochhammer(a: typing.Union[int, float, complex], q: typing.Union[int, float, complex], n: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
861
+ │ ├── qsin_large(x: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
862
+ │ ├── qsin_small(x: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
863
+ │ ├── qsinh_large(x: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
864
+ │ └── qsinh_small(x: typing.Union[int, float, complex], q: typing.Union[int, float, complex]) -> typing.Union[int, float, complex]
855
865
  ├── stattest
856
866
  │ ├── CLASS
857
867
  │ └── FUNCTION
@@ -870,8 +880,7 @@ PyPyNum
870
880
  │ │ └── Tensor(pypynum.arrays.Array)/__init__(self: Any, data: Any, check: Any) -> Any
871
881
  │ └── FUNCTION
872
882
  │ ├── ten(data: list) -> pypynum.tensors.Tensor
873
- ├── tensor_and_number(tensor: Any, operator: Any, number: Any) -> Any
874
- │ └── tensorproduct(tensors: pypynum.tensors.Tensor) -> pypynum.tensors.Tensor
883
+ └── tensor_and_number(tensor: Any, operator: Any, number: Any) -> Any
875
884
  ├── test
876
885
  │ ├── CLASS
877
886
  │ └── FUNCTION
@@ -882,10 +891,13 @@ PyPyNum
882
891
  │ ├── CLASS
883
892
  │ └── FUNCTION
884
893
  │ ├── classify(array: typing.Union[list, tuple]) -> dict
894
+ │ ├── cos_sim(seq1: typing.Union[list, tuple, str], seq2: typing.Union[list, tuple, str], is_vector: bool) -> float
885
895
  │ ├── dedup(iterable: typing.Union[list, tuple, str]) -> typing.Union[list, tuple, str]
886
896
  │ ├── fast_pow(a: typing.Any, n: int, init: typing.Any, mul: typing.Callable) -> typing.Any
897
+ │ ├── findall(seq: typing.Union[list, tuple, str], pat: typing.Union[list, tuple, str]) -> list
887
898
  │ ├── frange(start: typing.Union[int, float], stop: typing.Union[int, float], step: float) -> list
888
899
  │ ├── geomspace(start: typing.Union[int, float], stop: typing.Union[int, float], number: int) -> list
900
+ │ ├── kmp_table(pattern: typing.Union[list, tuple, str]) -> list
889
901
  │ ├── lcsubseq(x: typing.Union[list, tuple, str], y: typing.Union[list, tuple, str]) -> list
890
902
  │ ├── lcsubstr(x: typing.Union[list, tuple, str], y: typing.Union[list, tuple, str]) -> list
891
903
  │ ├── levenshtein(x: typing.Union[list, tuple, str], y: typing.Union[list, tuple, str]) -> int
@@ -894,6 +906,7 @@ PyPyNum
894
906
  │ ├── primality(n: int, iter_num: int) -> bool
895
907
  │ ├── prime_factors(integer: int, dictionary: bool, pollard_rho: bool) -> typing.Union[list, dict]
896
908
  │ ├── primes(limit: int) -> list
909
+ │ ├── replace(seq: typing.Union[list, tuple], old: typing.Union[list, tuple], new: typing.Union[list, tuple], count: int) -> typing.Union[list, tuple]
897
910
  │ ├── semiprimes(limit: int) -> list
898
911
  │ ├── split(iterable: typing.Union[list, tuple, str], key: typing.Union[list, tuple], retain: bool) -> list
899
912
  │ └── twinprimes(limit: int) -> list