Not signed in (Sign In)

Not signed in

Want to take part in these discussions? Sign in if you have an account, or apply for one below

  • Sign in using OpenID

Site Tag Cloud

2-category 2-category-theory abelian-categories adjoint algebra algebraic algebraic-geometry algebraic-topology analysis analytic-geometry arithmetic arithmetic-geometry book bundles calculus categorical categories category category-theory chern-weil-theory cohesion cohesive-homotopy-type-theory cohomology colimits combinatorics comma complex complex-geometry computable-mathematics computer-science constructive cosmology deformation-theory descent diagrams differential differential-cohomology differential-equations differential-geometry digraphs duality elliptic-cohomology enriched fibration finite foundation foundations functional-analysis functor gauge-theory gebra geometric-quantization geometry graph graphs gravity grothendieck group group-theory harmonic-analysis higher higher-algebra higher-category-theory higher-differential-geometry higher-geometry higher-lie-theory higher-topos-theory homological homological-algebra homotopy homotopy-theory homotopy-type-theory index-theory integration integration-theory k-theory lie-theory limits linear linear-algebra locale localization logic mathematics measure-theory modal modal-logic model model-category-theory monad monads monoidal monoidal-category-theory morphism motives motivic-cohomology nlab noncommutative noncommutative-geometry number-theory of operads operator operator-algebra order-theory pages pasting philosophy physics pro-object probability probability-theory quantization quantum quantum-field quantum-field-theory quantum-mechanics quantum-physics quantum-theory question representation representation-theory riemannian-geometry scheme schemes set set-theory sheaf simplicial space spin-geometry stable-homotopy-theory stack string string-theory superalgebra supergeometry svg symplectic-geometry synthetic-differential-geometry terminology theory topology topos topos-theory tqft type type-theory universal variational-calculus

Vanilla 1.1.10 is a product of Lussumo. More Information: Documentation, Community Support.

Welcome to nForum
If you want to take part in these discussions either sign in now (if you have an account), apply for one now (if you don't).
    • CommentRowNumber1.
    • CommentAuthorRichard Williamson
    • CommentTimeAug 12th 2018
    • (edited Aug 12th 2018)

    I am making some tentative, experimental steps towards a new tex parser for the nLab, which will parse tex directly to HTML. MathJax does this, but I am not really happy with using it server-side, and in addition, as we have noted previously, we would probably need to tweak it to make it compatible with Itex2MML.

    So far, I have used it only on the page set theory. If you usually use Firefox, where MathML was being rendered directly by the browser, you should not see an enormous difference from before. If you use any other browser, it should look a little different, because I am rendering the fonts using simply italicised normal fonts, and using a unicode symbol for the \mathcal as on this Wikipedia page.

    Now, my question: does the calligraphic P look OK? If not, please suggest a different unicode symbol! I am convinced that using unicode symbols is the way forward. The symbol is slightly different from that which Firefox uses, but I have not succeeded in finding the latter yet.

    • CommentRowNumber2.
    • CommentAuthorRichard Williamson
    • CommentTimeAug 12th 2018
    • (edited Aug 12th 2018)

    Hmm, actually I think it might be a question of which font is chosen. On my mobile phone, I get a rather ornate calligraphic P, whereas on my computer I get a relatively simple one, and neither is the same as Firefox uses on my computer for rendering MathML, even though I think the same symbol is present in the MathML source.

    I am tempted then to think that it is fine as it is, unless people think we should change font for the mathematics rendering.

    • CommentRowNumber3.
    • CommentAuthorDavid_Corfield
    • CommentTimeAug 13th 2018

    With a Chromebook the symbols appear as squares.

    • CommentRowNumber4.
    • CommentAuthorRichard Williamson
    • CommentTimeAug 13th 2018
    • (edited Aug 13th 2018)

    Interesting, thanks very much. That is in Chrome, presumably? Do you have Firefox on that machine? If so, does the curly P at power set render in Firefox?

    • CommentRowNumber5.
    • CommentAuthorDavid_Corfield
    • CommentTimeAug 13th 2018

    Yes, it’s Chrome. And no, one can’t have other OSes.

  1. Thanks! Hopefully this might be able to be solved by specifying a font-family to be used that the ChromeBook does have, and which can render mathematical characters. Not ideal, but I can’t think of any other option for the moment. I’d rather avoid embedding fonts. Will experiment when I get the chance.

    I will also be writing a parser which will export MathML, and so we could just keep MathJax on and output the same/similar MathML as Itex2MML; but I’d really like the HTML rendering to be done server-side, as this will improve the user experience greatly. It’d be a shame to have to use MathJax everywhere for the sake of a few relative corner cases. I’m sure we can come up with something.

    • CommentRowNumber7.
    • CommentAuthorRichard Williamson
    • CommentTimeAug 14th 2018
    • (edited Aug 14th 2018)

    Hi David, I’ve now embedded the STIX math fonts, so hopefully you should now see the power set symbol? I’m using the embedded fonts as a last resort; first it checks for DejaVu Math TeX Gyre, which seems to render quite nicely without affecting spacing much, then it looks for any serif font on your local machine which renders it; and then it uses the embedded font.

    I think that most Linux users with an up to date system may have DejaVu Math Tex Gyre on their local system. On my machine DejaVu Sans is used as the font for rendering the surrounding text, and the Math font seems to harmonise well with it. If people are using some other font for the main text, things may not look too good!

    The Stix fonts render fine but affect the spacing on my machine, no doubt because they are a different font to the surrounding text. I’ll not fix that for the moment, but will come back to it. The main thing is that the page is readable and the symbols recognisable.

    Feedback will be greatly appreciated from as many as possible, as if I do not hear anything I will move on!

    • CommentRowNumber8.
    • CommentAuthorMike Shulman
    • CommentTimeAug 14th 2018

    Remind me what is wrong with using mathjax server-side?

  2. It’s up for debate whether it is wrong, I am open to changing my mind!

    The following things are in my mind:

    1) There are some incompatibilites between MathJax and Itex2MML. The latest one cropped up in #2 here, where MathJax cannot render what Urs is trying to do. I do not think it would be a good idea to try to modify the MathJax source.

    2) MathJax is written in Javascript, and with client side in mind. Javascript can perfectly well be used nowadays as a server side language, but has limitations, say if we really wish to make the rendering as fast as possible. I would prefer something that is designed to be server side, and which either is very fast or could be optimised to be very fast.

    3) MathJax does not have great support for diagrams, which are a quite fundamental part of the nLab.

    4) MathJax is large and complex. I would prefer something that is as simple and lightweight as possible, even if it means sacrificing some functionality.

    5) I am not quite sure whether MathJax works well with HTML output (which is the best quality, and what you probably see in your browser) when run server side, because I think it determines font sizes, etc, from the surrounding text. It might be that everything is actually fine on this particular point, I have not tested it in detail.

    Maybe there are other arguments as well, but those are the ones which come to mind at the moment. In general, I think there is really room for a new server side renderer of mathematics directly to HTML (as well as to MathML, but I do not see the need to actually output MathML when it comes to a web page, which after all is about presentation; I see its value only in semantics, and I am not aware of any search engine, for instance, making significant use of these semantics at the moment). Of course, it is a significant undertaking and it may not be feasible in the end, but I thought we could try it out. Somehow I feel that presenting mathematics in HTML in the majority of cases should not really be all that difficult, as long as one does not expect perfection, and accepts that complex cases will be out of reach.

    The idea would be to fallback to MathJax if a page cannot be rendered by the home-grown parser.

    But we could certainly try MathJax server side if people would prefer that, just let me know.

  3. I have by the way used the new tex renderer at foundation of mathematics as well now. A few LaTeX symbols (\kappa, \times, and a couple of arrows) are used at this page.

    • CommentRowNumber11.
    • CommentAuthorRichard Williamson
    • CommentTimeAug 14th 2018
    • (edited Aug 14th 2018)

    One of my first impressions is that these pages look much better than before on a mobile (Android). Maybe not the most important consideration, but not completely inconsequential either. I think it is because the Android browser was trying to render the MathML directly, so this is not an argument against MathJax (if MathJax were used to produce HTML directly server side rather than MathML).

    • CommentRowNumber12.
    • CommentAuthorRichard Williamson
    • CommentTimeAug 14th 2018
    • (edited Aug 14th 2018)

    On a computer, I am not yet sure. With DejaVu Sans as main font and DejaVu Math TeX Gyre as math font, things look OK to me; not perfect, but neither is MathJax, which produces rather large mathematics text which does not fully harmonise with the rest, nor MathML rendered in Firefox. I would be very interested to hear how things look in other fonts.

    • CommentRowNumber13.
    • CommentAuthorMike Shulman
    • CommentTimeAug 15th 2018

    Those are reasonable arguments.

    I don’t have time right now to do a lot of testing of how things look, unfortunately, but maybe others can.

  4. No problem, just let me know if you see something that looks terrible.

    I tested just now on Windows, and things look very good there, actually slightly better than on Linux at the moment I would say. I also noticed a slight positive that Google seems to be able to nicely display the mathematics if one searches for ’set theory’, say.

    I’d be interested to hear from you again, David, when you get the chance to take a look at the above two pages on a ChromeBook. It might be better to embed DejaVu rather than Stix, but things should at least render now.

    I’d also be very interested how things look if anyone has a Mac or an iPhone.