Menu

#15 LaTeX support

open
nobody
None
5
2008-06-05
2008-06-05
Jiri Tyr
No

Hello Max,

I have got an idea. It would be nice, if Jeuclid would know to translate LaTeX into MathML internally. Then we could use LaTeX instead of pure MathML in the FO source file.

Jeuclid could detect if <math></math> contains "$" on the begin and on the end of the inner text. If so, it would call method latexToMathml or whatever and translate the inner text to MathML. Then the text would be replaced by proper MathML code and Jeuclid would continue as it works now.

There already exists such implementation:
http://www.cmt.phys.kyushu-u.ac.jp/~M.Sakurai/java/sdoc/mathml/test.html
Maybe you could just overtake it and implement it into the Jeuclid.

Example of the functionality in Jeuclid:
<math xmlns="http://www.w3.org/1998/Math/MathML">
$x^2$
</math>

translated into:

<math xmlns="http://www.w3.org/1998/Math/MathML">
<mrow>
<msup>
<mi>x</mi>
<mn>2</mn>
</msup>
</mrow>
</math>

What do you think about that?

Best Regards,
Jiri

Discussion

  • Max Berger

    Max Berger - 2008-06-06

    Logged In: YES
    user_id=99210
    Originator: NO

    Jiri,

    I like the idea in general, but I have two issues with it:

    1) It should not use the MathML namespace and the MathML tags. Maybe something like
    <latex xmlns="http://jeuclid.sf.net/ns/fopext">x^2</latex>
    (tagname and namespace can change)
    Rationale: It would be clear that this is not MathML, it would also be clear that this is renderable by JEuclid

    2) The library you liked to is GPL, which is incompatible with the Apache License. Further, the library you linked to has not been updated in years, e.g. is inactive. We should try to find another solution.

    Max

     
  • Jiri Tyr

    Jiri Tyr - 2008-06-06

    Logged In: YES
    user_id=498168
    Originator: YES

    Hello Max,

    the Japan JAVA applet was just for the inspiration. I suppose there doesn't exists any JAVA project which would provide exact functionality what we are looking for. I have found few similar projects:

    http://sourceforge.net/search/?words=mathml+AND+latex&type_of_search=soft&pmode=0&words=mathml+AND+latex+AND+java&Search=Search

    but their licenses are probably also incompatible with Apache License.

    Regards,
    Jiri

     
  • Sylvestre Ledru

    Sylvestre Ledru - 2010-12-14

    If you still want to go in this direction, you might be interested in:
    http://forge.scilab.org/index.php/p/jlatexmath/

     

Log in to post a comment.