Scribble python kid has learnt ocaml and want to do ocaml-like things in python (symbolic maths)
Find a file
2024-06-18 17:23:10 +02:00
.idea Change "instances" class variables of Smybols and children of Symbols to Dict instead of List. Start expand.py (not completed) 2024-02-20 01:33:32 +01:00
python_symb Add memoization in basic_modif.py 2024-02-24 03:57:37 +01:00
README.md Update README.md 2024-06-18 17:23:10 +02:00

Python-symbolic

Python-symbolic is a small project written in pure Python that allows you to perform symbolic mathematics on your computer. The focus is on readability and simplicity.

Features

Done:

  • Default type definitions
  • Expression tree implementation
  • Transformation of infix strings to expression trees
  • Visualization of expression trees
  • Expansion of expressions (e.g., a*(a+b) to a^2 + ab)

To-Do:

  • Create a type (BinOperator) for exponents
  • Implement complex numbers
  • Modify expression trees, including:
    • Factorization of expressions (e.g., a^2 + 2ab + b^2 to (a+b)^2)
    • Easy simplification (e.g., sin(x)² + cos(x)² to 1)
  • Define calculus types:
    • Derivative
    • Integral
    • Sum
    • Product
    • Limit

Exemple of visualation of the expression tree (launch tree_visual.py to see)

Screenshot from 2024-02-20 00-14-07