Ununiform bracket sizes in $(x,y) = x \sin \left( \frac{1}{y} \right) + y \sin \left( \frac{1}{x} \right)$

In the PSQ Show that $f(x,y) = x \sin \left( \frac{1}{y} \right) + y \sin \left( \frac{1}{x} \right)$ is not differentiable at origin?, the question title contains the MathJax code

(x,y) = x \sin \left( \frac{1}{y} \right) + y \sin \left( \frac{1}{x} \right)

which is rendered as $$(x,y) = x \sin \left( \frac{1}{y} \right) + y \sin \left( \frac{1}{x} \right)$$.

The first pair of brackets is much bigger than the 2nd pair. Is there a way to make them look even?

• Putting the equation on its own line fixes this issue for me. (Alternatively, use \dfrac. Except, don't use \dfrac.) Jan 26 '21 at 15:25
• @user1729 I confirm your observation after testing this equation with displayed style in Firefox 84.0.2 (64-bit) on Ubuntu 20.04 that comes with the OS. Yes for sure. If I see a recent post containing a displayed style math expression, I usually edit them so that it's inline. Jan 26 '21 at 15:31
• The word "nonuniform" in the title would give a more conventional appearance. Jan 28 '21 at 5:38
• I am unable to see the difference on my devices. (I assume you are talking about the brackets on the right of the equals sign, the one to the left is the smallest) Jan 29 '21 at 4:50
• May be it is just my taste, but those parens look too large to me. I would prefer simple $$\sin\frac1x+\sin\frac1y$$ or even $$\sin(\frac1x)+\sin(\frac1y),$$ if judged that clarity requires some kind of parens wrapping the fraction. In my opinion \left...\right produces boxes that are too large in comparison to $\sin$. Jan 29 '21 at 7:29

Note that \big does not need to be left/right paired, you can type \big(\frac 1x\big) $$\big(\frac 1x\big)$$.

I also use the whole hierarchy in place of \left and \right because it gives more consistent results \Bigg(\bigg(\Big(\big(( $$\Bigg(\bigg(\Big(\big(($$

• related TeX.SE answer: tex.stackexchange.com/a/1233/126386 \big without l or r give more spacing, but the other answer suggests that it's a good practice to include that or use \mathopen{}. Jan 28 '21 at 7:50
• I started using \big and variants recently after finding some less than ideal behavior from \left/\right regarding whitespace. It's not as fool-proof, but it will create a more uniform look in your formulae. Jan 30 '21 at 14:11

I have tried using \vphantom.

Although I have to admit that:
a) I am not sure whether there are some adverse effects (e.g., for screenreaders).
b) I do not know whether there is a guarantee that it will be displayed the same for everybody.
c) It seems to me that there is difference between displaying math online and, e.g., in textbooks or papers - I would expect looking at various typesetting issues mostly in the latter case.

I tried $(x,y) = x \sin \left( \frac{1}{y}\vphantom{\frac1x} \right) + y \sin \left( \frac{1}{x}\vphantom{\frac1y} \right)$ to get this:
$$(x,y) = x \sin \left( \frac{1}{y}\vphantom{\frac1x} \right) + y \sin \left( \frac{1}{x}\vphantom{\frac1y} \right)$$.

Or, as Asaf Karagila suggests in the comment, it might be better to put exactly the same thing into vphantom: $(x,y) = x \sin \left( \frac{1}{y}\vphantom{\frac1{xy}} \right) + y \sin \left( \frac{1}{x}\vphantom{\frac1{xy}} \right)$ gives $$(x,y) = x \sin \left( \frac{1}{y}\vphantom{\frac1{xy}} \right) + y \sin \left( \frac{1}{x}\vphantom{\frac1{xy}} \right)$$.

• If you want a truly uniform size, you might as well use \frac1{xy} in your phantom text.
– Asaf Karagila Mod
Jan 26 '21 at 15:31
• This has the advantage over the other methods that no trial-and-error is needed, as the sizing is done automatically. It is more in-keeping with the TeX "ideal". Jan 27 '21 at 21:31

Just a suggestion:

$(x,y) = x \sin \bigl( \frac{1}{y} \bigr) + y \sin \bigl( \frac{1}{x} \bigr)$

gives $$(x,y) = x \sin \bigl( \frac{1}{y} \bigr) + y \sin \bigl( \frac{1}{x} \bigr)$$.