Pattern-matching algebraic expressions!
- Match anything
- Match anything or nothing (optional term)
expr in the group named
- Match any of the expressions
- Capture all terms matching
- Match anything except
- Match any expression which uses the named variables
- Match the terms in
expr in any order, following the laws of commutativity. (Use if you only want to use commutativity in certain places)
- Match nothing. Useful as an empty term to set up a sum where you want all terms to match one pattern.