📐 Calpylus
Calpylus is a powerful and beginner-friendly Python library built for symbolic and visual calculus. Whether you're a student studying calculus, an educator building tools, or a developer creating math-powered apps — Calpylus has your back with expressive syntax, beautiful plotting, and a growing feature set.
Developed with ❤️ by Mohammad Mahfuz Rahman
✨ Features
- ✅ Symbolic Differentiation and Integration
- ✅ 2D Function Plotting (Matplotlib-based)
- ✅ 3D Surface Plotting (
graph3D) - ✅ Simple, intuitive API
- ✅ Built using
SymPyandMatplotlib
📦 Installation
Install directly from PyPI:
pip install calpylus
Or install from GitHub (for development):
pip install git+https://github.com/mahfuz0712/Calpylus.git
🧪 Quick Start
import matplotlib.pyplot as plt
from calpylus.calculus import Calculus as cl
# Define a function
f = "sin(x)"
g = "cos(x)"
# Plot 2D graphs
cl.graph(f)
cl.graph(g)
# Plot a 3D surface
cl.graph3D("sin(x)*cos(y)")
# Final blocking call to keep all windows open until closed manually
plt.show()
Differential & Integral Calculus
Symbolically differentiate an expression with respect to a variable.
cl.differentiate("x**2 + sin(x)")
# Output: 2*x + cos(x)
cl.differentiate(expr: str, variable='x')
Symbolically integrate an expression with respect to a variable.
cl.integrate("x**2")
# Output: x**3/3
cl.integrate(expr: str, variable='x')
Graphical View
Plots a 2D graph of a function of x.
cl.graph(expr: str)
cl.graph("x**2 + 2*x + 1")
3D Graph
Plots a 3D surface plot of a function in terms of x and y.
cl.graph3D(expr: str)
cl.graph3D("sin(x) * cos(y)")
🧠 Under the Hood
| Feature | Library Used |
|---|---|
| Symbolic Math | sympy |
| 2D/3D Plotting | matplotlib |
🤝 Contributing
Pull requests are welcome! For major changes, please open an issue first to discuss what you would like to change or add.
To run locally:
git clone https://github.com/mahfuz0712/Calpylus.git
cd Calpylus
pip install -e .
📜 License
This project is licensed under the MIT License.
🙋 FAQ
Q: Can I use this library without knowing advanced calculus?
A: Yes! The library is designed to be intuitive and beginner-friendly.
Q: Will you add support for limits, series expansion, etc.?
A: Absolutely. These features are planned in future releases.
🌐 Links
“Mathematics is the music of reason.” — James Joseph Sylvester
Calpylus turns that music into code. 🎶
Metadata
Release files for Calpylus 0.0.5
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| calpylus-0.0.5.tar.gz | 8.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| calpylus-0.0.5-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 21.4 kB
Release files / calpylus-0.0.5.tar.gz
| Download URL | calpylus-0.0.5.tar.gz |
|---|---|
| Size | 8.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
fe6f4f7651dc200ea10d1dcba522d0c11b1e60496916010083235d2c1c5e18d4
|
|
BLAKE2b-256 checksum How to use checksums |
464ac12e26d14ec57740727a01a81e037f982f5e4cfd22b8ab207fe3ee71412e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.1
|
Release files / calpylus-0.0.5-py3-none-any.whl
| Download URL | calpylus-0.0.5-py3-none-any.whl |
|---|---|
| Size | 12.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
2e5a8f8553f3d579ee4296d21bebf48eb58552dffc1fc617344480421109b517
|
|
BLAKE2b-256 checksum How to use checksums |
08145a64683a98fbc38909c944497617820e5a77330b14bb1e53693c66b06c5f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.1
|