Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Content MathML vs. OpenMath for model exchange

In my research group, we have different people doing algebraic modelling in different symbolic tools such as Symbolic Toolbox in Matlab and Sympy in Python. These models are then typically exported to C-code and copy-pasted-adapted into our own symbolic C++-based tools for further symbolic manipulation.

When looking for an alternative to this hardly maintainable approach I found two formats that looked more or less standardized: OpenMath and "Content MathML". Note that we are only interested in the semantics, no pretty printing.

What is the relation between these two formats? Can both be used to store and exchange mathematical expressions between tools?

Are there yet other more or less standardized exchange format for mathematical expressions?

like image 690
Joel Avatar asked Jul 21 '12 10:07

Joel


1 Answers

The formats are very closely related (and defined at roughly the same time by an overlapping set of people) (I'm an editor of both MathML and OpenMath specs for example). In the current version of Content MathML (MathML 3) this is formalised far more than in earlier versions and all the MathML content elements are given semantics in terms of openmath symbols. So formally the only difference is syntax, Content MathML has a "strict" subset that is a formal encoding of OpenMath, plus a set of convenience elements that are given formal rewrite rules to the OpenMath equivalent subset.

Apart from the syntax of the expressions themselves, if you are straying away from the fixed set of operators pre-defined in MathML, you need some way of recording definitions, and here both OpenMath and MathML use the same OpenMath "Content Dictionary" format.

like image 72
David Carlisle Avatar answered Oct 27 '22 00:10

David Carlisle