MathRuler is a powerful and versatile Python library, currently at version 0.1.0, designed to simplify and enhance mathematical calculations. It aims to provide tools for handling equations, units, and general computations, leveraging symbolic and numerical backends. As an early-stage library, its API is subject to iterative improvements with a rapid release cadence.
pip install mathrulerVerified import paths — ran on the pinned version, not inferred.
Initializes a MathRuler instance and demonstrates solving a simple equation, evaluating an expression, and using variables. The `.equation()` method returns an equation object that can be further manipulated, for example, to solve for a specific variable. The `.evaluate()` method directly computes an expression.
Always consult the latest GitHub README and documentation for current API usage. Pin specific minor versions if stability is critical for your project, but be prepared for potential refactoring when upgrading.
When encountering unexpected results, simplify your expressions or break them into smaller, more explicit parts. Refer to the documentation (or source code for 0.1.0) for supported syntax and operations. Avoid shorthand or implicit operations that might not be universally parsed.
For applications requiring high precision, consider using MathRuler's symbolic capabilities where applicable, or explicitly implement decimal arithmetic. Be aware that comparisons of floating-point results should often involve a tolerance (epsilon) rather than direct equality checks.