My question is, which Latex features aren't supported by Mathjax? For example, in Latex I can write $\today$ and it will return the current date. This is not possible in Mathjax.
In KaTeX, a Mathjax alternative, there seem to be more troublesome limitations such as \overrightarrow{AB} not working. I was wondering, what the current limitations of Mathjax are, in terms of latex rendering, before using it in a website instead of converting tex equations to png images and inserting those. I have noticed that Wikipedia uses the tex2png approach instead of Mathjax and was wondering whether they just did not want to depend on Mathjax, whether it's not fully supported by all browsers, whether it's too slow, whether the limited feature set of Mathjax is a problem or just legacy?
First and foremost, Mathjax, as its name suggest, supports mathematics typesetting for the web and is not a web-implementation of general-purpose Latex. Here's what this means most notably feature-wise:
No tables
No tikzpictures
No bibliographies
No support for units, e.g. \SI{10}{\hertz} is not possible (requiring the siunitx package in latex)
No special packages, for example no \uwave from package ulem
Within the math-world, Mathjax is covering almost everything. Here is a list of features that are not supported for mathematics typesetting:
Items that require the mathtools package, for example H \xrightharpoondown[under]{over} I\\.
The other question was, why Wikipedia isn't using Mathjax, but has chosen to convert Equations into a png. I think it's because they already had a working solution when Mathjax got popular and don't really have an incentive to switch to Mathjax. Mathjax especially shines, when you need an out of the box solution for rendering math on the web.
Related
I am programming a website on the subject of chemistry and for obvious reasons I also have to include structural and molecular formulas on that site. I want to have as few images as possible on the side and would therefore like to know how I can compile LaTeX code on my website, so I can show everything I could do in LaTeX itself.
Thanks in advance.
As outlined in a previous comment, Chemistry.SE has enabled mhchem in MathJax to allow the rendering of simple formula and reaction equations. The MathJax documention actually gives some directions.
As far as structures of organic molecules are concerned, I'm usually draw them using BkChem and export them as the png images.
If I understand you correctly, you would like to avoid the images themselves and not just the act of drawing. Therefore, the idea to generate the drawings from a linear representation (InChi, SMILES) using openbabel will probably not convince you.
As a matter of fact, it is possible to create structure in LaTeX using chemfig and there have been requests to support this package in MathJax. However, it seems that so far, the strong dependance of chemfig on TikZ has prevented this.
I plan to use Xcode to make an app for the iPhone that displays math equations that high school and college students often use. I do all my math with Mathematica, and it allows me to save such equations in three relevant formats. (1) LaTex (.tex); (2) MathML (.mml); (3) XHTMLMathML.
The Mathemactica documentation says the third format is XHTML with embedded MathML. I found some of the examples at this browser test don't look so good on my iPhone. So I will propbably not rely completly on MathML.
I am a total beginner with Xcode and the three file formats that I mention above, but I have some experience with OOP in C++. Assuming Mathematica can do a good job writing the required LaTeX, MathML, XHHTMLMathML needed for whatever equation, what are the tradeoffs between the three file formats? Can I mix the formats in the same app?
I would suggest to use HTML. The "right" way to include mathematical content is MathML -- which is part of HTML5 (but see below for using TeX).
iOS's UIwebview is webkit based and therefore has the same partial MathML support (though on iOS5 it's significantly worse due to a font bug) so I would also suggest to use MathJax (disclaimer: I'm part of MathJax).
MathJax is an open source javascript library which understands TeX and Asciimath input, converts either one to MathML and renders MathML as HTML-CSS or SVG (in any modern browser).
MathJax has no problem mixing these input formats. Additionally, it has better MathML support than webkit (and you can always configure MathJax to use the native MathML support if you want -- say when you know your content should render fine in webkits native support).
To get you started, you can take a look at this open source app to see how MathJax can be integrated in an iOS app.
I want to find a (preferably) open-source OCR package (for any OS) that is capable of handling a new character set.
The language is Latin, but with some scribal abbreviations, about 10 different abbreviations that aren't in Unicode.
The text has been printed using specially-developed fonts, and I have high-res images of the text.
I'm assuming some training is going to be needed, first to map the scribal abbreviations to ASCII, and then presumably corpus-specific training for the software to learn where the abbreviations tend to appear within words.
Could anyone recommend a (preferably) open-source package capable of handling this?
AFAIK there is no library (free or commercial) that can be used as-is for what you describe (a language with characters not representable by Unicode) ... BUT as a good starting point there is an opensource OCR called Tesseract which you could take and modify for your special scenario... another interesting base could be OCROpus... but beware: this will mean lots of work.
Looking through docs on the TeX website, it seems like almost all documentation for TeX and LaTeX are tutorials on how to use them, how to install fonts, how to get graphics working, etc.
What should I look at if I want to know more about how TeX works? For instance, I want to know about its parser grammar. I want to know how its text engine works, how it decides hyphenation, how it flows text, how it decides on box layouts.
It seems like TeX and LaTeX are built up on several layers of different technologies. (Metafont, etc.) Is there any resources that describe step by step the TeX system from the ground up? How it goes from parsing a text file, into how this is represented and transformed, and finally how it ends up in a particular page layout?
There are essentially two resources on TeX itself: one is the TeXbook by Don Knuth, along with the typeset documented sourcecode itself (Vol's A and C of Computers and Typesetting), the other one is Victor Eijkhout's TeX by Topic, which is available for download.
Working in academia publishing CS/math, you sooner or later find yourself trying to publish in a journal that will only accept .doc/.rtf. This means tedious, boring hours of translating line after line, especially equations, from LaTeX to an inferior format. Over the years I have tried a number of export tools for LaTeX, but none, at least of the free ones, that I have been very satisfied with. I'd like this page to collect and monitor the best import/export tools for LaTeX, to .doc/.rtf, or to other useful (e.g. HTML, MATHML) formats.
Thus, what is your one favorite import or export LaTeX tool?
AFAIK there isn't really a convenient and effective way to achieve what you're trying to do. What I usually do in those rare occasions is that I export to pdf, then select all the text, and paste into word. It's horrible and messes things up and of course doesn't adjust your citations.
To this day I don't understand how people writing in scientific fields can write and publish in Word. It is common in some human-computer interaction literature but I have not seen it in other conferences and journals. May I ask which one it is?
Also, some places, once you've already been accepted, will be willing to accept a PDF if you push it with them. You may have to make little adjustment yourself. Negotiations sometimes work on this.
The UK TeX FAQ has been collecting answers on this for quite some time now. :)
See Conversion from (La)TeX to HTML and Other conversions to and from (La)TeX. There is another FAQ specifically about Converters between LaTeX and PC Textprocessors maintained by Wilfried Hennings.
For LaTeX to HTML there are LaTeX2HTML, TtH, Tex4ht, TeXpider and Hevea; in my experience TeX4ht is the best. For LaTeX to Word, you can go through RTF with TeX2RTF (not so good), or through Adobe Acrobat which can produce PDF that Word can read (not good either), or go through HTML as above, but best is to use tex4ht which can generate OpenOffice ODT format, from which conversion to Word is easy.
The UK TeX FAQ also has many other useful things; you should take a look.