[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[O] [PATCH] org.el: Add support for LaTeX to MathML conversion
From: |
Jambunathan K |
Subject: |
[O] [PATCH] org.el: Add support for LaTeX to MathML conversion |
Date: |
Fri, 09 Sep 2011 01:27:57 +0530 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (windows-nt) |
> IMPORTANT: I am following this mail with a patch to org.el which will
> add support for LaTeX-to-MathML conversion using an external
> converter.
MathToWeb is available from
http://www.mathtoweb.com/cgi-bin/mathtoweb_home.pl
Your .emacs should look something like this.
(custom-set-variables
'(org-latex-to-mathml-convert-command "java -jar %j -unicode -force -df %o %I")
'(org-latex-to-mathml-jar-file "~/tmp-odt/mathtoweb.jar"))
I am attaching odt files used with both dvipng and mathml options. The
latex-mathml.odt reports an error on one of the $$ $$ equations.
Note to reviewers: Can someone enhance the patch so that
`org-latex-src-embed-type can take all the various anchors that a latex
equation could use - inline, display-unnumbered, display-numbered, what
else?
Note to the users:
1. You need to not only apply this patch but also pull from the repo for
full support.
2. Currently there is NO support for numbered and displayed equations
which go like this
x = y (1)
y = z (2)
0001-org.el-Add-support-for-LaTeX-to-MathML-conversion.patch
Description: Text Data
#+TITLE: latex-mathml.org
#+AUTHOR: Jambunathan K
#+EMAIL: address@hidden
#+DATE: 2011-09-09 Fri
#+DESCRIPTION:
#+KEYWORDS:
#+LANGUAGE: en
#+OPTIONS: H:3 num:t toc:t \n:nil @:t ::t |:t ^:t -:t f:t *:t <:t
#+OPTIONS: TeX:t LaTeX:t skip:nil d:nil todo:t pri:nil tags:not-in-toc
#+EXPORT_SELECT_TAGS: export
#+EXPORT_EXCLUDE_TAGS: noexport
#+LINK_UP:
#+LINK_HOME:
#+XSLT:
* LaTeX Fragments
** LaTeX Fragment1
# See org-format-latex-options
There is a equation down below.
\begin{equation}
e = \frac{1}{2}mv^2
\end{equation}
** LaTeX Fragment2
#+CAPTION: Radicals
#+LABEL: Equation:1
\begin{equation}
x=\sqrt{b}
\end{equation}
If $a^2=b$ and \( b=2 \), then the solution must be either $$
a=+\sqrt{2} $$ or \[ a=-\sqrt{2} \].
latex-mathml.odt
Description: latex-mathml.odt
latex-dvipng.odt
Description: latex-dvipng.odt