6
$\begingroup$

I hope I'm at the right place to write my question.Because the mathjax tag exists at both stackoverflow.comand tex.stackexchange.com.

I want to write this equation (This is just an example)

$$G(x_1,x_2,x_3,\cdots, x_n):=A_1(x_1)+A_2(x_2)+ A_3(x_3)+\cdots+A_n(x_n)$$

in MathJax but my MathJax syntax doesn't work.

I want to write the left side of equation with larger syntax and the right of side with normal syntax. But, my MathJax syntax doesn`t work. I tried:

\mathlarger {G(x_1,x_2,x_3,\cdots, x_n)}:=A_1(x_1)+A_2(x_2)+ A_3(x_3)+cdots+A_n(x_n)

\bigletter {G(x_1,x_2,x_3,\cdots, x_n)}:=A_1(x_1)+A_2(x_2)+ A_3(x_3)+cdots+A_n(x_n)

\mathlarger {G(x_1,x_2,x_3,\cdots, x_n)}:=A_1(x_1)+A_2(x_2)+ A_3(x_3)+cdots+A_n(x_n)

But, \mathlarger{G}, \bigletter {G} and \ensuremath {G} doesn't work.

\Large {G(x_1,x_2,x_3,\cdots, x_n)}=A_1(x_1)+A_2(x_2)+ A_3(x_3)+cdots+A_n(x_n)

\huge {G(x_1,x_2,x_3,\cdots, x_n)}=A_1(x_1)+A_2(x_2)+ A_3(x_3)+cdots+A_n(x_n)

In the last line I use \Large and \huge change all equations size. So, I have no idea, what can I do.

$\endgroup$
  • 8
    $\begingroup$ Limit the scope of \Large, e.g. {\Large G(x_1,\dotsc, x_n)} = A_1(x_1) produces ${\Large G(x_1,\dotsc, x_n)} = A_1(x_1)$. (And wow, that looks ugly. At most use \large.) $\endgroup$ – Daniel Fischer Nov 30 at 21:17
  • $\begingroup$ @DanielFischer Ohh..Finally..Thank you very much..!and I want to ask is math.meta.stackexchange.com right place for such questions? $\endgroup$ – Elementary Nov 30 at 21:21
  • 1
    $\begingroup$ Questions about how to do stuff in MathJax are somewhat on topic here (take a look at the questions tagged mathjax). But I think such questions often would be better suited for TeX - LaTeX (however, I don't really know the scope of the mathjax tag there). $\endgroup$ – Daniel Fischer Nov 30 at 21:31
  • $\begingroup$ @DanielFischer The users of tex.stackexchange.com directed me to stackoverflow.com. Because MathJax is off topic. Users of stackoverflow.com have stated that this is a much more wrong place. I found the last address with my own head :) I see that, there were only 2 parenthesis errors in my syntax $\endgroup$ – Elementary Nov 30 at 21:40
  • 3
    $\begingroup$ Ah, well. You can however always ask how to do stuff in $\LaTeX$ over there (after looking for duplicates first), and then check whether it also works in MathJax. $\endgroup$ – Daniel Fischer Nov 30 at 21:43
  • $\begingroup$ @DanielFischer I've spent almost $2$ hours for $2$ parenthesis errors... Thank you for to solve the problem and for further information. $\endgroup$ – Elementary Nov 30 at 21:49
  • $\begingroup$ @DanielFischer by the way can I ask why \mathlarger and \bigletter doesnt work in mathjax? $\endgroup$ – Elementary Nov 30 at 21:52
  • 2
    $\begingroup$ I don't know \mathlarger or \bigletter. I'd guess that either MathJax doesn't know them at all, or you must \require some package that provides them. $\endgroup$ – Daniel Fischer Nov 30 at 21:55
  • $\begingroup$ @DanielFischer I found it tex.stackexchange.com while looking for a solution to my question. Well. I understood.Thanks again! $\endgroup$ – Elementary Nov 30 at 21:59
  • $\begingroup$ I suppose that MathJax is off-topic at the TeX StackExchange because that is about TeX for publication, and they would be overwhelmed with MathJax questions if it were on-topic (or so I assume). So the question of why mathlarger and other commands aren't implemented in MathJax is off-topic, but the similar question of which packages they require would be on-topic. The question of why large and huge didn't do what you expected, would also be on-topic, although you'd probably first want to check (perhaps at codecogs.com/latex/eqneditor.php) that it's not a MathJax error. $\endgroup$ – Toby Bartels Dec 2 at 18:23
  • 1
    $\begingroup$ Why on earth would you want to do that? $\endgroup$ – mrf Dec 3 at 11:58
8
$\begingroup$

The size directives \large etc. are not commands taking arguments. Their effect lasts until the scope(1) in which they were issued ends. The same holds for style selectors like \displaystyle, \scriptscriptstyle and so on. Thus wrapping G(x_1, \dotsc, x_n) in braces doesn't make it an argument to \large, it just makes the expression an ordinary maths atom (which can be important for correct spacing). To end the effect of the size directive before the end of the equation, you need to create a new scope (typically via braces, but beginning a new environment (e.g. cases) and issuing the directive there is also possible).

{\large G(x_1,x_2,x_3,\cdots, x_n)} := A_1(x_1)+A_2(x_2)+ A_3(x_3)+\cdots+A_n(x_n)

produces $${\large G(x_1,x_2,x_3,\cdots, x_n)} := A_1(x_1)+A_2(x_2)+ A_3(x_3)+\cdots+A_n(x_n)$$


(1) I'm not a $\TeX$ expert, I may not be using the official terminology.

$\endgroup$
  • $\begingroup$ LaTeX wikibook suggest it's a switch. okay maybe not quite, but close. $\endgroup$ – Roddy MacPhee Dec 1 at 14:34

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .