Syntax and Symbol Dictionaries
The MathJSON format is independent of any source or target language (Latex, MathASCII, etc…) or of any specific interpretation of the symbols used in a MathJSON expression (
A syntax dictionary defines how a MathJSON expression can be expressed into a specific target language (serialization) or constructed from a source language (parsing).
It includes definitions such as:
Powerfunction is represented as “
Dividefunction is represented as “
A symbol dictionary defines the vocabulary used by a MathJSON expression. This dictionary is independent of the syntax used to parse/serialize from another language but it defines the meaning of the symbols used in a MathJSON expression.
An entry in a symbol dictionary includes information necessary to correctly interpret it.
Piis a transcendental number whose value is approximately 3.14159265…”
Addfunction is associative, commutative, pure, idempotent and can be applied to arbitrary number of Real or Complex numbers”.
A domain is roughly a combination of a type in a traditional programming language and an “assumption” in some CAS software. It can be associated with a symbol to provide some contextual information about this symbol, for example: “x is an integer”.
Each entry in the symbol dictionary indicate the domain of the symbol, and for functions the expected domain of its argument and the domain of its result (its codomain).
Customizing the Dictionaries
It is possible to provide custom syntax and symbol dictionaries, or to modify the default ones.
When no dictionaries are provided, default ones are used automatically.
This section describe the symbols defined in the default dictionaries. For convenience, the information below combine the information included in the default Latex syntax dictionary and the default global dictionary.