meditor


  meditor is a text editor interfaced with a symbolic engine for interpreting mathematical expressions. Primarily, it is intended to solve algebraic equation systems of degree n in m indeterminates, for any nm, by computing the Groebner bases of polynomial ideals.

For example, let us consider this system for the indeterminates x, y:

x2y24
xy1

We put:

groebner4x2y21xyxy

By selecting the text bloc above and by doing "Math->Evaluate" in the menu bar (Ctrl+E), we get:

14x2x44xx3y

, which allows us to find x, then y from x. This operation does not calculate the roots, it just writes the equation. For instance, it would not give a45 but 45a ("= 0" implied).

Groebner basis computation is explained in more details in the file math_background.


  meditor can process vector and matrix expressions. Vectors are denoted as abc and matrices as abcd.

To illustrate their use, let us consider a simple system of linear equations. We write:

matrixa00a01a10a11x0x1b0b1

("= 0" implied ; as meditor cannot deal with non-commutative operations, it is mandatory to use matrixAB instead of AB). By selecting the expression above and by doing "Evaluate", we get:

b0a00x0a01x1b1a10x0a11x1

, which allows us to write the following input, that can be used to solve the linear system:

groebnerb0a00x0a01x1b1a10x0a11x1a00a01a10a11b0b1x0x1

Other vector and matrix operations are listed in quickref, along with all the functions and operations available in meditor.


  meditor allows polynomial solving:

solvecbxax2x
=
root0cba

, variable substitution:

subst1x2xa
=
1a2

, and simplification of expressions using the "simplify" operator:

simplify
=
-1

It is often useful to rewrite an expression in term of elementary functions (log, exp, frac, sqrt, implicit roots), using the "elementary" operator, before simplifying it. For instance:

simplifyelementaryx2x2
=
1

To compute numerical values, one can use the "numeric" operator:

numeric
=
2.718281828459045


  As we can see, meditor knows of some usual functions. It can compute derivatives and integrals too, as shown below:

1xfx
=
f′xfx

fxyzxyzxyz
=
000

taylorxx04
=
1x12x216x3124x4

x11x2
=
root010412xroot0104root110412xroot1104


  meditor can also be used for boolean computations, using modulo 2 as fourth parameter of the "groebner" operation. 0 represents "false", 1 "true", the addition an "exclusive or" and the product an "and". The statement ab, equivalent to ab, or ab, is written : a1b ("= 0" implied).

"sokrates is a man" is written sokrates1man
"a man is mortal" is written man1mortal

We put the system:

groebnersokrates1manman1mortalmanmortalsokrateslex2

"Evaluate", we get:

manmanmortalsokratesmansokratessokratesmortalsokrates

The last equation can be factorized as follows:

factorizesokratesmortalsokrates
=
sokrates1mortal, which reads : sokratesmortal.

Other modulos are also possible.


  Lastly, meditor can produce and render MathML expressions, and convert them back to text via XSLT:

quotex11x2
=
x11x2

x2y2
=
x2y2

It can also produce SVG graphs with the "graph" operator:

graphxx
=
0; 0-6.07-5.05-4.04-3.03-2.02-1.011.012.023.034.045.056.07-6.07-5.05-4.04-3.03-2.02-1.011.012.023.034.045.056.07

, and it can export the result to XHTML for web publishing, and also to PDF.


  The complete syntax of meditor is found in the file grammar. The entry point for the interpreter is the "Expression" token.