mingmath 0.2.0__tar.gz → 0.3.1__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.
@@ -0,0 +1,161 @@
1
+ Metadata-Version: 2.4
2
+ Name: mingmath
3
+ Version: 0.3.1
4
+ Summary: A Python package for undergraduate mathematics, including Calculus, Linear Algebra, Data Structures, Recursion, OOP, Scientific Computing, File I/O, Data Visualization, Graph Theory, and Advanced Mathematics.
5
+ Author-email: Thayapan <m.thayapan@gmail.com>
6
+ License: MIT
7
+ License-File: LICENSE
8
+ Keywords: calculus,data structures,gmpy2,linear algebra,mathematics,matplotlib,networkx,numpy,oop,pari,plotly,pyvista,recursion,sagemath,scipy,seaborn,sympy
9
+ Classifier: Development Status :: 3 - Alpha
10
+ Classifier: Intended Audience :: Education
11
+ Classifier: License :: OSI Approved :: MIT License
12
+ Classifier: Programming Language :: Python
13
+ Classifier: Programming Language :: Python :: 3
14
+ Classifier: Programming Language :: Python :: 3.8
15
+ Classifier: Programming Language :: Python :: 3.9
16
+ Classifier: Programming Language :: Python :: 3.10
17
+ Classifier: Programming Language :: Python :: 3.11
18
+ Classifier: Programming Language :: Python :: 3.12
19
+ Classifier: Topic :: Education
20
+ Classifier: Topic :: Scientific/Engineering :: Mathematics
21
+ Requires-Python: >=3.8
22
+ Requires-Dist: cypari2
23
+ Requires-Dist: gmpy2
24
+ Requires-Dist: matplotlib
25
+ Requires-Dist: networkx
26
+ Requires-Dist: numpy
27
+ Requires-Dist: plotly
28
+ Requires-Dist: pyvista
29
+ Requires-Dist: scipy
30
+ Requires-Dist: seaborn
31
+ Requires-Dist: sympy
32
+ Description-Content-Type: text/markdown
33
+
34
+ # MingMath Package
35
+
36
+ MingMath is a Python package for undergraduate mathematics.
37
+
38
+ It provides functions related to Calculus, Linear Algebra,
39
+ Data Structures, String Processing, Recursion, OOP,
40
+ Scientific Computing, File I/O, Data Visualization,
41
+ Graph Theory, and Advanced Mathematics.
42
+
43
+ ## Installation
44
+
45
+ ```bash
46
+ pip install mingmath
47
+ ```
48
+
49
+ ## Usage
50
+
51
+ ```python
52
+ import mingmath
53
+
54
+ # Calculus
55
+ print(mingmath.derivative_power(3, 2))
56
+ print(mingmath.definite_integral_power(2, 2, 0, 3))
57
+
58
+
59
+ # Linear Algebra
60
+ A = [[1, 2], [3, 4]]
61
+ B = [[5, 6], [7, 8]]
62
+
63
+ print(mingmath.matrix_add(A, B))
64
+ print(mingmath.matrix_multiply(A, B))
65
+
66
+
67
+ # Data Structures and String Processing
68
+ print(mingmath.reverse_string("MingMath"))
69
+ print(mingmath.list_sum([1, 2, 3, 4, 5]))
70
+ print(mingmath.dictionary_keys({"name": "MingMath","year": 2026}))
71
+ print(mingmath.set_union({1, 2}, {2, 3}))
72
+
73
+
74
+ # Recursive Functions
75
+ print(mingmath.factorial_recursive(5))
76
+ print(mingmath.fibonacci_recursive(6))
77
+ print(mingmath.fibonacci_memo(10))
78
+
79
+
80
+ # Object-Oriented Programming
81
+ number = mingmath.Number(10)
82
+ print(number)
83
+ scientific_number = mingmath.ScientificNumber(5)
84
+ print(scientific_number.square())
85
+ print(scientific_number.cube())
86
+
87
+
88
+ # NumPy
89
+ print(mingmath.numpy_mean([1, 2, 3, 4, 5]))
90
+ print(mingmath.numpy_matrix_determinant([[1, 2],[3, 4]]))
91
+
92
+
93
+ # SymPy
94
+ print(mingmath.sympy_derivative("x**3 + 2*x"))
95
+ print(mingmath.sympy_integral("2*x"))
96
+
97
+
98
+ # SciPy
99
+ print(mingmath.scipy_mean([1, 2, 3, 4, 5]))
100
+
101
+
102
+ # File I/O
103
+ mingmath.write_text_file("example.txt","Hello MingMath!")
104
+ print(mingmath.read_text_file("example.txt"))
105
+
106
+
107
+ # Matplotlib
108
+ x = [1, 2, 3, 4, 5]
109
+ y = [1, 4, 9, 16, 25]
110
+
111
+ mingmath.plot_line(x, y)
112
+
113
+
114
+ # Seaborn
115
+ x = [1, 2, 3, 4, 5]
116
+ y = [2, 4, 3, 5, 6]
117
+
118
+ mingmath.plot_scatter(x, y)
119
+
120
+
121
+ # Plotly
122
+ mingmath.plot_bar(["A", "B", "C"],[10, 20, 15])
123
+
124
+
125
+ # NetworkX
126
+ edges = [("A", "B"),("B", "C"),("A", "C")]
127
+
128
+ print(mingmath.graph_degrees(edges))
129
+ print(mingmath.shortest_path(edges, "A", "C"))
130
+
131
+
132
+ # PyVista
133
+ import numpy as np
134
+
135
+ x = np.linspace(-2, 2, 20)
136
+ y = np.linspace(-2, 2, 20)
137
+
138
+ X, Y = np.meshgrid(x, y)
139
+
140
+ Z = X**2 + Y**2
141
+
142
+ grid = mingmath.create_3d_surface(X, Y, Z)
143
+
144
+ print(grid)
145
+
146
+
147
+ # GMPY2
148
+ print(mingmath.high_precision_sqrt("2"))
149
+
150
+ print(mingmath.high_precision_pi())
151
+
152
+
153
+ # PARI/GP
154
+ print(mingmath.pari_factorial(5))
155
+
156
+ print(mingmath.pari_factorization(60))
157
+
158
+
159
+ # SageMath
160
+ print(mingmath.sage_available())
161
+ ```
@@ -0,0 +1,128 @@
1
+ # MingMath Package
2
+
3
+ MingMath is a Python package for undergraduate mathematics.
4
+
5
+ It provides functions related to Calculus, Linear Algebra,
6
+ Data Structures, String Processing, Recursion, OOP,
7
+ Scientific Computing, File I/O, Data Visualization,
8
+ Graph Theory, and Advanced Mathematics.
9
+
10
+ ## Installation
11
+
12
+ ```bash
13
+ pip install mingmath
14
+ ```
15
+
16
+ ## Usage
17
+
18
+ ```python
19
+ import mingmath
20
+
21
+ # Calculus
22
+ print(mingmath.derivative_power(3, 2))
23
+ print(mingmath.definite_integral_power(2, 2, 0, 3))
24
+
25
+
26
+ # Linear Algebra
27
+ A = [[1, 2], [3, 4]]
28
+ B = [[5, 6], [7, 8]]
29
+
30
+ print(mingmath.matrix_add(A, B))
31
+ print(mingmath.matrix_multiply(A, B))
32
+
33
+
34
+ # Data Structures and String Processing
35
+ print(mingmath.reverse_string("MingMath"))
36
+ print(mingmath.list_sum([1, 2, 3, 4, 5]))
37
+ print(mingmath.dictionary_keys({"name": "MingMath","year": 2026}))
38
+ print(mingmath.set_union({1, 2}, {2, 3}))
39
+
40
+
41
+ # Recursive Functions
42
+ print(mingmath.factorial_recursive(5))
43
+ print(mingmath.fibonacci_recursive(6))
44
+ print(mingmath.fibonacci_memo(10))
45
+
46
+
47
+ # Object-Oriented Programming
48
+ number = mingmath.Number(10)
49
+ print(number)
50
+ scientific_number = mingmath.ScientificNumber(5)
51
+ print(scientific_number.square())
52
+ print(scientific_number.cube())
53
+
54
+
55
+ # NumPy
56
+ print(mingmath.numpy_mean([1, 2, 3, 4, 5]))
57
+ print(mingmath.numpy_matrix_determinant([[1, 2],[3, 4]]))
58
+
59
+
60
+ # SymPy
61
+ print(mingmath.sympy_derivative("x**3 + 2*x"))
62
+ print(mingmath.sympy_integral("2*x"))
63
+
64
+
65
+ # SciPy
66
+ print(mingmath.scipy_mean([1, 2, 3, 4, 5]))
67
+
68
+
69
+ # File I/O
70
+ mingmath.write_text_file("example.txt","Hello MingMath!")
71
+ print(mingmath.read_text_file("example.txt"))
72
+
73
+
74
+ # Matplotlib
75
+ x = [1, 2, 3, 4, 5]
76
+ y = [1, 4, 9, 16, 25]
77
+
78
+ mingmath.plot_line(x, y)
79
+
80
+
81
+ # Seaborn
82
+ x = [1, 2, 3, 4, 5]
83
+ y = [2, 4, 3, 5, 6]
84
+
85
+ mingmath.plot_scatter(x, y)
86
+
87
+
88
+ # Plotly
89
+ mingmath.plot_bar(["A", "B", "C"],[10, 20, 15])
90
+
91
+
92
+ # NetworkX
93
+ edges = [("A", "B"),("B", "C"),("A", "C")]
94
+
95
+ print(mingmath.graph_degrees(edges))
96
+ print(mingmath.shortest_path(edges, "A", "C"))
97
+
98
+
99
+ # PyVista
100
+ import numpy as np
101
+
102
+ x = np.linspace(-2, 2, 20)
103
+ y = np.linspace(-2, 2, 20)
104
+
105
+ X, Y = np.meshgrid(x, y)
106
+
107
+ Z = X**2 + Y**2
108
+
109
+ grid = mingmath.create_3d_surface(X, Y, Z)
110
+
111
+ print(grid)
112
+
113
+
114
+ # GMPY2
115
+ print(mingmath.high_precision_sqrt("2"))
116
+
117
+ print(mingmath.high_precision_pi())
118
+
119
+
120
+ # PARI/GP
121
+ print(mingmath.pari_factorial(5))
122
+
123
+ print(mingmath.pari_factorization(60))
124
+
125
+
126
+ # SageMath
127
+ print(mingmath.sage_available())
128
+ ```
@@ -1,48 +1,72 @@
1
- [build-system]
2
- requires = ["hatchling"]
3
- build-backend = "hatchling.build"
4
-
5
- [project]
6
- name = "mingmath"
7
- version = "0.2.0"
8
- description = "A Python package for undergraduate mathematics, including Calculus, Linear Algebra, Data Structures, Recursion, OOP, and Scientific Computing."
9
- readme = "README.md"
10
- requires-python = ">=3.8"
11
- license = { text = "MIT" }
12
-
13
- authors = [
14
- { name = "Thayapan", email = "m.thayapan@gmail.com" }
15
- ]
16
-
17
- keywords = [
18
- "mathematics",
19
- "calculus",
20
- "linear algebra",
21
- "data structures",
22
- "recursion",
23
- "numpy",
24
- "scipy",
25
- "sympy"
26
- ]
27
-
28
- classifiers = [
29
- "Development Status :: 3 - Alpha",
30
- "Intended Audience :: Education",
31
- "License :: OSI Approved :: MIT License",
32
- "Programming Language :: Python :: 3",
33
- "Programming Language :: Python :: 3.8",
34
- "Programming Language :: Python :: 3.9",
35
- "Programming Language :: Python :: 3.10",
36
- "Programming Language :: Python :: 3.11",
37
- "Programming Language :: Python :: 3.12",
38
- ]
39
-
40
- dependencies = [
41
- "numpy",
42
- "scipy",
43
- "sympy",
44
- "matplotlib"
45
- ]
46
-
47
- [tool.hatch.build.targets.wheel]
48
- packages = ["src/mingmath"]
1
+ [build-system]
2
+ requires = ["hatchling"]
3
+ build-backend = "hatchling.build"
4
+
5
+
6
+ [project]
7
+ name = "mingmath"
8
+ version = "0.3.1"
9
+
10
+ description = "A Python package for undergraduate mathematics, including Calculus, Linear Algebra, Data Structures, Recursion, OOP, Scientific Computing, File I/O, Data Visualization, Graph Theory, and Advanced Mathematics."
11
+
12
+ readme = "README.md"
13
+
14
+ requires-python = ">=3.8"
15
+
16
+ license = { text = "MIT" }
17
+
18
+ authors = [
19
+ { name = "Thayapan", email = "m.thayapan@gmail.com" }
20
+ ]
21
+
22
+ keywords = [
23
+ "mathematics",
24
+ "calculus",
25
+ "linear algebra",
26
+ "data structures",
27
+ "recursion",
28
+ "oop",
29
+ "numpy",
30
+ "scipy",
31
+ "sympy",
32
+ "matplotlib",
33
+ "seaborn",
34
+ "plotly",
35
+ "networkx",
36
+ "pyvista",
37
+ "gmpy2",
38
+ "pari",
39
+ "sagemath"
40
+ ]
41
+
42
+ classifiers = [
43
+ "Development Status :: 3 - Alpha",
44
+ "Intended Audience :: Education",
45
+ "License :: OSI Approved :: MIT License",
46
+ "Programming Language :: Python",
47
+ "Programming Language :: Python :: 3",
48
+ "Programming Language :: Python :: 3.8",
49
+ "Programming Language :: Python :: 3.9",
50
+ "Programming Language :: Python :: 3.10",
51
+ "Programming Language :: Python :: 3.11",
52
+ "Programming Language :: Python :: 3.12",
53
+ "Topic :: Education",
54
+ "Topic :: Scientific/Engineering :: Mathematics"
55
+ ]
56
+
57
+ dependencies = [
58
+ "numpy",
59
+ "scipy",
60
+ "sympy",
61
+ "matplotlib",
62
+ "seaborn",
63
+ "plotly",
64
+ "networkx",
65
+ "pyvista",
66
+ "gmpy2",
67
+ "cypari2"
68
+ ]
69
+
70
+
71
+ [tool.hatch.build.targets.wheel]
72
+ packages = ["src/mingmath"]
@@ -0,0 +1,107 @@
1
+ """
2
+ MingMath - A mathematics package for undergraduate students.
3
+ """
4
+
5
+ # Calculus
6
+ from .calculus import (
7
+ derivative_power,
8
+ definite_integral_power,
9
+ limit_polynomial,
10
+ maclaurin_exp,
11
+ critical_points_quadratic,
12
+ )
13
+
14
+ # Linear Algebra
15
+ from .linear import (
16
+ matrix_add,
17
+ matrix_multiply,
18
+ determinant_2x2,
19
+ transpose,
20
+ dot_product,
21
+ )
22
+
23
+ # String Processing and Data Structures
24
+ from .data_structures import (
25
+ reverse_string,
26
+ count_vowels,
27
+ list_sum,
28
+ tuple_to_list,
29
+ dictionary_keys,
30
+ set_union,
31
+ set_intersection,
32
+ )
33
+
34
+ # Recursion and OOP
35
+ from .recursive import (
36
+ factorial_recursive,
37
+ fibonacci_recursive,
38
+ fibonacci_memo,
39
+ Number,
40
+ PositiveNumber,
41
+ Printable,
42
+ AdvancedNumber,
43
+ ScientificNumber,
44
+ EvenNumber,
45
+ HybridNumber,
46
+ )
47
+
48
+ # NumPy, SciPy, SymPy, Matplotlib
49
+ from .advanced_math import (
50
+ numpy_mean,
51
+ numpy_matrix_multiply,
52
+ numpy_matrix_determinant,
53
+ sympy_derivative,
54
+ sympy_integral,
55
+ scipy_mean,
56
+ plot_data,
57
+ )
58
+
59
+ # File I/O
60
+ from .file_io import (
61
+ write_text_file,
62
+ read_text_file,
63
+ append_text_file,
64
+ )
65
+
66
+ # NetworkX
67
+ from .networkx_functions import (
68
+ create_graph,
69
+ graph_degrees,
70
+ shortest_path,
71
+ )
72
+
73
+ # Matplotlib, Seaborn, Plotly
74
+ from .visualization import (
75
+ plot_line,
76
+ plot_scatter,
77
+ plot_bar,
78
+ )
79
+
80
+ # PyVista
81
+ from .pyvista_functions import (
82
+ create_3d_surface,
83
+ show_3d_surface,
84
+ )
85
+
86
+ # GMPY2
87
+ from .gmpy2_functions import (
88
+ high_precision_sqrt,
89
+ high_precision_pi,
90
+ high_precision_factorial,
91
+ )
92
+
93
+ # PARI/GP
94
+ from .pari_functions import (
95
+ pari_factorial,
96
+ pari_factorization,
97
+ pari_gcd,
98
+ )
99
+
100
+ # SageMath
101
+ from .sage_functions import (
102
+ sage_available,
103
+ sage_calculate,
104
+ )
105
+
106
+
107
+ __version__ = "0.3.1"
@@ -0,0 +1,30 @@
1
+ """
2
+ File I/O functions for reading and writing text files.
3
+ """
4
+
5
+
6
+ def write_text_file(filename, text):
7
+ """Write text to a file."""
8
+ try:
9
+ with open(filename, "w", encoding="utf-8") as file:
10
+ file.write(text)
11
+ except OSError as e:
12
+ raise OSError(f"Cannot write file: {e}")
13
+
14
+
15
+ def read_text_file(filename):
16
+ """Read text from a file."""
17
+ try:
18
+ with open(filename, "r", encoding="utf-8") as file:
19
+ return file.read()
20
+ except FileNotFoundError:
21
+ raise FileNotFoundError(f"File not found: {filename}")
22
+
23
+
24
+ def append_text_file(filename, text):
25
+ """Append text to a file."""
26
+ try:
27
+ with open(filename, "a", encoding="utf-8") as file:
28
+ file.write(text)
29
+ except OSError as e:
30
+ raise OSError(f"Cannot append to file: {e}")
@@ -0,0 +1,23 @@
1
+ """
2
+ High-precision mathematics functions using GMPY2.
3
+ """
4
+
5
+ import gmpy2
6
+
7
+
8
+ def high_precision_sqrt(number):
9
+ """Calculate square root with high precision."""
10
+ return gmpy2.sqrt(gmpy2.mpfr(number))
11
+
12
+
13
+ def high_precision_pi():
14
+ """Return pi with high precision."""
15
+ return gmpy2.const_pi()
16
+
17
+
18
+ def high_precision_factorial(n):
19
+ """Calculate factorial using GMPY2."""
20
+ if n < 0:
21
+ raise ValueError("n must be non-negative")
22
+
23
+ return gmpy2.fac(n)
@@ -0,0 +1,17 @@
1
+ import networkx as nx
2
+
3
+
4
+ def create_graph(edges):
5
+ graph = nx.Graph()
6
+ graph.add_edges_from(edges)
7
+ return graph
8
+
9
+
10
+ def graph_degrees(edges):
11
+ graph = create_graph(edges)
12
+ return dict(graph.degree())
13
+
14
+
15
+ def shortest_path(edges, start, end):
16
+ graph = create_graph(edges)
17
+ return nx.shortest_path(graph, start, end)
@@ -0,0 +1,25 @@
1
+ """
2
+ Number theory functions using PARI/GP through cypari2.
3
+ """
4
+
5
+ from cypari2 import Pari
6
+
7
+ pari = Pari()
8
+
9
+
10
+ def pari_factorial(n):
11
+ """Calculate factorial using PARI/GP."""
12
+ if n < 0:
13
+ raise ValueError("n must be non-negative")
14
+
15
+ return pari(f"factorial({n})")
16
+
17
+
18
+ def pari_factorization(n):
19
+ """Factorize an integer using PARI/GP."""
20
+ return pari(f"factor({n})")
21
+
22
+
23
+ def pari_gcd(a, b):
24
+ """Calculate GCD using PARI/GP."""
25
+ return pari(f"gcd({a}, {b})")
@@ -0,0 +1,32 @@
1
+ """
2
+ PyVista functions for 3D mathematical visualization.
3
+ """
4
+
5
+ import numpy as np
6
+ import pyvista as pv
7
+
8
+
9
+ def create_3d_surface(x, y, z):
10
+ """Create a 3D surface from x, y and z data."""
11
+ x = np.asarray(x)
12
+ y = np.asarray(y)
13
+ z = np.asarray(z)
14
+
15
+ if x.ndim == 1 and y.ndim == 1:
16
+ X, Y = np.meshgrid(x, y)
17
+ else:
18
+ X, Y = x, y
19
+
20
+ if z.shape != X.shape:
21
+ raise ValueError("z must have the same shape as the mesh grid")
22
+
23
+ return pv.StructuredGrid(X, Y, z)
24
+
25
+
26
+ def show_3d_surface(x, y, z):
27
+ """Display a 3D surface."""
28
+ grid = create_3d_surface(x, y, z)
29
+
30
+ plotter = pv.Plotter()
31
+ plotter.add_mesh(grid)
32
+ plotter.show()
@@ -0,0 +1,26 @@
1
+ """
2
+ Mathematical functions using SageMath.
3
+ """
4
+
5
+ import shutil
6
+ import subprocess
7
+
8
+
9
+ def sage_available():
10
+ """Check whether SageMath is installed."""
11
+ return shutil.which("sage") is not None
12
+
13
+
14
+ def sage_calculate(expression):
15
+ """Calculate an expression using SageMath."""
16
+ if not sage_available():
17
+ raise RuntimeError("SageMath is not installed or not available in PATH")
18
+
19
+ result = subprocess.run(
20
+ ["sage", "-c", f"print({expression})"],
21
+ capture_output=True,
22
+ text=True,
23
+ check=True
24
+ )
25
+
26
+ return result.stdout.strip()
@@ -0,0 +1,31 @@
1
+ """
2
+ Data visualization functions using Matplotlib, Seaborn and Plotly.
3
+ """
4
+
5
+ import matplotlib.pyplot as plt
6
+ import seaborn as sns
7
+ import plotly.express as px
8
+
9
+
10
+ def plot_line(x, y):
11
+ """Create a line plot using Matplotlib."""
12
+ plt.plot(x, y)
13
+ plt.xlabel("x")
14
+ plt.ylabel("y")
15
+ plt.title("Line Plot")
16
+ plt.show()
17
+
18
+
19
+ def plot_scatter(x, y):
20
+ """Create a scatter plot using Seaborn."""
21
+ sns.scatterplot(x=x, y=y)
22
+ plt.xlabel("x")
23
+ plt.ylabel("y")
24
+ plt.title("Scatter Plot")
25
+ plt.show()
26
+
27
+
28
+ def plot_bar(x, y):
29
+ """Create a bar chart using Plotly."""
30
+ fig = px.bar(x=x, y=y, title="Bar Chart")
31
+ fig.show()
mingmath-0.2.0/PKG-INFO DELETED
@@ -1,142 +0,0 @@
1
- Metadata-Version: 2.4
2
- Name: mingmath
3
- Version: 0.2.0
4
- Summary: A Python package for undergraduate mathematics, including Calculus, Linear Algebra, Data Structures, Recursion, OOP, and Scientific Computing.
5
- Author-email: Thayapan <m.thayapan@gmail.com>
6
- License: MIT
7
- License-File: LICENSE
8
- Keywords: calculus,data structures,linear algebra,mathematics,numpy,recursion,scipy,sympy
9
- Classifier: Development Status :: 3 - Alpha
10
- Classifier: Intended Audience :: Education
11
- Classifier: License :: OSI Approved :: MIT License
12
- Classifier: Programming Language :: Python :: 3
13
- Classifier: Programming Language :: Python :: 3.8
14
- Classifier: Programming Language :: Python :: 3.9
15
- Classifier: Programming Language :: Python :: 3.10
16
- Classifier: Programming Language :: Python :: 3.11
17
- Classifier: Programming Language :: Python :: 3.12
18
- Requires-Python: >=3.8
19
- Requires-Dist: matplotlib
20
- Requires-Dist: numpy
21
- Requires-Dist: scipy
22
- Requires-Dist: sympy
23
- Description-Content-Type: text/markdown
24
-
25
- # MingMath Package
26
-
27
- MingMath is a Python package for undergraduate mathematics.
28
-
29
- It provides functions related to Calculus, Linear Algebra,
30
- Data Structures, Recursion, OOP, and Scientific Computing.
31
-
32
- ## Features
33
-
34
- ### Calculus
35
-
36
- - Power rule derivative
37
- - Definite integral
38
- - Polynomial limit
39
- - Maclaurin series
40
- - Critical points of quadratic functions
41
-
42
- ### Linear Algebra
43
-
44
- - Matrix addition
45
- - Matrix multiplication
46
- - Determinant of a 2x2 matrix
47
- - Matrix transpose
48
- - Dot product
49
-
50
- ### Data Structures and String Processing
51
-
52
- - String reversal
53
- - Vowel counting
54
- - List operations
55
- - Tuple conversion
56
- - Dictionary operations
57
- - Set union
58
- - Set intersection
59
- - Exception handling
60
-
61
- ### Recursive Functions
62
-
63
- - Recursive factorial
64
- - Recursive Fibonacci
65
- - Fibonacci with memoization
66
-
67
- ### Object-Oriented Programming
68
-
69
- - Class and Object
70
- - Magic methods
71
- - Single inheritance
72
- - Multiple inheritance
73
- - Multilevel inheritance
74
- - Hierarchical inheritance
75
- - Hybrid inheritance
76
-
77
- ### Scientific Computing
78
-
79
- - NumPy
80
- - SciPy
81
- - SymPy
82
- - Matplotlib
83
-
84
- ## Installation
85
-
86
- ```bash
87
- pip install mingmath
88
- ```
89
-
90
- ## Usage
91
-
92
- ```python
93
- import mingmath
94
-
95
- # Calculus
96
- print(mingmath.derivative_power(3, 2))
97
- print(mingmath.definite_integral_power(2, 2, 0, 3))
98
- print(mingmath.limit_polynomial([1, 2, 3], 2))
99
- print(mingmath.maclaurin_exp(1))
100
- print(mingmath.critical_points_quadratic(1, -4, 3))
101
-
102
- # Linear Algebra
103
- A = [[1, 2], [3, 4]]
104
- B = [[5, 6], [7, 8]]
105
-
106
- print(mingmath.matrix_add(A, B))
107
- print(mingmath.matrix_multiply(A, B))
108
- print(mingmath.determinant_2x2(A))
109
- print(mingmath.transpose(A))
110
-
111
- # Data Structures
112
- print(mingmath.reverse_string("MingMath"))
113
- print(mingmath.count_vowels("Mathematics"))
114
- print(mingmath.list_sum([1, 2, 3, 4, 5]))
115
-
116
- # Recursive Functions
117
- print(mingmath.factorial_recursive(5))
118
- print(mingmath.fibonacci_recursive(10))
119
- print(mingmath.fibonacci_memo(10))
120
-
121
- # NumPy
122
- print(mingmath.numpy_mean([1, 2, 3, 4, 5]))
123
-
124
- # SymPy
125
- print(mingmath.sympy_derivative("x**2 + 3*x"))
126
- print(mingmath.sympy_integral("2*x"))
127
-
128
- # SciPy
129
- print(mingmath.scipy_mean([1, 2, 3, 4, 5]))
130
-
131
- # OOP
132
- number = mingmath.HybridNumber(3)
133
- print(number.summary())
134
- ```
135
-
136
- ## Version
137
-
138
- Current version: **0.2.0**
139
-
140
- ## License
141
-
142
- MIT License
mingmath-0.2.0/README.md DELETED
@@ -1,118 +0,0 @@
1
- # MingMath Package
2
-
3
- MingMath is a Python package for undergraduate mathematics.
4
-
5
- It provides functions related to Calculus, Linear Algebra,
6
- Data Structures, Recursion, OOP, and Scientific Computing.
7
-
8
- ## Features
9
-
10
- ### Calculus
11
-
12
- - Power rule derivative
13
- - Definite integral
14
- - Polynomial limit
15
- - Maclaurin series
16
- - Critical points of quadratic functions
17
-
18
- ### Linear Algebra
19
-
20
- - Matrix addition
21
- - Matrix multiplication
22
- - Determinant of a 2x2 matrix
23
- - Matrix transpose
24
- - Dot product
25
-
26
- ### Data Structures and String Processing
27
-
28
- - String reversal
29
- - Vowel counting
30
- - List operations
31
- - Tuple conversion
32
- - Dictionary operations
33
- - Set union
34
- - Set intersection
35
- - Exception handling
36
-
37
- ### Recursive Functions
38
-
39
- - Recursive factorial
40
- - Recursive Fibonacci
41
- - Fibonacci with memoization
42
-
43
- ### Object-Oriented Programming
44
-
45
- - Class and Object
46
- - Magic methods
47
- - Single inheritance
48
- - Multiple inheritance
49
- - Multilevel inheritance
50
- - Hierarchical inheritance
51
- - Hybrid inheritance
52
-
53
- ### Scientific Computing
54
-
55
- - NumPy
56
- - SciPy
57
- - SymPy
58
- - Matplotlib
59
-
60
- ## Installation
61
-
62
- ```bash
63
- pip install mingmath
64
- ```
65
-
66
- ## Usage
67
-
68
- ```python
69
- import mingmath
70
-
71
- # Calculus
72
- print(mingmath.derivative_power(3, 2))
73
- print(mingmath.definite_integral_power(2, 2, 0, 3))
74
- print(mingmath.limit_polynomial([1, 2, 3], 2))
75
- print(mingmath.maclaurin_exp(1))
76
- print(mingmath.critical_points_quadratic(1, -4, 3))
77
-
78
- # Linear Algebra
79
- A = [[1, 2], [3, 4]]
80
- B = [[5, 6], [7, 8]]
81
-
82
- print(mingmath.matrix_add(A, B))
83
- print(mingmath.matrix_multiply(A, B))
84
- print(mingmath.determinant_2x2(A))
85
- print(mingmath.transpose(A))
86
-
87
- # Data Structures
88
- print(mingmath.reverse_string("MingMath"))
89
- print(mingmath.count_vowels("Mathematics"))
90
- print(mingmath.list_sum([1, 2, 3, 4, 5]))
91
-
92
- # Recursive Functions
93
- print(mingmath.factorial_recursive(5))
94
- print(mingmath.fibonacci_recursive(10))
95
- print(mingmath.fibonacci_memo(10))
96
-
97
- # NumPy
98
- print(mingmath.numpy_mean([1, 2, 3, 4, 5]))
99
-
100
- # SymPy
101
- print(mingmath.sympy_derivative("x**2 + 3*x"))
102
- print(mingmath.sympy_integral("2*x"))
103
-
104
- # SciPy
105
- print(mingmath.scipy_mean([1, 2, 3, 4, 5]))
106
-
107
- # OOP
108
- number = mingmath.HybridNumber(3)
109
- print(number.summary())
110
- ```
111
-
112
- ## Version
113
-
114
- Current version: **0.2.0**
115
-
116
- ## License
117
-
118
- MIT License
@@ -1,93 +0,0 @@
1
- """
2
- MingMath Package
3
- รวมฟังก์ชันเกี่ยวกับ Calculus, Linear Algebra,
4
- Data Structures, Recursion, OOP และ Scientific Computing
5
- """
6
-
7
- from .calculus import (
8
- derivative_power,
9
- definite_integral_power,
10
- limit_polynomial,
11
- maclaurin_exp,
12
- critical_points_quadratic
13
- )
14
-
15
- from .linear import (
16
- matrix_add,
17
- matrix_multiply,
18
- determinant_2x2,
19
- transpose,
20
- dot_product
21
- )
22
-
23
- from .data_structures import (
24
- reverse_string,
25
- count_vowels,
26
- list_sum,
27
- tuple_to_list,
28
- dictionary_keys,
29
- set_union,
30
- set_intersection
31
- )
32
-
33
- from .recursive import (
34
- factorial_recursive,
35
- fibonacci_recursive,
36
- fibonacci_memo,
37
- Number,
38
- PositiveNumber,
39
- Printable,
40
- AdvancedNumber,
41
- ScientificNumber,
42
- EvenNumber,
43
- HybridNumber
44
- )
45
-
46
- from .advanced_math import (
47
- numpy_mean,
48
- numpy_matrix_multiply,
49
- numpy_matrix_determinant,
50
- sympy_derivative,
51
- sympy_integral,
52
- scipy_mean,
53
- plot_data
54
- )
55
-
56
- __version__ = "0.2.0"
57
-
58
- __all__ = [
59
- "derivative_power",
60
- "definite_integral_power",
61
- "limit_polynomial",
62
- "maclaurin_exp",
63
- "critical_points_quadratic",
64
- "matrix_add",
65
- "matrix_multiply",
66
- "determinant_2x2",
67
- "transpose",
68
- "dot_product",
69
- "reverse_string",
70
- "count_vowels",
71
- "list_sum",
72
- "tuple_to_list",
73
- "dictionary_keys",
74
- "set_union",
75
- "set_intersection",
76
- "factorial_recursive",
77
- "fibonacci_recursive",
78
- "fibonacci_memo",
79
- "Number",
80
- "PositiveNumber",
81
- "Printable",
82
- "AdvancedNumber",
83
- "ScientificNumber",
84
- "EvenNumber",
85
- "HybridNumber",
86
- "numpy_mean",
87
- "numpy_matrix_multiply",
88
- "numpy_matrix_determinant",
89
- "sympy_derivative",
90
- "sympy_integral",
91
- "scipy_mean",
92
- "plot_data"
93
- ]
File without changes