Link to the HomePage

An OO System for Mathematica, Version 3

Programming Object Oriented with Mathematica



There are applications, which which may be improved, if the software is programmed objectorientedly. Object-oriented languages gained much prominence. Some programming languages are natively object-oriented, e.g. Java, others were made object-oriented after their creation, e.g. C/C++.

Mathematica seems well suited for the addition of object-oriented features.

Mathematica is a language, which may be useful beyond the realm of Mathematics especially, if oo is taken into account. It is essentially an interpreted language, an attribute, which may be advantageous in many cases compared with the compiled languages Java and C++. It is also a very powerful language.

The oo system, which is delt with here, is - in the opinion of the author - a good implementation of the object-oriented features for Mathematica. A comparison with other oo languages is supplied.
The following features of the system deserve to be mentioned explicitly:

  • full polymorphism
  • multiple inheritance
  • the possibility to store objects on external media, with some support for making selections according to serveral criteria
  • the support of class arrays in objects. (a feature not supported in any other object oriented language.)
  • Debugging: Formal errors in participating classes are reported, when an object is created.

    The following link contains a comparison of the oo system for Mathematica with other oo languages in html format.
    To a Comparison of the OO System for Mathematica with other OO Languages.

    The following link leads to the documentation of the oo system in PDF format.
    To the Documentation of the OO System

    Here you find a collection of "frequently asked questions"
    To the FAQ

    The software of the oo system may be downloaded here:
    Download the Software of the OO System for Mathematica
    The software is offered in the form of a zip archive. The zip archive contains a file with the code of the system and an example (no notebook).
    Please, take notice, that the variable $classPath must contain the full path of the directory, in which the classes are stored. No changes are necessary, if the zip file is extracted to C:.
    In order to execute the code, you have to invocate Mathematica and execute "File/Open Special" and "Kernel/Evaluation/Evaluate Notebook".

    The following zip file contains examples, which may be loaded and executed. The oo system package oosys.m has to be in the AddOns/Appplications directory.
    Download Examples

    You are invited to send me programs and classes, which may be useful for other Mathematica users, as email appendices in the form of zip files to the following email adddress:
    oosys@schmitther.de
    I shall then store them on my web site in a similar way as the examples.

    Please, do not hesitate to contact me, if you have problems or if you want to make suggestions.

    Comments and critique are welcome!