Yacas under the hood
The Yacas architecture
Startup, scripts and
.def
files
Object types
Yacas evaluation scheme
Rules
Examples of using rules
Structured programming and control flow
Additional syntactic sugar
Using "Macro rules" (e.g.
NFunction
)
Macro expansion
Scope of variable bindings
Evaluation of expressions
The LISP heritage
Yacas
-specific extensions for CAS implementations
Destructive operations
Coding style
Introduction
Interactions of rules and types
Ordering of rules
Writing new library functions
Reporting errors
Advanced example 1: parsing expressions (
CForm
)
Recursive parsing of expression trees
Handling precedence of infix operations
Yacas programming pitfalls
All rules are global
Objects that look like functions
Guessing when arguments are evaluated and when not
Evaluating variables in the wrong scope
Debugging in Yacas
Introduction
The interactive command line debugger
The trace facilities
Custom evaluation facilities
The basic infrastructure for custom evaluation
A simple interactive debugger
Profiling
The Yacas Debugger
Advanced example 2: implementing a non-commutative algebra
The problem
First steps
Structure of expressions
Implementing the canonical form
Implementing commutation relations
Avoiding infinite recursion
Implementing VEV()
GNU Free Documentation License