Presentations
Schedule of Events
|
|
Computing with Both Content and Presentation MathML
in Mathematica
Neil Soiffer
Wolfram Research, Inc.
Abstract
Mathematica V4, released in the summer of 1999, included support
for importing and exporting MathML. As one would expect, content MathML
that is imported into Mathematica can be evaluated. Importation
is typically accomplished by simply pasting the MathML into a Mathematica
notebook. The MathML is converted into the equivalent Mathematica
functions, and the result is displayed. The result can be edited or evaluated
just as any other user input can be edited or evaluated.
Mathematica is also capable of evaluating a significant amount
of imported presentation MathML. This is possible for two reasons. First,
in Mathematica it is possible to define sets of interpretation rules.
This effectively allows one to define a new input syntax in Mathematica
as long as the operators share the precedence of Mathematica's operators.
Secondly, disambiguation features added to MathML, such as making explicit
the difference between function call and multiplication and distinguishing
between the variable i and the Sqrt[-1], eliminate a large number
of error-prone heuristics.
These same features also help make presentation MathML accessible.
Although the primary means for users to import MathML into Mathematica
is simply to paste it in, Mathematica can also be used as a computation
server for MathML (again, both content and presentation MathML). Programs
can connect to Mathematica via either MathLink (a general
communication protocol that is used to call or be called by Mathematica)
or J/Link (a Java interface for calling the Mathematica kernel).
Using these protocols, Mathematica can be used as a compute engine
that accepts Mathematica or MathML input and can return the results
in a number of forms including MathML. For web-based usages, Mathematica
can be wrapped up as a servlet for MathML computations.
|