Show HN: Mathcha – Online Mathematics Editor


358 points | by buiducnha 342 days ago


  • jordigh 342 days ago

    Nothing here attracts me away from pure LaTeX that much except two things: (1) built-in symbol recognition (I still rely on but it's rare for me to have to look something up) and (2) auto-resizing delimiters.

    Can any TeX experts explain to me why delimiters don't resize by default? Why do we need to insert so many \left and \right commands?

    • jimhefferon 342 days ago

      Not a typesetting expert but to my eye the auto-sized delimiters are bad more often than they are good. The people that I look to for expert advice on this seem to me to agree. I'll mention and but more googling will get you more opinions. :-)

      Edit: Here is what Knuth says (p 148 in my copy)

      At this point you are probably wondering why you should bother learning about |\bigl| and |\bigr| and their relatives, when |\left| and |\right| are there to calculate sizes for you automatically. Well, it's true that |\left| and |\right| are quite handy, but there are at least three situations in which you will want to use your own wisdom when selecting the proper delimiter size: \ (1)~Sometimes |\left| and |\right| choose a smaller delimiter than you want. For example, we used |\bigl| and |\bigr| to produce $\bigl\vert\vert x\vert- \vert y\vert\bigr\vert$ in one of the previous illustrations; |\left| and |\right| don't make things any bigger than necessary, so `|$\left|\||\left|\||x\right|\||-\left|\||y\right|\||\right|\||$|' yields only `$\left\vert \left\vert x\right\vert -\left\vert y\right\vert \right\vert$'. \ (2)~Sometimes |\left| and |\right| choose a larger delimiter than you want. This happens most frequently when they enclose a large operator in a display; for example, compare the following two formulas: \beginlongdisplaymathdemo \noalign{\vskip 6pt} |$$\left( \sum_{k=1}^n A_k \right)$$|&\left( \sum_{k=1}^n A_k \right)\cr \noalign{\vskip 3pt} |$$\biggl( \sum_{k=1}^n A_k \biggr)$$|&\biggl( \sum_{k=1}^n A_k \biggr)\cr \endmathdemo The rules of\/ |\left| and |\right| cause them to enclose the ^|\sum| together with its ^{limits}, but in special cases like this it looks better to let the limits hang out a~bit; |\bigg| delimiters are better here. \ (3)~Sometimes you need to break a huge displayed formula into two or more separate lines, and you want to make sure that its opening and closing delimiters have the same size; but you can't use |\left| on the first line and |\right| on the last, since |\left| and |\right| must occur in pairs. The solution is to use |\Biggl| (say) on the first line and |\Biggr| on the last.

      • repsak 342 days ago

        Check out the nath package

        ... de­lim­iters adapt their size to the ma­te­rial en­closed, ren­der­ing \left and \right al­most ob­so­lete.

        • beagle3 342 days ago

          I am not an expert, but my impression was always that the way it is makes things general, orthogonal, and easy to explain and reason about (if cumbersome to use).

          If \left and \right were automatic, then whenever you needed something less-but-often-still common, like [0,1) open intervals, or physics <bra|ket> notation, that would require kludges.

          Whether or not it is a smart decision is a different argument.

          • ves 342 days ago

            Why not make auto-sizing the default and manual size control the exceptional case? It's already like this "in reality," I just wish the language would follow that.

            I use templates so my editor shims in the above anyway, at the cost of lots of noise.

        • yorwba 342 days ago

          This looks really good, but you might want to hire a copy-editor in the future:

          Most ~~of~~ symbols are the same in \inline-math and \math-container, but there are ~~one~difference~~ some differences , these symbols below will be displayed in smaller fonts

          Additionally, when I copy-pasted this here from your document, it included a bunch of metadata you probably don't want to expose to users. I think there is a way to set different clipboard contents for different MIME types, maybe look into that.

          • buiducnha 342 days ago

            With Inline Math (\inline-math), there are some symbols will be displayed smaller (by default) than Display Mode (math-container). This is because I implement it to be the same with LATEX style, maybe most of people dont want that behavior, so may possibly change in future.

            Good advice on MIME types, thanks.

            • andrewjw 341 days ago

              The comment above with ~~~ was trying to give you grammar help, not content help.

          • edanm 342 days ago

            This is really awesome, I'm going to be trying it out over the next few days. I'm by no means a Latex expert, but it seems like it could make writing Latex a bit faster and more wysiwyig-ish.

            One question - if I want to write a^(b+c), I'll normally write in latex: a^{b+c} to group the b+c as part of the power. I can't figure out how to do the same in the editor - if I write in a^b+c, anything after the "b" will go back down and will no longer be superscripted.

            • dorfsmay 342 days ago

              Have you used LyX?


              • edanm 342 days ago

                No, but this has inspired me to check it out. I only started used Latex recently.

              • buiducnha 342 days ago

                Hi, that's intentional, because we see that most of the time superscript input is only one character, you can press arrow left to go back and input more characters.

                Maybe in future I should have a setting to turn off that feature/behavior.


                • edanm 342 days ago

                  OK I feel a bit silly because I didn't realize you could just press left and go back to editing it. It's not even unintuitive, this is exactly the behavior of e.g. grapher, which I use all the time, I really have no excuse.

                  • tuananh 342 days ago


                    it looks like a very polished product. congrats on releasing.

                  • Tade0 342 days ago

                    Type \power.

                  • Kagerjay 342 days ago

                    That was one seriously impressive 3 min video. Explained everything you wanted to know about the platform without any audio needed either

                    Im going to definitely try this out later

                    • johndough 342 days ago

                      This seems to be broken for keyboards without QWERTY layout (about half of Europe) because math mode can not be entered with the '\'-key.

                      • buiducnha 342 days ago

                        Thanks for feedback, did not aware of different type of keyboard layouts!

                        • sharigram 342 days ago

                          I'm using international QWERTY and can't use it either.

                      • dbranes 342 days ago

                        The diagramming tools look promising, great work!

                        I never felt like I needed a WYSIWYG for Latex. But I deifnitely need a WYSIWYG for tikz[0]. For example, the tikz code for a simple diagram [1] is essentially incomprehensible. So in light of this:

                        1. I'm having trouble finding an image (especially vector format) export feature, do you have it?

                        2. Feature request: export diagrams to tikz code.



                        • IshKebab 342 days ago

                          > I deifnitely need a WYSIWYG for tikz

                          I just use IPE. It's a nice GUI diagram editor that can save as PDF (as in, the PDF contains the IPE data). Far better than faffing around with tikz.


                          • buiducnha 342 days ago

                            1. You can export diagram as Image (PNG), by selecting Diagram itself (not item in Diagram), and click "Save as Image" on toolbar (resolution will be doubled as normal). There is no Vector Format Export.

                            2. Will have a look at TikZ format


                            • jimhefferon 342 days ago

                              > 2. Feature request: export diagrams to tikz code.

                              Just in case you are unaware, there are many GUI's that export to TikZ. See and for instance.

                            • kevinb7 342 days ago

                              Nice work. The drawing recognition feature seemed to work well. One little thing that could be improve is enforcing a minimum font size so that deeply nested fractions don't become unreadably small.

                            • jxy 342 days ago

                              Looks nice. Would there be a native version, for which data are only stored locally? You would certainly have some professional market with that. I would pay for it just to replace LaTeXiT.

                              • ttd 342 days ago

                                I recently released Vexlio (, a desktop (i.e. non-browser) diagramming application, that supports editing of embedded LaTeX equations which you can then easily export to PDF, SVG or PNG. Currently Windows only, but Mac is coming very soon now.

                                • vram22 342 days ago

                                  Interesting. If not confidential, what language did you use to create Vexlio? and what library (if any) for PDF and PNG output? Asking since PDF generation is one of my interests.

                                  • ttd 341 days ago

                                    Not confidential -- Vexlio's written in C#, and uses Xamarin.Mac for the bindings to the Mac world. PDF and PNG are both generated by the Skia library (

                                    • vram22 341 days ago

                                      Thanks, had not heard of Skia. Will check it.

                              • kerneldeveloper 342 days ago

                                There is also a tool which can convert Latex equations into images:

                                • Hengjie 342 days ago

                                  You guys really need to compete against Wiris in the K12 Education space. If you ever want to see this introduced to the US edu market, ping me a line.

                                • rmbeard 342 days ago

                                  This looks really good. The main application I would have for this is online teaching, where previously I would have used WolframAlpha, so while this does not have computational functionality it looks like it might be superior as a communication tool. The one thing I would like to see is support for mobile devices.

                                  • gabrielgoh 342 days ago

                                    to those who are looking for a WYSIWYG editor which supports latex, try LyX. It's good and intuitive enough that I have used it as a tool for thought, and prefer to work straight from latex rather than a whiteboard or a paper and pen.

                                    • jgtrosh 342 days ago

                                      Haven't used it in a while, but I think this public should also take a look at TeXmacs. I've long stopped caring about anything WYSIWYG but that software seemed to me to strike a very well designed balance between WYSIWYG/fast-input (though with a steeper learning curve than M$Word, but very approachable) and showing what's under the hood.

                                      • kipari 342 days ago

                                        Are you able to give a quick overview of some of the differences between TeXmacs and LyX. As a longtime LyX user, the two applications look very much alike.

                                        • LolWolf 342 days ago

                                          +1 for TeXmacs, though it seems development hasn't really continued which is a shame really: it's pretty fantastic software.

                                      • ChuckMcM 342 days ago

                                        It would be awesome to add this to tydig. (iPad calculation application) I really wish I had something like my Ti92 wide body on the iPad with an editor that was this easy to use.

                                        • samcat116 342 days ago

                                          Seems very similar to Swift Calcs -

                                          • lousken 340 days ago

                                            Definitely adding this to my favourites, but I wonder if you could export those diagrams to latex using tikz?

                                            • michaelmior 341 days ago

                                              > a fast way to write and share mathematics formula

                                              This should probably read "share mathematical formulas"

                                              Looks pretty cool though :)

                                              • buiducnha 341 days ago

                                                Thanks, sorry for that bad English :)

                                              • be5invis 342 days ago

                                                I guess you (or your company) does not have any Windows PC.

                                                • thamtudethuong 342 days ago

                                                  Yes, what is the problems with Windows PC?

                                                  • be5invis 341 days ago

                                                    The website works well in Edge but you claimed that it does not support that. I have to override the user agent in order to access your editor.

                                                    • buiducnha 341 days ago

                                                      The reason is we did not test carefully on Edge, may have some problems we don't know!

                                                • lauretas 342 days ago


                                                  • buiducnha 342 days ago

                                                    It's free to use, currently there is a limit of 50 documents (to avoid people create unlimited documents), will increase that limit.

                                                    • bryanph_ 342 days ago

                                                      Have you considered open sourcing and selling commercial licenses for integration? I think this is a product that many corporations would love to integrate with. However, as an alone standing product I don't think it adds a lot of value. Something like the business model of

                                                      • buiducnha 342 days ago

                                                        Very good point, did think about that, but until now still not very sure about business model. At the beginning, when we build it, we want to have a editor for people to easily type and share their Math (even without knowing LATEX). Will definitely consider/think about Integration, or somethings else ...


                                                  • kensai 342 days ago

                                                    Sometimes the HN algorithm baffles me. This article has already be submitted by the same person, a couple of days ago. I even asked a question there.

                                                    How is it that the comments there are not included here, given the same link? Or is it not the same link?!


                                                    • buiducnha 342 days ago

                                                      Hi, I submitted again because at that time I did not know and did not post with Prefix "Show HN:". Maybe that's reason?

                                                      • kensai 342 days ago

                                                        If the link was the same, shouldn't you get a warning that this was already submitted? If I submit something that has already been submitted, HN automatically give a point to the previous submission.

                                                        Which is the way I expect it to work to avoid double submission and parallel discussions. The thing is: I have not quite understood why sometimes it works and others not.

                                                        • scribu 342 days ago

                                                          Submitting an identical link starts working after a few days since the previous submission.

                                                          • kensai 341 days ago

                                                            Is there a technical reason for this?

                                                    • 342 days ago