|
3 | 3 |
|
4 | 4 | FunKit bridges the gap between symbolic mathematics (SymPy) and numerical computations (NumPy/SciPy), offering a unified interface that maintains mathematical rigor while providing practical tools for real-world problems. |
5 | 5 |
|
6 | | -[](https://www.python.org/downloads/) |
| 6 | + |
7 | 7 | [](https://opensource.org/licenses/MIT) |
8 | 8 |
|
9 | | -**Ready to revolutionize your mathematical computing workflow?** |
10 | | -```bash |
| 9 | +**Ready to revolutionize your mathematical computing workflow?** |
| 10 | +```bash |
11 | 11 | pip install funkit |
12 | | -``` |
| 12 | +``` |
13 | 13 |
|
14 | | -**Have Questions? Take a look at the Q&A:** |
| 14 | +**Have Questions? Take a look at the Q&A:** |
15 | 15 | [Questions & Answers: Addressing Potential Concerns](docs/QA.md) |
16 | 16 |
|
17 | 17 | ## ✨ Key Features |
@@ -45,24 +45,24 @@ result = f(2.5) # Numerically evaluate at x = 2.5 |
45 | 45 |
|
46 | 46 | # Use the .n attribute to access fast numerical methods |
47 | 47 | numerical_roots = f.n.all_roots() |
48 | | -# or call f's n-prefixed methods directly to use variable precision numerical methods |
49 | | -roots = f.nsolve_all() |
| 48 | +# Call f's n-prefixed methods to use variable precision numerical methods |
| 49 | +precise_roots = f.nsolve_all(prec=50) # 50 digits of accuracy |
50 | 50 |
|
51 | | -# Beautiful printing options |
52 | | -f.print() # quick and easy printing |
| 51 | +# quick and easy printing |
| 52 | +f.print() |
53 | 53 | f.print('latex') |
54 | 54 | f.print('mathematica_code') |
55 | 55 | # or |
56 | 56 | print(f.print.latex()) # LaTeX output |
57 | | -print(f.print.ccode()) # Pretty ASCII art |
| 57 | +print(f.print.ccode()) # c code output |
58 | 58 | ``` |
59 | 59 |
|
60 | 60 |
|
61 | | -## 🎯 Numerical Computing |
| 61 | +## 🎯 Numerical Computing |
62 | 62 |
|
63 | 63 | FunKit excels at bridging symbolic and numerical mathematics: |
64 | 64 | ```python |
65 | | -f = Expression("x^3 - 2*x^2 + x - 1") |
| 65 | +f = Expression("x^3 - 2x^2 + x - 1") |
66 | 66 |
|
67 | 67 | # Root finding |
68 | 68 | all_roots = f.n.all_roots(bounds=(-5, 5)) |
@@ -105,13 +105,13 @@ expr = Expression("2x^2 + ln(|x-1|)") |
105 | 105 | from sympy import sin, cos |
106 | 106 | expr = Expression(sin(x) + cos(x)) |
107 | 107 |
|
108 | | -# Numerical methods via .n attribute |
109 | | -roots = expr.n.all_roots(bounds=(-10, 10)) |
110 | | -integral = expr.n.quad(0, 1) # Numerical integration |
111 | | - |
112 | 108 | # Symbolic operations |
113 | 109 | derivative = expr.diff(x) |
114 | 110 | expanded = expr.expand() |
| 111 | + |
| 112 | +# Numerical methods via .n attribute |
| 113 | +roots = expr.n.all_roots(bounds=(-10, 10)) |
| 114 | +integral = expr.n.quad(0, 1) # Numerical integration |
115 | 115 | ``` |
116 | 116 |
|
117 | 117 |
|
|
0 commit comments