|
|
|
|
|
|
|
|
|
Basic structural optimization of expressions
|
|
|
|
|
|
Organization: | RMIT University |
Department: | Department of Mathematics |
|
|
|
|
|
|
2004-09-21
|
|
|
|
|
|
Basic structural optimization of expressions. A classic program written in Mathematica version 2, and still working unchanged in Mathematica version 5. In 19 lines, the definition of the Optimize[expr_] function manages to use no less that 28 diverse Mathematica functions including: Append, Apply, Count, DeleteCases, Depth, Drop, First, Flatten, Fold, FoldList, Last, Length, Level, List, Literal, Map, MapIndexed, Partition, Position, ReplaceAll, Reverse, Rule, Select, Table, Take, Transpose, and Union. All it all does something very useful.
|
|
|
|
|
|
|
|
|
|
|
|
optimize, efficiency, compiling, optimization, expression, syntactic optimization, structural optimization
|
|
|
|
|
|
| Optimize.m (7.4 KB) - Mathematica Package |
|
|
|
|
|
|
|
| | | | | |
|