Jump to content

Help talk:Displaying a formula/Archive 1

Page contents not supported in other languages.
From Wikipedia, the free encyclopedia
This is an old revision of this page, as edited by Rich Farmbrough (talk | contribs) at 01:18, 13 July 2011 (Subst "Unsigned IP" and minor fixes using AWB). The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.
Archive 1Archive 2Archive 3

A new way to view formulas in browsers

Please, attention! If you are interesting to finish develop.

What is it a page?
– It is a page of project overview.
What is the project name?
– Formulas for us.
Who is an author of the project?
– Dmitry Zotov.
What is a purpose of the project?
– To develop a comfortable method for the visualization of different sort of formulas in the Internet browsers.
What stage is the project on?
– An effective solution was found and some features of other technologies used by him are tested.
What technologies is it possible to realize the prepared decision by?
– Java, JavaScript, MathML, CML, TeX, DOM, CSS, HTML, XML.
How does the decision provide for to use Java technology?
– As an applet. He demonstrates a formula.
If not to accent attention at internal work of applet, what information is he exchanged with other components of decision?
– He gets such information: size and color of font, character of background, style of reflections of formulas, language on which a formula and record of formula was written down in this language. He gives information about the sizes of the image of formula and displacement in relation to the baseline of line that he is inserted on.
What part in the decision does act by technology of JavaScript?
– She co-operates with technology of Java and Internet browser.
What concrete mechanisms can an exchange of information between the components of decision?
– The applet of Java can get information the call of the methods from JavaScript scenario, passing of parameters at an insertion in HTML, and by a local or remote file, the address of which can be passed of one of the first two methods. To return information he can by the object returned from a method. Passing to information of JavaScript to the Internet browser can take place by the known DOM technology.
How can there be a process of reflection of formula in the browser of the Internet?
– An user creates HTML document, containing the necessary JavaScript scenario. Inserts a necessary applet in this document. Adjusts him statically by parameters and additional files (including passes a line with the name of the language of record of formulas used by him and record of formula in this language). After, it is needed to start this document in the browser of the Internet. After the start, Java applet will reveal to JavaScript the scenario parameters of the dynamic tuning of insertion itself in a document, and JavaScript will execute this tuning by DOM/CSS. It will allow a formula correctly enough represented in a document. The JavaScript scenario can watch the changes of sizes and colors of font, character of background, scale and to retune a formula dynamically.
Will there be a project to develop farther?
– Yes.
What is it assumed to do in the near time?
– Trial page that evidently will show co-operation of technologies for the reflection of formulas in the browsers of the Internet.
Is there a reflection of formulas in the browsers of the Internet a problem?
– I ran into it. In the Internet also there is a lot of forums, where both this problem and possible decisions come into question. However, effective decision I did not find there. In one well-known Internet encyclopedia the pictures of formulas, created "on the fly, are used". However, their sizes and colors is impossible to change.
Is there a necessity in the use of browsers of the Internet for the reflection of formulas? Possibly, do the specialized programs befit for this purpose?
– Technologies, related to the Internet, have large distribution and formulas, represented on their base, do not require additional software. It befits for such genre of sites as scientific publications. In addition, Internet browsers are constantly perfected and, learning to work with them, users get comfortable access to the most various information. Including, before long, and to the comfortably represented formulas.
Are you going to do the variant of this idea prepared for the use with support of even one language or his subset?
– Possibly. However, as an acceptable enough decision is already found, I count on a help other people that can do its concrete realization.
Are there some stages developments that would require specific skills?
– Yes. One stage is related to the translation of record of formula in the working structure of formula. And other stage which is related to the correct reflection of this structure. However much it seems to me that the carefully thought out system of classes can considerably simplify motion of work. It is similarly needed to create the formats of styles of reflection of formulas (XML), those users could change on their taste.
Is it possible with you to associate for consultations, wishes, questions or additions?
– Yes. By e-mail. Address is sharp-witted@rambler.ru.
The above is out of context and references. Is it spam? I have an idea about a WP project on wikipedia based interactive calculation, plotting, animation and simulation. Is that what the above is about? I suggest that the section should be removed or archived. Mange01 14:51, 20 June 2007 (UTC)
Where are more information about your idea? And what a date of implementation? To user Mange01. —Preceding unsigned comment added by 82.207.99.2 (talk) 15:22, 28 April 2008 (UTC)

Why so large formulas?

Why is the default font size of the formulas much larger than the text? This is a problem especially in inline formulas. What can I do to overcome this problem? I have to choose a very large text size in my browser to make it harmonize with the formulas, but that should not be the way to go. I suggest that the default templates / .CSS files should be revised for smaller formula size. Mange01 15:03, 20 June 2007 (UTC)

On the other hand if the user wants to zoom in to a PNG formula — perhaps because they have poor eyesight and can't read some sub-subscripts — ...they cannot!
—DIV (128.250.80.15 (talk) 07:48, 5 December 2007 (UTC))

I set up a local wiki server with texvc, and I really want to have an option to change the default settings. Can I? Thanks. --Lanyijie 09:16, 15 May 2008 (UTC)

Suggestion: Wiki based interactive math

I have a vision of a wiki project on interactive web based math. From wikipedia articles, the user should find interactive free tools for web based calculation, visulization, simulation, modelling and symbolic math. A commercial software such as Maple, Matlab and MathCAD should not be required for running computer simulations.

Where is the appropriate place to discuss this? Viewpoints on the basic idea?

Application examples that I have in mind:

  • Web based unit conversion: When reading an article about for example Celcius, the user should be able to access a tool where he can enter a temperature in a field or using a slide control, and convert it between Fahrenheit, Kelvin, Celcius and Rankine.
  • Web based formula calculation: When reading any wikipedia article about a math formula, the user should be able to enter numerical values of the parameters and get numerical results. Sometimes a certain interactive tool page may be designed for the formula, where controls such as text boxes, radio buttons, slide bars, etc, can be found. There should also be a generic way to calculate any formula found in wikipedia, for example by accessing a tool from the background menu, or by copying the formula into some kind of mathematical sandbox or private notebook web page.
  • Web based interactive plots: In plots, the user should be able to elaborate with different parameter values and generate new plots.
  • Web based animation: Models of dynamic processes may be visualized by means of plots with an aditional time dimension, i.e. by animations. Examples are math formulas with a time dimension, but also electrical circuits, physical phenomena, etc. The animations may resemble Flash animations, and be two or three dimensional.
  • Web based stochastic simulation: It should be possible to visualize the behaviour of models of stochastic processes, for example queuing theory applications such as computer networks, that change their behaviour on a time-to-time scale.
  • Web based algorithm simulation: It should be possible to run algorithms documentet by flow charts, signal flow charts, or mathematical style pseudo code, in view to test it for certain values, and to visualize the behaviour.
  • Web-based component-based graphical programming and modelling: Users should be able to build complex system models by linking and interconnecting various wiki objects, for example math formulas, algorithms, scripts, lock-up tables, software components, electrical circuit models, plots, and interactive controls into their own wiki documents. Each entity may be graphically represented by a block in a flow chart, state-flow diagram, signal/data flow diagram, UML diagram, etc, and the user may copy and paste such blocks between models. AJAX style web service for web based graphical editing may be an option. In some cases, a commercial tool may be required to design a block, but not to utilize it in a model. The model may be published on a wiki server, publically or on a private note page. It may also be saved and run locally using some freeware software. This idea resembles the old mathCad/MathConnex commercial software, where OLE linking and embedding was used to interconnect various math blocks, for example mathcad formulas and pseudo code scripts, matlab functions, Excel scheats, spice models of electrial circuits, etc.
  • Web based simulation of dynamic systems. Similar to Simulink models.
  • Web based symbolic math: The user should be able to elaborate algebraically with formulas in for example wikipedia. See for example MathCAD.
  • Web based audio and video processing: The user should be able to apply various algorithms on his own recorded sound, video and documents.

The calculations should normally be carried out at the client side, to relieve the wiki web server from load. However, in some cases it might be interesting that the server generates a "cashed" version of a plot or an animation, for some common parameter cases.

In computer simulation, distributed computing is important, and sometimes we want to distribute the model over different machines. Different blocks and/oror different parameter cases, may be simulated on different machines. The distributed computing may be carried out by a local computer cluster, or by a worldwide peer-to-peer network of users sharing each others capacity. A web based user interface for controlling the distributed computing is also a vision.

To achieve efficient computer simulation, there should be means of controlling cashing, look-up tables, etc. Only changed values should be recalculated, as in a spread-sheet document or in MathCAD.

Related wiki topics:

Mange01 18:06, 20 June 2007 (UTC)

Recommend \displaystyle instead of \,?

Wouldn‘t it be easier to recommend \displaystyle if one wanted a formula to be rendered as png? The word has a meaning that is easy to remember, easier than the \, trick with a comment. Or don’t they have the same effect? H. (talk) 11:41, 12 August 2007 (UTC)

Please add
Wikipedia:How_to_write_a_Wikipedia_article_on_Mathematics#Typesetting_of_mathematical_formulas
Wikipedia:Mathematical_symbols
as "See also" links to this article. Just an easy guide for those looking for help without crawling through paragraphs of stuff. Brews ohare (talk) 19:45, 29 November 2007 (UTC)

Non-italic text

The guide suggests either \mathrm{·} or \mbox{·} for rendering "text" non-italic (i.e. 'roman'). There are three serious problems:

  • \mathrm{·} will not operate on e.g. Greek letters!
compare and
(expected θ and θ)
  • nowhere is it made clear that \mbox{·} is simply a way of including 'verbatim' text, so that tokens signifying e.g. Greek letters (say, \theta) will not be parsed correctly (or in fact at all — wierd!!)
compare and Failed to parse (syntax error): {\displaystyle \,\!\mbox{\theta}}
(expected θ for both)
  • generally \mathrm{·} is preferable for rendering text like "max" as a subscript, because \mbox{·} doesn't shrink the text ...it displays the argument exactly as entered:
compare and
(expected tmax for both)
Given this it seems \mathrm{·} should always be preferred to \mbox{·}!?

—DIV (128.250.80.15 (talk) 08:01, 5 December 2007 (UTC)) Amended —DIV (128.250.80.15 (talk) 08:04, 5 December 2007 (UTC))

Italic variables

It is not apparent how to force uppercase Greek letters to render in italics. For example:

compare and
(expected Γ and Γ)

Note: a good reference for italicising formulæ is:
I. M. MILLS and W. V. METANOMSKI; On the use of italic and roman fonts for symbols in scientific text; IUPAC Interdivisional Committee on Nomenclature and Symbols; December 1999. (Accessed from http://www.iupac.org/standing/idcns/italic-roman_dec99.pdf, 2003–05–08.)

—DIV (128.250.80.15 (talk) 08:10, 5 December 2007 (UTC))

Hmm, no one seems to come here very often. If your still after an answer try <math>\,\!\mathit{\Gamma}</math> which will give you this; . SpinningSpark 18:52, 26 April 2008 (UTC)

Adding symbols to TeX

How does one go about adding symbols or commands to TeX? For instance, there is a section here in "Displaying a formula" for "Unsorted new stuff". How does one create "new stuff"——If it has to be approved, where does one submit it?  ~Kaimbridge~00:19, 12 December 2007 (UTC)

Numbered Equations?

Is there a way to number automatically equations in Wikipedia? Thanks--Geremia (talk) 06:41, 19 January 2008 (UTC)

Font used

Hi all, I have been curious about exactly which font is rendered into these pngs? I have acquired the font, "cmr10": Computer Modern Roman font, but it doesn't seem to match up. Any idea what the actual font is? Or better yet, link to a ttf? ॐ नमःशिवाय Śaiva Sujīt सुजीत ॐ 08:05, 25 February 2008 (UTC)

Hi, you already tried cmmi*? Computer Modern Math Italic? --Georg-Johann (talk) 14:42, 15 April 2008 (UTC)

Omicrons are missing from Greek alphabet

/omicron and /Omicron are not recognised. Why? Is this a bug? SpinningSpark 18:54, 26 April 2008 (UTC)

That's probably because Greek 'omicron', both lower and uppercase, are identical glyphs to Latin 'o'. See the Short Math Guide for LaTeX ftp://ftp.ams.org/pub/tex/doc/amsmath/short-math-guide.pdf par.3.4 page 5. --CiaPan (talk) 05:59, 13 June 2008 (UTC)

Hence

I was wondering if there a tag for a mathematical "therefore"? (I.e. the equivalent to the HTML "∴" tag: ∴) I didn't see it documented.—RJH (talk) 19:33, 12 May 2008 (UTC)

It is just \therefore, . JackSchmidt (talk) 19:39, 12 May 2008 (UTC)

I have Mediawiki installed. I want to display \gamma with a mouseover text description of :gamma. It fails and the culprit is "|" . Is there a solution to this? I don't want to manually update the page ( one of many under wikipedia dump). Please let me know if i am missing a mathml package. Thanks

[[gamma|<math>\gamma</math>]] - doesn't work but i want this to work as is. any thoughts?

[[<math>\gamma</math>]] - works fine — Preceding unsigned comment added by 131.107.0.73 (talk) 2008-05-13T21:56:24Z

On my mediawiki installation with texvc installed, it works just fine. On wikipedia it works just fine. If you need help with mediawiki software, you probably want to check out mw:Project:Help, or more specifically mw:Manual:Math for the texvc help. JackSchmidt (talk) 22:08, 13 May 2008 (UTC)

TeX Reference Card - Restricted Access

There is a reference on the bottom of the page for a reference card of TeX, offered under the URL "http://www.csit.fsu.edu/docs/tex/tex-refcard-letter.pdf". I can't get to the page because it says I do not have permission to. I'm not sure if the port is blocked by my personal firewall, or it the file has been restricted of public access. I hesitate to change the link to the Internet Archive link here because of this doubt. Is anybody having the same restricted access problem? Un Piton (talk) 14:52, 15 May 2008 (UTC)

I got it too. The error is coming from the server so I don't think it would be a personal firewall problem. SpinningSpark 20:50, 15 May 2008 (UTC)

Changing font size in Wikipedia

Hi! I noticed that Wikipedia isn't able to change font size in latex. For example code \tiny \frac{355}{113} results an error message, not tinier font size. And when I tried my code in a latex generator it produces just fine tinier font size. Is there any reason why changing font size is not allowed in Wikipedia? --QWerk (talk) 10:34, 12 June 2008 (UTC)

Only a small part of LaTeX is implemented on Wikipedia - just enough for the purposes of doing formulae. But for the example you quote \tfrac{355}{113} should work and renders as;
as opposed to for \frac{355}{113}
SpinningSpark 11:51, 12 June 2008 (UTC)
OK. Thanks for the advice. --QWerk (talk) 12:15, 12 June 2008 (UTC)
If you think that there is a need for a new feature you can always try suggesting it at Wikimedia Bugzilla. Usually only goes anywhere though if there is lots of people supporting it so discussing first at Wikipedia:Village pump (technical) would be a good idea. SpinningSpark 12:38, 12 June 2008 (UTC)

Dollar sign mania

The page says to most users

 ┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┯━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┯━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
 ┃                                   │                                        │          How it looks rendered           ┃
 ┃              Feature              │                 Syntax                 ├───────────────────┬──────────────────────┨
 ┃                                   │                                        │       HTML        │         PNG          ┃
 ┠───────────────────────────────────┼────────────────────────────────────────┼───────────────────┼──────────────────────┨
 ┃ Superscript                       │ a^2                                    │ a^2               │ a^2 \,\!             ┃
 ┠───────────────────────────────────┼────────────────────────────────────────┼───────────────────┼──────────────────────┨
 ┃ Subscript                         │ a_2                                    │ a[2]              │ a_2 \,\!             ┃
 ┠───────────────────────────────────┼────────────────────────────────────────┼───────────────────┼──────────────────────┨

But if you have a certain preference set this is what you will see

 ┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┯━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┯━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
 ┃                                  │                                       │           How it looks rendered            ┃
 ┃             Feature              │                Syntax                 ├────────────────────┬───────────────────────┨
 ┃                                  │                                       │        HTML        │          PNG          ┃
 ┠──────────────────────────────────┼───────────────────────────────────────┼────────────────────┼───────────────────────┨
 ┃ Superscript                      │ a^2                                   │ $ a^2 $            │ $ a^2 \,\! $          ┃
 ┠──────────────────────────────────┼───────────────────────────────────────┼────────────────────┼───────────────────────┨
 ┃ Subscript                        │ a_2                                   │ $ a_2 $            │ $ a_2 \,\! $          ┃
 ┠──────────────────────────────────┼───────────────────────────────────────┼────────────────────┼───────────────────────┨

As the page is supposed to be showing what different users see, it itself should be a static and not appear different to different users! And those $'s look horrible at least in my text browser. You at least need an extra column to show what "dollar sign victims" see if you don't intend to fix it. Jidanni (talk) 02:40, 17 September 2008 (UTC)

Physics?

For physics, I would like to be able to write

  • bold italic latin symbols,
  • bold italic capital Greek symbols, and
  • bold roman small Greek symbols.

How to do it in Wikimath? Miraceti (talk) 17:29, 18 September 2008 (UTC)

Is MathML ever going to happen?

Really, these renderings in png are terribly fugly! With FF3's release, there is no excuse why the feature should not be made a top priority by the wikimedia devs. --Dragon695 (talk) 20:14, 8 July 2008 (UTC)

I really hope MathML does happen, there is a lot of bugs and errors when you try to do complex function like sigma notation, limits...etc and the characters is somewhat ugly and the fractions is making the entire formula look horrible, in fact it almost deteroriate the entire look of the formula because the fraction is humongously big. Wish some developers can make MathType a lightweight web open source markup. --Ramu50 (talk) 21:02, 21 October 2008 (UTC)

latex vs. html

The template doesn't exist anymore there, does it? LivingShadow (talk) 10:58, 13 October 2008 (UTC)

TeX will display in HTML by default, and only in PNG if the equation is sufficiently complex. Gary King (talk) 19:56, 26 October 2008 (UTC)

Conversion help

Can anyone please help convert Image:Pwi-formula.gif (used in Process Window Index — comment addded by CiaPan (talk)) to Latex? I found it too complicated to try. Thanks in advance. Zithan (talk) 18:49, 6 November 2008 (UTC)

Let's see... something like this?
Or maybe
CiaPan (talk) 14:49, 7 November 2008 (UTC)
The second one looks accurate. Gary King (talk) 17:18, 7 November 2008 (UTC)
Thank you. The second one looks better, but there is a problem. The denominator is divided by 2, not added. The dots on the division sign are two close to view with the naked eye. It's the average, therefore divide by 2. Zithan (talk) 12:48, 8 November 2008 (UTC)
Okay I fixed it in the equation above. Gary King (talk) 20:10, 8 November 2008 (UTC)
Thanks. Zithan (talk) 14:59, 9 November 2008 (UTC)
Quick question: Is it possible to use /2 instead of the traditional division symbol? Zithan (talk) 15:08, 12 November 2008 (UTC)
Just change "\div" to "/". Gary King (talk) 15:16, 12 November 2008 (UTC)
Thank you! :) Zithan (talk) 15:21, 12 November 2008 (UTC)

LaTeX symbols

Hello. I'd like to add an alternative layout for the LaTeX symbols. If you are interested, please visit the discussion page on meta. Thank you very much. Regards, --Julian (talk) 14:43, 13 November 2008 (UTC)

Why doesn't this one work?

What is wrong with this equation? Why doesn't it appear like an equation? (taken from previous version of Bohr equation)

Mikael Häggström (talk) 11:54, 13 November 2008 (UTC)

Use this:

Gary King (talk) 15:13, 13 November 2008 (UTC)

Thanks! Mikael Häggström (talk) 16:17, 13 November 2008 (UTC)
Wrong! That works, if you have chosen 'HTML if very simple or else PNG' in your Preferences page (Math tab). If your setting is 'HTML if possible or else PNG' (as is mine), then '\,' does not always do what you expect — and in this case both formulae, with and without a backslashed comma, are displayed with HTML.
You should better use '\,\!' as explicitly stated in the help page, section Forced PNG rendering. --CiaPan (talk) 07:14, 18 November 2008 (UTC)
Thanks! That really fixed the problem. Mikael Häggström (talk) 06:57, 19 November 2008 (UTC)

Passing in a class to <math>

Is it portable to pass in a class to the <math> tag? I writen a Mediawiki to LaTeX converter and have found that if I generate a formula like this:

<math class=eq>\int x^2 dx</math>

Then the HTML produced with have an image with class tex eq rather than class tex. My converter uses this to distinguish between inline math and math that should be in the equation environment (or displaymath). What I don't know is if this will continue in later versions of MediaWiki. Any ideas? Autopilot (talk) 17:19, 17 November 2008 (UTC)

About TeX

By the way who is responsible for the bug of TeX, is it Bugzilla Wikipedia or is it the TeX markup developers? --Ramu50 (talk) 21:04, 21 October 2008 (UTC)

I think it's TeX, as it's probably just a module that MediaWiki (the software that Wikipedia runs on) uses. Gary King (talk) 19:56, 26 October 2008 (UTC)
And if you have found a bug in TeX, you may have already won a prize in the form of a Knuth reward check. There are only 427 bugs listed after 26 years of use. Autopilot (talk) 17:45, 20 November 2008 (UTC)
You probably didn't find a bug in Tex, but in texvc, which we use here to render it and is not the program Knuth wrote. Much to our frustration. Ryan Reich (talk) 00:06, 14 January 2009 (UTC)

I want to change the instructions for converting LaTeX to SVG. Although the current ones are technically correct, they are excessively complicated, produce very poor results when there are diagonal lines, and anyway require either installing all of inkscape, which is unnecessary if all you want is to convert SVG's, or purchasing the commercial direct-to-SVG plugin for pstoedit, which is unacceptable. If no one objects, I will put in the procedure I discuss (with some attitude) on my user page:

pdflatex file.tex
pdfcrop --clip file.pdf tmp.pdf
pdf2svg tmp.pdf file.svg
(rm tmp.pdf)

The use of pdflatex is of course unnecessary; you could use dvipdfm to convert the output of ordinary latex to a PDF file. Ryan Reich (talk) 00:11, 14 January 2009 (UTC)

Using pstoedit directly is also an option, with GNU libplot to replace the proprietary driver: just replace the pdf2svg line with

pstoedit -f plot-svg -dt -ssp tmp.pdf file.svg

where hopefully your ghostscript program can handle PDFs (of course, this requires some rather opaque options that I do not fully understand). This method produces smaller file sizes but I do not know how either works internally so I cannot say whether it will always be of equal quality. Ryan Reich (talk) 21:07, 14 January 2009 (UTC)

The pstoedit invocation failed to produce an image with some of the pictures now at Cone (category theory), whereas pdf2svg worked, so I don't think I can really recommend pstoedit for anything at this point. Ryan Reich (talk) 04:22, 15 January 2009 (UTC)

Maybe also discuss how to get the math actually working??

Saying that one has to fiddle around in LocalSettings.php isn't clear enough, maybe be so good to mention the actual existence of the variable $wgUseTex in LocalSettings.php, or is that too much??

After putting this $wgUseTex to true, any subsequent errors might be worth mentioning also...

like this one: Failed to parse (Can't write to or create math temp directory) might at least get an indication of a solution. So, how does one resolve this problem?? Even chmodding everything to 777 doesn't work, so there is a directory missing. But again... which directory? Where in this wiki is this information???

The temp directory is the directory specified by the $wgTmpDirectory variable in your LocalSettings.php file —Preceding unsigned comment added by Simsong (talkcontribs) 19:01, 12 October 2007 (UTC)

I suspect that some kind of caching goes on---I got this error because the tmp/math directories as specified in LocalSettings didn't exist. I created and chmoded them, but reloading the test page still showed errors---however, other pages displayed formulas fine. I then 'edited' the page that was giving me trouble: didn't actually change anything but just saved after opening for editing, and the page redisplayed with glorious equations. Please check this and report if it worked for you. —Preceding unsigned comment added by 129.6.123.99 (talk) 12:09, 5 May 2009 (UTC)

Semantics with the aligning in normal flow

The article reads:

an inline expression like should look good.
If you need to align it otherwise, use <font style="vertical-align:-100%;"><math>...</math></font> and play with the vertical-align argument until you get it right; however, how it looks may depend on the browser and the browser settings.

Would it not, in the interest of semantic HTML, make more sense to use <span> instead of <font>? Font tags have long since died off. — metaprimer (talk) 04:18, 17 August 2007 (UTC)

A good example would be something like or Anyway the effect depends on the default font size in the user's browser and the font size in math PNG files, so the offset values are never guaranteed to work well for everybody. CiaPan (talk) 14:42, 5 May 2009 (UTC)

\xleftrightarrow

Is it possible to view an \xleftrightarrow with discriptions above and under the arrows shown here.--benutzer:Roland1952 (talk) 00:43, 21 January 2009 (UTC)

Try this:

       

It's not exactly what you need, but I don't know how to make arrows arbitrary long. --CiaPan (talk) 08:31, 21 January 2009 (UTC)

Transparent Background Rendering

The Rendering section says text is rendered black on white. It would be nice if there was a way to allow a transparent background color or at least a custom background color. For example, if we take a look at Sorting algorithm#List_of_sorting_algorithms we can see it doesn't look nice with a white background. —Preceding unsigned comment added by 70.68.146.60 (talk) 21:52, 13 October 2008 (UTC)

Just the same request here. Transparent pngs or at least backgroud colors for these seem to be possible - please look at [[1]]. If your browser has 'don't print background colors' on, do a print preview - you will see that some pngs have gray background and others are transparent. (Don't worry about the black shadows of the pngs) --Ernsts (talk) 15:54, 7 May 2009 (UTC)

Maxwell Stefen diffusion coefficient

Hello, I'm looking for the symbol vor the Maxwell Stefen diffusion coefficient which is a major D with a slash. In latex mathmode normally writen as \text{\sl\DH} but this is not working in wikipedia. Has someone a workaround for this symbol. Mgloede (talk) 13:40, 1 March 2009 (UTC)

If it's not part of a complicated formula, just write the letter directly: Đ. I don't know how to make it inside <math>…</math>. — Emil J. 12:06, 18 June 2009 (UTC)

Please clarify ...

I have no idea what this means:

  • "To have math rendered, you have to set $wgUseTeX = true; in LocalSettings.php."

Does this mean I need to a adjust a setting in the Wikimedia software I'm running? Or do I adjust this in my browser? Or is it a setting under "preferences" in wikipedia? How the heck do I find this setting? Could you please clarify the sentence on the help page? Agradman demands civility/makes occasional mistakes 06:13, 18 June 2009 (UTC)

It refers to the MediaWiki software. — Emil J. 11:49, 18 June 2009 (UTC)

What's the difference between this page: "http://en.wikipedia.org/wiki/Help:Displaying_a_formula" and this page: "http://meta.wikimedia.org/wiki/Help_talk:Displaying_a_formula"? They are almost identical. Ken6en (talk) 04:34, 13 May 2009 (UTC)

The page here is a copy of the page there on meta, so they are supposed to be identical, except that they are not really kept in sync and therefore diverge. I have no idea what's the rationale for keeping a local copy of the page here. — Emil J. 12:13, 18 June 2009 (UTC)
It's easier to have a page here rather than having to go to meta. I personally find this much more useful than having to travel to another Wikimedia project. —MC10|Sign here! 02:52, 19 June 2009 (UTC)
So, does it mean that you volunteer to keep the pages synchronized? — Emil J. 15:17, 22 June 2009 (UTC)

help a novice? ...

I'd like to make this equation look a bit prettier:

However I was told at Wikipedia:Help Desk that it's not possible to put wikilinks into TeX. Is there any other way to make this equation look less ugly? ThanX, Agradman appreciates civility/makes occasional mistakes 00:58, 20 June 2009 (UTC)


You might use HTML to get a proper layout with a table. For example:


  <table align="center" style="text-align:center;">
      <tr>
      <td> Payables period =         </td>
      <td> Avg.Acc.P  <hr>  [ .... ] </td>
      <td> × 365
    </tr>
  </table>


displays as:
Payables period = Avg.Acc.P
[ .... ]
× 365
Similar result with a wiki-table:

  {| align="center"
  || Payables period =
  | style="text-align:center;" | Avg.Acc.P   <hr>  [ ..... ] 
  || × 365
  |}

Payables period = Avg.Acc.P
[ ..... ]
× 365
CiaPan (talk) 06:46, 22 June 2009 (UTC)
Use <hr style="background-color:black" /> to make the rule black instead of grey:
Payables period = Avg.Acc.P
[ ..... ]
× 365
— Emil J. 15:15, 22 June 2009 (UTC)
Something went wrong. Are you sure your example works? It renders with exactly same line color on my computer — both your and my fraction line display in "#AAAAAA" gray. Seems to me you meant to use style="color:black", not background-color. --CiaPan (talk) 05:46, 24 June 2009 (UTC)
I just tried it in three different browsers (Firefox, Opera, Konqueror), and all of them display it black as I intended. On the other hand, with style="color:black" it displays as grey. I consider it highly unlikely that all three would mysteriously have the same bug in their CSS code, hence chances are that it is your browser (which one is that?) which is wrong. In any case, it should not do any harm to set both properties: <hr style="background-color:black;color:black" />. — Emil J. 10:45, 24 June 2009 (UTC)
It's MS IE 7.0 on WinXP Pro SP3.
BTW, MSDN Library (August 2006 version, which I have on my disc) does not mention neither 'color' nor 'background-color' STYLE property for HR. However it describes the 'color' property of HR item itself (that is
). --CiaPan (talk) 13:41, 24 June 2009 (UTC)
The color attribute of the hr element is not present in XHTML 1.0[2], HTML 4.01[3] or HTML 3.2[4] (I don't feel like searching older versions), and as such it is completely nonstandard (and thus gets removed by Wikipedia software, try it). The CSS color[5] and background-color[6] properties apply (in principle) to all elements, including hr.
A bit of googling revealed that cross-browser styling of hr elements is indeed a royal mess. For color, the recommended way is to set both background-color and color as above (and set nonzero height and null border because of Opera, but the default WP stylesheet already does that). For anything more complicated, the only reliable way seems to be to wrap the rule in a div, style the div, and make the hr invisible: <div style="..."><hr style="display:none" /></div>. — Emil J. 14:34, 24 June 2009 (UTC)

Subscript with several letters?

Is it possible to make a subscript with several letters in math, like Ptotal? Mikael Häggström (talk) 16:29, 13 November 2008 (UTC)

Here: Gary King (talk) 16:39, 13 November 2008 (UTC)
See the help page, section Subscripts, superscripts, integrals --CiaPan (talk) 07:01, 14 November 2008 (UTC)
I find having to wrap anything more than a single character subscript or superscript counter-intuitive, e.g. 2^{16} for but I guess that's a TeX limitation? --80.175.250.218 (talk) 19:33, 7 August 2009 (UTC)

Not a subset of ΤΕΧ

At present, the help article claims

MediaWiki uses a subset of TeX markup, including some extensions from LaTeX and AMS-LaTeX, for mathematical formulae.

LaΤΕΧ is not a subset (proper or improper) of ΤΕΧ; the claim is self-contradictory. An accurate claim would be

MediaWiki uses a subset of AMS-LaΤΕΧ markup, a superset of LaΤΕΧ markup which is in turn a superset of ΤΕΧ markup.

SlamDiego←T 10:05, 14 April 2009 (UTC)

I believe some of the tex markup is filtered out by texvc, so the assumption that MediaWiki use a subset of TeX is true, regardless if it also support a subset of some LaTeX extra stuff beside that. —Preceding unsigned comment added by 195.83.155.55 (talk) 17:37, 24 July 2009 (UTC)

only 20 columns in matrixes

Dear friends,

columns

<math>
\begin{bmatrix}
  1 & 2 & 3 & 4 & 5 & 6 & 7 & 8 & 9 & 10 & 11
\end{bmatrix}
</math>

generates:

This is today (18:21, 8 August 2009 (UTC)):

Failed to parse (PNG conversion failed; check for correct installation of latex, dvips, gs, and convert): \begin{bmatrix} 1 & 2 & 3 & 4 & 5 & 6 & 7 & 8 & 9 & 10 & 11 \end{bmatrix}

rows

<math>
\begin{bmatrix}
 1 \\
 2 \\
 3 \\
 4 \\
 5 \\
 6 \\
 7 \\
 8 \\
 9 \\
 10 \\
 11
\end{bmatrix}
</math>

generates:

problem

It makes not much sense to limit the number of columns to 10. Can anybody verify if this is a known problem / bug ? If so please report it to bugzilla: and / or kindly ask to update / reconfigure "math". Thanks in advance! Best regards
‫·‏לערי ריינהארט‏·‏T‏·‏m‏:‏Th‏·‏T‏·‏email me‏·‏‬ 18:21, 8 August 2009 (UTC)

This arbitrary limit is imposed by TeX itself (more precisely, the amsmath package). It is controlled by the MaxMatrixCols counter. — Emil J. 10:35, 10 August 2009 (UTC)
Thanks for the answer! Is it possible to change it; for example to 36 or the same value as the one used for rows? Best regards
‫·‏לערי ריינהארט‏·‏T‏·‏m‏:‏Th‏·‏T‏·‏email me‏·‏‬ 14:48, 10 August 2009 (UTC)
There is no limit on rows. In real TeX, you can change the column limit easily with \setcounter{MaxMatrixCols}{36}. This is not accepted by texvc, so on Wikipedia it would require a global change by a developer. You might try to petition for it on bugzilla, but don't hold your breath. Why do you need such a wide matrix, anyway? In any case, you can work around it by using array instead:
    \left[\begin{array}{ccccccccccc}1 & 2 & 3 & 4 & 5 & 6 & 7 & 8 & 9 & 10 & 11\end{array}\right]
— Emil J. 15:12, 10 August 2009 (UTC)

Re.: "Why do you need such a wide matrix, anyway?"

Please see Most-perfect magic square#Examples (and fr:talk:Carré magique plus que parfait).
‫·‏לערי ריינהארט‏·‏T‏·‏m‏:‏Th‏·‏T‏·‏email me‏·‏‬ 11:36, 11 August 2009 (UTC)
I actually think that the ASCII art is OK, for one thing it does not have accessibility issues like PNG-rendered TeX. However, if you absolutely want to rewrite it using TeX markup, array is your best bet: apart from the columns problem, it also lets you keep the entries right-aligned (matrix can only center them). — Emil J. 12:45, 11 August 2009 (UTC)

Dankon Brion!
‫·‏לערי ריינהארט‏·‏T‏·‏m‏:‏Th‏·‏T‏·‏email me‏·‏‬ 15:51, 14 August 2009 (UTC)

scaling a formula

Dear friends, assume that you have the following text:

If is the order of a most-perfect magic square then . Assuming the prime decomposition of is
where for and
example:

Question: Is it possible to scale the rendering of the output for the example? Thanks for your help in advance! Best regards
‫·‏לערי ריינהארט‏·‏T‏·‏m‏:‏Th‏·‏T‏·‏email me‏·‏‬ 11:45, 11 August 2009 (UTC)

Depends on what do you mean by scaling. If you want to scale it down so that it matches the size of the text around, you can try to force \scriptstyle: , or you can simply rewrite it in HTML: 360 = 23·32·51. If you want to scale it up to make it more prominent, I don't think you can do it using <math> markup; however, you can write it in HTML as above, and adjust the size with appropriate CSS:
<span style="font-size:200%">360 = 2<sup>3</sup>·3<sup>2</sup>·5<sup>1</sup></span>
360 = 23·32·51
— Emil J. 12:57, 11 August 2009 (UTC)

Rendering of small z

When reading the article on the gamma function, I noticed that the when the letter z is set in a smaller-than-usual size, it looks very similar to "≈", as in this example:

Is there anything that can be done to improve that? I realize it's probably not a big problem, but I think anything that can be done to improve the clarity of math articles is a good thing. I'm generally struggling to understand something whenever I consult a math article, and any difficulty in recognizing the symbols being used is an unwelcome distraction.

John W (talk) 15:11, 15 October 2009 (UTC)

formulas should be composed by TeX. 129.132.225.144 (talk) 22:30, 28 October 2009 (UTC)

Phi and varphi and weird behaviour

What's up with the different phi and varphi symbols for the same code, \phi?:

It appears to me as when it has to load some libraries, it switches over to the usual TeX \phi, but when it needn't do it, we get TeX's \varphi!

  • and
  • and versus —Preceding unsigned comment added by 62.194.183.233 (talk) 11:32, 7 March 2010 (UTC)
, , and render in HTML, and your font happens to show the Unicode character φ (U+03C6 GREEK SMALL LETTER PHI) as \varphi (both are possible). The other formulas are rendered in PNG using TeX. You can force PNG rendering with \, as described in the help page.—Emil J. 12:11, 8 March 2010 (UTC)

Which fonts are used?

Which fonts does Wikipedia's LaTeX renderer use? SharkD  Talk  19:20, 2 April 2010 (UTC)

Slashing more than one symbol

Is there any way to slash more than one symbol?

Example: is fine, but is ugly. Albmont (talk) 14:02, 11 March 2010 (UTC)

. Also note the extra space in the superscript, so it doesn't look so much like a power. Nageh (talk) 09:08, 4 April 2010 (UTC)

Better math formatting support please! (cross-posted to MathML)

Ok, how can we get this to the right people in the wikipedia/media foundation? The current MathML support is non-existent, and the random formatting changes in expressions like (upright, standard font), (italic), (missing spaces around congruence sign) and (font much larger than rest of text) are embarrassing. For a start, it would be nice if the math tags could at least produce the same font in all cases. People agree? Nageh (talk) 08:46, 4 April 2010 (UTC)

Just found out that the first expression is rendered in upright, standard font only when you select MathML rendering in your preferences! Wow, we have MathML rendering! >:) Nageh (talk) 11:08, 4 April 2010 (UTC)

Can someone tweak some formulas for me?

Every time I use the math tags I end up with different results. Can someone who understands how it works please patch up the headway article? I used the exact same syntax for three formulas in a row, and each one looks different. The first is in big text and appears to be an image? The next is sans-serif and indented, with huge whitespace on the division. The third goes back to a serif font (which I'd prefer) and is not indented. I can't figure out how to fix this. Help?! Maury Markowitz (talk) 12:38, 1 September 2009 (UTC)

Please see #Why doesn't this one work? section aboveat this history page. Hope this helps. --CiaPan (talk) 06:52, 2 September 2009 (UTC)
(New pointer to history page by kcylsnavS{screechharrass} 00:50, 25 May 2010 (UTC))

/textstyle

What does the /textstyle switch do? Document? kcylsnavS {screech} 14:34, 16 May 2010 (UTC)

You mean \textstyle, I suppose. It switches the formula (or the subformula where it appears) to text style, which implies that large operators (symbols of type \mathop) will not be that large as in display style (which is the default style for Wikipedia <math>...</math>), and numerators and denominators in fractions and fraction-like constructs will be in script style (whereas they would appear in text style if the fraction were in display style), which in particular makes them smaller. I'm not sure whether all this makes much sense without understanding the concept of TeX's math styles, see the TeXbook for a more detailed explanation.—Emil J. 12:30, 17 May 2010 (UTC)

OK. I thought maybe it just meant that fonts were used instead of images, which would be nice for signatures. kcylsnavS{screechharrass} 00:41, 19 May 2010 (UTC)