
Discrete Structures
io.github.ZohaibCodez由 GitHub 帳號 ZohaibCodez 發布v0.1.4更新於 Oct 24, 2026
Comprehensive tools for discrete mathematics: logic, algorithms, number theory, cryptography
概覽
本機 MCP 伺服器,為助理提供 21 個離散數學工具:布林邏輯、數論、演算法視覺化,以及古典、RSA 與 AES 密碼學。
- 可以做什麼
- 求值、化簡布林表達式,產生真值表並轉換為 CNF/DNF 形式。判斷質數、質因數分解、計算最大公因數與最小公倍數、模運算和歐拉函數。逐步示範排序、二分搜尋以及 Dijkstra、BFS/DFS 等圖形演算法。使用凱撒、維吉尼亞、RSA 和 AES 進行加解密,並產生 RSA 金鑰對。
- 適用情境
- 適合教學或學習離散數學、演算法與密碼學,練習演算法面試題,或需要附解釋的數論與布林邏輯計算時使用。
- 執行需求
- 以 Python 套件形式在本機執行(需 Python 3.11+),透過 uvx 或 pip 啟動;未宣告帳號、API 金鑰或環境變數。僅支援桌面 MCP 用戶端。
安裝
在 SourceWeft 中
- 開啟 儀表板中的 Discrete Structures,將其新增到工作區。
- 為需要使用其工具的對話啟用該服務。
Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。
其他 MCP 客戶端
參照 儲存庫 中的啟動說明。
README
🎓 Discrete Structures MCP Server
[PyPI version] [Python Version] [MCP Registry] [License: MIT] [Downloads]
Professional-grade AI tools for discrete mathematics, algorithms, and cryptography
Installation • Features • Quick Start • Documentation • Examples
🚀 Overview
Discrete Structures MCP Server is a comprehensive Model Context Protocol server that brings 21 powerful mathematical tools to AI assistants like Claude Desktop, Cline, and Zed. Perfect for students, educators, and developers working with discrete mathematics, data structures, algorithms, and cryptography.
Why Choose This Server?
- 🎯 21 Production-Ready Tools across 4 categories
- 📚 Educational Focus with step-by-step visualizations
- 🔒 Enterprise Cryptography (RSA, AES, Caesar, Vigenere)
- 📊 Algorithm Visualizations for sorting and graph algorithms
- 🧮 Boolean Logic with CNF/DNF conversion
- 🔢 Number Theory including prime factorization and modular arithmetic
- ⚡ Fast Installation via
uvx discrete-structures-mcp - 🌐 MCP Registry Listed for easy discovery
✨ Features
📦 Installation
⚡ Quick Install (Recommended)
📥 Install with pip
🛠️ Development Installation
🎯 Quick Start
Usage with Claude Desktop
Add to your claude_desktop_config.json:
Usage with Other MCP Clients
Compatible with any MCP client:
- Cline - VS Code extension
- Zed - Modern code editor
- Continue - AI code assistant
- Custom MCP clients via Python SDK
💻 Example Tool Calls
💻 Example Tool Calls
🔢 Number Theory Examples
Calculate GCD and LCM
Prime Factorization
Modular Arithmetic
🧮 Boolean Logic Examples
Generate Truth Table
Simplify Boolean Expression
Convert to CNF
📊 Algorithm Visualization Examples
Visualize Bubble Sort
Binary Search
Dijkstra's Algorithm
🔐 Cryptography Examples
RSA Encryption
AES Encryption
Caesar Cipher
🎓 Use Cases
- Computer Science Education - Teach algorithms and data structures
- Cryptography Learning - Understand encryption methods
- Mathematics Research - Number theory and discrete math
- Algorithm Analysis - Visualize complexity and performance
- Code Interviews - Practice common algorithmic problems
- Academic Projects - Implement mathematical concepts
🏗️ Technical Stack
- Language: Python 3.11+
- Framework: Model Context Protocol (MCP)
- Math Libraries: SymPy, NumPy
- Crypto: Python Cryptography library
- Graphs: NetworkX
- Build: UV package manager
📊 Performance
- Startup Time: < 2 seconds
- Response Time: < 100ms for most operations
- Memory: < 50MB baseline
- Concurrency: Async/await support
🔒 Security Note
Educational Purpose: Caesar and Vigenere ciphers are for learning only. Use AES or RSA for real-world encryption.
🤝 Contributing
We welcome contributions! Here's how to get started:
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit changes (
git commit -m 'Add amazing feature') - Push to branch (
git push origin feature/amazing-feature) - Open a Pull Request
See CONTRIBUTING.md for detailed guidelines.
📄 License
This project is licensed under the MIT License - see the LICENSE file for details.
🔗 Links & Resources
Official Links
- 🏠 Homepage: GitHub Repository
- 📦 PyPI Package: discrete-structures-mcp
- 🌐 MCP Registry: Official Listing
- 📝 Documentation: README
- 🐛 Issue Tracker: Report Bugs
Community
- 💬 Discussions: GitHub Discussions
- 📢 Announcements: Watch repository for updates
- 🤝 Contributing: See contribution guide
MCP Resources
- 📖 MCP Documentation: modelcontextprotocol.io
- 🛠️ MCP SDK: Python SDK
- 🌟 MCP Servers: Community Servers
📈 Project Stats
[GitHub stars] [GitHub forks] [GitHub issues] [GitHub pull requests]
🙏 Acknowledgments
- Model Context Protocol team at Anthropic
- SymPy and NumPy communities
- Python Cryptography developers
- NetworkX graph library maintainers
- All contributors and users
📞 Support
- 📧 Email: Open an issue for support
- 💬 Discussions: Use GitHub Discussions
- 🐛 Bugs: Report via Issues
- 💡 Features: Request via Issues with enhancement label
Made with ❤️ for the discrete mathematics and computer science community
⭐ Star this repo if you find it useful! ⭐
來源:mcp-server/README.md,提交 b878c1c
工具
0版本歷史
1- v0.1.4最新Sep 16, 2026
評分
已滿足適用檢查項的 40%
該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。
- 近 30 天內可連通25 分
請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。
- 已宣告認證方式10 分
請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。
- 已列出工具15 分
請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。
- 描述必需15 分
- 圖示10 分
- 文件15 分
- 授權條款10 分
請在儲存庫或註冊中心條目中宣告授權條款。