Skip to content

A high-performance Algebraic Expression Compiler to evaluate and simplify expressions with unlimited-length integers, rationals, and trigonometric functions. Supports symbolic simplifications, arbitrary precision, and processes 100,000+ terms in under 0.5 seconds. Built with Python and Streamlit, with visual parse tree generation.

Notifications You must be signed in to change notification settings

avr-varshan/Algebraic-Expression-Compiler

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🔢 Algebraic Expression Compiler

A high-performance application for evaluating and simplifying algebraic expressions involving unlimited-length integers, rationals, and trigonometric functions. This tool is designed for accuracy, speed, and usability, making it ideal for complex mathematical computations.

🚀 Features

  • Arbitrary Precision: Handles numbers with 100,000+ digits seamlessly.

  • Efficient Processing: Evaluates 100,000+ terms in under 0.5 seconds.

  • Symbolic Simplifications: Combines terms, removes redundancies, and ensures exact results.

  • Visual Parse Trees: Generates visualizations of raw and simplified expressions for debugging and analysis.

  • Optimized Performance: Leverages parallelized tasks and caching to improve speed by up to 50%.

  • Trigonometric Mode: Supports degree and radian modes for trigonometric calculations.

🔧 Tech Stack

  • Programming Language: Python

  • Framework: Streamlit

🖥️ Usage

1. Run Locally

Clone the repository and install the dependencies:

git clone cd pip install -r requirements.txt

Run the app locally:

streamlit run main.py

Visit http://localhost:8501 in your browser.

🌐 Live Demo

Check out the live app : https://algebraic-expression-compiler-36xvtrhkpq5gc3yjseeacp.streamlit.app/

📜 Process Workflow

  1. Tokenization: Converts input into structured tokens.

  2. Parsing: Builds a binary tree based on operator precedence.

  3. Optimization: Simplifies the tree with constant evaluation and term reduction.

  4. Evaluation: Computes results with arbitrary precision.

📊 Performance Benchmarks

  • Handles numbers with 100,000+ digits and 10,000+ terms effortlessly.

  • Evaluates 100,000+ terms in under 0.5 seconds.

  • Simplifies large expressions 40% faster than traditional symbolic systems.

🤝 Contributing

Contributions are welcome! Please fork this repository and submit a pull request for any bug fixes or feature enhancements.

📄 License

This project is licensed under the MIT License.

About

A high-performance Algebraic Expression Compiler to evaluate and simplify expressions with unlimited-length integers, rationals, and trigonometric functions. Supports symbolic simplifications, arbitrary precision, and processes 100,000+ terms in under 0.5 seconds. Built with Python and Streamlit, with visual parse tree generation.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages