Design topics that have come up recently

Maybe we can discuss stuff at length on the mailing list, then move stuff here as it begins to gel. Or we can just park stuff here as it occurs to us.


Themes:

Additional topics in mathematics

  1. Expand class of equations that Maxima can solve (i.e. strengthen the solve function)

    • There is the solver share package; not sure what are its capabilities compared to built-in solve
  2. Improvements to limit computation. This project would have two steps:

    • Implement asymptotic exapnsions of gamma function (factorial), error function, and zeta function by extending Taylor series code.
    • Gruntz algorithm for computing limits. See the dissertation of Dominik Gruntz, circa 1996. The dissertation also has a collection of examples that we could put into the test suite.
  3. Number theory functions, including (1) modular powers, (2) inverses, (3) extended euclidean algorithm, (4) chinese remainder theorem, (5) factorization (using all the best methods, up to and including the number field sieve), (6) discrete logarithms, (7) modular square and nth roots, (8) modular equations, (9) primitive roots, (10) Euler phi function, (11) Moebius function, (12) quadratic residue testing, (13) Jacobi and Legendre symbols

    • There are already some Maxima functions: ezgcd, gcd, gcdex, factor, totient (= Euler phi function), others? These and other functions may be best implemented by importing the number theory functions from GMP, specifically GMPZ stuff. (RJF)
    • Also share/contrib/ifactor.lisp (factorizing, probabilistic prime test, and modular expt)
    • Some Lisp implementations (GCL, Clisp, others?) use GMP for arithmetic. What are the relevant functions in GMP ?
  4. Graph theory. Creating graphs (weighted, unweighted, directed, undirected), drawing graphs (this would require another plotting package to gnuplot), modifying graphs, testing for planarity, euler and hamiltonian paths and circuits. Minimal spanning trees, shortest paths, coloring and matching, flow algorithms.

  5. Boolean algebra and logic. Simplification of boolean expressions, truth tables, satisfyability, disjuntive and conjunctive canonical forms, checking for tautologies and contradictions.

    • boolsimp can simplify some expressions
  6. Linear Algebra. Reduced row echelon form, and some matrix decompositions (LU, QR, Cholesky etc).

    • Some of these functions already exist in src/ and share/. See share/linearalgebra/
  7. Unit step function, delta function, derivatives and integrals of these functions

    • laplace knows a little about delta function, delint in share/integration/delta.mac can do integrals with delta functions
    • Unit step is defined as theta( ) in delta.mac, unitstep( ) in share/simplification/absimp.mac
    • Could implement some stuff related to Green's functions with this in hand
    • Define functions to convert between if/then/else and unit step or delta expressions; integrate, diff, etc would make use of this conversion to handle if/then/else
  8. Solve a differential equation as a generalized power series

    • (Not sure how this differs from existing stuff)
  9. Functions to handle partial differential equations
  10. Symbolic solution of linear programming
  11. Additional numerical methods

    • Systems of equations (beef up mnewton or come up with something else)
    • Numerical solution of PDE's
    • Use Octave as a library to get numerical functions?
    • Raymond Toy has Lisp translations of ODEPACK, MINPACK, HOMPACK, and FISHPACK, which could be integrated with Maxima
    • Other libraries of interest: NTL, MPFR
    • Integrate femlisp http://www.femlisp.org with Maxima
    • Spectral / pseudospectral methods for PDE's (based on linear algebra and special functions already in Maxima)
    • Bigfloat version of Gaussian integration
    • Purely numeric unconstrained and constrained optimization, e.g. stuff from Richard Brent "Algorithms for Minimization Without Derivatives"
  12. Differential geometry
  13. Computational geometry (Delaunay triangulation, Voronoi tessellation, convex hull, point in polygon, etc)
  14. Young tableaux, skew Schur functions
  15. Differentiation of programs
  16. Port symmetry group analysis of PDE's by Hereman et al. to Maxima

    • See: http://www.mines.edu/fs_home/whereman
    • About this package, Raffaele Vitolo writes:

      • "1 Ask the authors the permission of taking their code in Maxima under GPL;
      • "2 Check the code against the new maxima and do possible modification to make it run with the new maxima;
      • "3 Add new features to the code (there are a lot of possibilities in this sense). There are a number of packages about group analysis of ODEs and PDEs around, most of them are for Maple. One of the most famous is Vessiot, by I. Anderson and coworkers http://www.math.usu.edu/fg_mp, unfortunately not available with the source code (but I could ask for it). There is another one whose source is available, Jets http://diffiety.ac.ru."
  17. z-transform
  18. Vector or tuple type (distinct from list and matrix)
  19. Functional differentiation and integration - based on the identity: fdiff(f(x), f(y)) = delta(x - y)
  20. Grassmann symbols.
  21. Error function (erf) for complex arguments

    • Octave might have some code for that

User interface

  1. Notebook interface (mix text, graphics, and equations)

    • Implement notebook as a plugin for OpenOffice? ?
    • TeXmacs? implements a notebook interface, but some people don't like it
  2. Spreadsheet interface

  3. Maybe we should focus on one GUI.
  4. Help system

    • Category system

      • Tag articles with category links, and have the category page give an overview and then a list of all articles in the category with 1-line summary for each one
      • An article can belong to multiple categories, and categories can be grouped into super-categories
      • Any category can contain articles and/or subcategories (i.e., articles are not restricted to the "leaf" categories)
    • Keyword system

      • Associate keywords with each item
      • Search on item names or keywords or both
    • Fuzzy vs sharp search

      • ? by default is a sharp search (return exact matches only)
      • ?? (new) is a fuzzy search (actually that's more like ? at present)
      • ? falls back on ?? if there are no exact matches
      • ?? groups item name, keyword, and category matches separately
    • When describe displays a list of help items, show first line of each item's documentation
    • In html docs, make links to an on-line math reference, such as Wikipedia or Planet Math. E.g. in Maxima doc for Bessel functions, link to articles about Bessel functions.
  5. Single stepping: step through algorithms at some 'appropriate' level of detail.

    • Useful for debugging purposes.
    • Hard to do as most algebra algorithms differ from hand methods.
  6. TeX line breaking

  7. TeX flavor system -- allow user to choose between plain TeX, LaTeX, maybe others (e.g. AMSTeX)
  8. Speech or handwriting input
  9. Select expressions via mouse
  10. Maxima plugin for Eclipse (an extensible programming environment, see: http://eclipse.org)

Programmatic interface

  1. One input, one output mode (obviate need to parse output stream)
  2. Safe mode

    • Refuse to write to file system
    • Limits on cpu time and memory
  3. Maxima server mode (note that maxima --server option makes Maxima a client, not a server)

    • Fiddle with socket options
    • Figure out a scheme for handling out-of-band data
    • Implement some kind of warm start or session-launching mode
  4. Exact save/restore

    • Maxima uses a LOT of special (i.e., global) variables. State of Maxima = current values of all specials
    • This makes it hard to find everything that needs to be saved, and hard to restore everything that needs to be restored
    • "Exact" save/restore would save everything needed to bring Maxima back to the same state
  5. Maxima as a plug-in for Excel or Powerpoint, maybe Word too (selected cells or object become the argument for a Maxima function)
  6. Database interface
  7. "webMaxima" interface for PlanetMath? or other web sites

Plotting

  1. Plotting implementation

    1. Simpler interface for plotting functions
    2. Use cl-plplot to plot stuff. See: http://common-lisp.net/project/cl-plplot
    3. Use pipes instead of files (ideally pipes transmitting binary data, so no need to unparse/reparse numbers)
    4. Matplotlib/Pylab http://matplotlib.sourceforge.net/ creates plots and animations

      • It's a Python library, so using it implies Lisp/Python glue (via CFFI ?)
  2. Plotting features

    1. Interactive 3d graphics

      • Openmath already has some of it. The New Version of Openmath will implement some missing features that made people prefer Gnuplot.
    2. Images (image processing, fractals)

    3. Graphs (circles and arrows diagrams)
    4. Mouse-based parameter control

      • That works in plotdf because The plot's data is generated by the graphic interface (openmath). To do something similar in plot2d, the generation of the plot data could be left to openmath (improve its code with the recent changes introduced in the lisp code for plot2d).
    5. Animations, e.g. animation of a family of curves which depend on a parameter; other kinds of animations?
    6. Basic graphical objects so that more complex custom displays can be programmed. A new graphics syntax is needed, both to create new objects and to make graphics programming more intuitive.
    7. Write a function to plot inequalities; in gnuplot, this should be made with option 'filledcurve'.
    8. Allow options to be specified as my_option = my_value instead of clumsy [my_option, my_value]

    9. Make a namespace or package for plot options and put the plot option symbols in it. set_plot_option is essentially maintaining a namespace of plot options; we need a general namespace/package mechanism anyway.
    10. replot function which recreates the most recent plot, maybe taking new plotting parameter values into account (similar to function of same name in Octave and Matlab).
    11. Plot multiple functions over different ranges (at present all functions in one plot must have the same range)
    12. Accumulate plotted functions (at present each plot2d or plot3d call starts from a blank slate)

      • One could get multiple functions over different ranges by accumulating multiple plots
    13. Allow multiple surfaces in one 3-d plot

Maxima internals and/or implementation

  1. Lexical scope

    • Might implement lexical scope by porting another language (e.g. CLPython) to be the Maxima user language
    • Might implement lexical scope by translating everything to Lisp and banishing (DECLARE (SPECIAL FOO)) stuff from translator
  2. Treat inf and other special values unlike ordinary symbols, e.g. inf - inf => und, not 0.

    • An exploratory implementation can be found on the CVS branch infinity-ops-branch.
  3. Unevaluated conditionals
  4. Bound variables in sum, integrate, etc.
  5. Comment and/or document Lisp functions in src/.
  6. A Maxima package system could be useful.

    1. Cleaner programming constructs: gensyms, namespaces
    2. Maybe including some kind of feature to indicate "load something just once", named require or using or import or something like that
  7. Generalized arithmetic -- some sort of 'object' framework

    1. Interval arithmetic

      • Various underlying numeric types: floats, bfloats, rationals, complex floats, quad-floats, etc.
      • Various kinds of 'interval': lower/upper bounds, fuzzy distributions (trapezoidal), symmetric/radial
      • note that intervals do not conform to some basic Maxima properties, e.g. x-x --> 0 is false
    2. Complexes as numbers (not expressions)
    3. Quaternions
  8. Non-ascii characters in symbols and strings.

    • Use UTF-8 characters to display sum, product, integral, other signs which are now displayed with ascii art?
  9. Special floating point values

    • NaN's, positive/negative infinity, signed zero, denormalized numbers
  10. Bags (composite objects) in general

    • What is desired here?
  11. Provisos (e.g. the expression 1/a assuming that a>0)

    • Seems like this could be subsumed by unevaluated conditionals, or maybe given its own representation (e.g, "1 / a assuming a > 0"). If separate from unevaluated conditionals, how would "1 / a assuming a > 0" differ from "if a > 0 then 1 / a" ?
  12. Standardized algebra syntax

  13. Iterators -- functions which can loop through long lists without ever constructing the whole list
  14. Interface to other programming languages (C, Python, Fortran, etc) to make use of libraries
  15. Get rid of useless specials, rename to ... where they are needed
  16. Make operators like diff, integrate, ... aware of functions rather than expressions
  17. Single line comments like other languages, maybe // (like C++).

    • The Maxima parser already recognizes # at the beginning of a line as a comment (although that's buggy).
    • Ability to nest comments. (Actually, isn't the parser already able to recognize nested comments?)
  18. Reimplement lists and matrices using Lisp arrays for storage

    • Maybe cut out Maxima arrays after that
  19. Save/load arrays of floating point numbers
  20. Load an image (png, jpeg) as an array of numbers (pixel values), also save array of numbers as an image
  21. Load/save audio data as arrays or other data structures

  22. To make Maxima run on a Java VM, build a code generator for Clisp which generates JVM bytecodes instead of Clisp VM bytecodes

Other computer algebra systems:

Several systems with very interesting features and/or algebra.

None of the above


Included from NonGPLnotice

NOTE: This page is has no explicit license. (In particular, it is not licensed under the GNU General Public License.) Therefore the rights of parties other than than the copyright holder are limited to "fair use".