Putting a superscript before a variable or expression ....

  • Context: MHB 
  • Thread starter Thread starter Math Amateur
  • Start date Start date
  • Tags Tags
    Expression Variable
Click For Summary

Discussion Overview

The discussion centers around the formatting of superscripts in mathematical expressions, specifically in the context of LaTeX typesetting as referenced in a book on Set Theory. Participants explore methods for correctly placing superscripts before variables or expressions, particularly in relation to Cartesian Products.

Discussion Character

  • Technical explanation
  • Mathematical reasoning

Main Points Raised

  • One participant requests assistance with placing a superscript before a variable or expression.
  • Another participant suggests using the syntax $^{A}B$ as a straightforward solution.
  • A further contribution indicates that adding an empty pair of braces before the superscript, as in {}^{A}B, is necessary to prevent the superscript from attaching to the preceding element.
  • This participant provides a comparison between two expressions to illustrate the issue: $f\in ^I\left( \bigcup \{A_i:i\in I\}\right)$ versus $f\in {}^I \left( \bigcup \{A_i:i\in I\}\right)$, highlighting the attachment of the superscript.
  • They also mention that inserting a negative space after the superscript can improve the visual appearance of the expression.
  • A later reply reiterates the need for braces and negative space, thanking other participants for their assistance.

Areas of Agreement / Disagreement

Participants appear to agree on the necessity of using braces to properly format superscripts, but there is no consensus on the best approach to achieve the desired visual outcome, as different methods are proposed.

Contextual Notes

The discussion does not resolve the visual formatting preferences or the implications of using different methods in LaTeX.

Math Amateur
Gold Member
MHB
Messages
3,920
Reaction score
48
Can someone help with the issue/problem of placing a superscript before a variable or expression ... as Just and Weese do in their book on Set Theory ... in the expression for a Cartesian Product as follows:

View attachment 7536Hope that someone can help ...

Peter
 
Physics news on Phys.org
There are various packages that can do this and more sophisticated things, but I think in this case the easiest is: $^{A}B$. (Right-click on formula to see $\LaTeX$ source.)
 
You may need to add an empty pair of braces before the superscript, like this: {}^{A}B. Otherwise, the superscript will attach itself to the previous element in the formula. Compare

$f\in ^I\left( \bigcup \{A_i:i\in I\}\right)$ with $f\in {}^I \left( \bigcup \{A_i:i\in I\}\right)$.

In the first case, the superscript $I$ has attached itself to the $\in$ symbol. Even when the braces are inserted, the superscript looks as though it is suspended halfway between the symbols on either side. You can eliminate that by inserting a negative space (given in TeX by \!) after the superscript, to get

$f\in {}^I \!\left( \bigcup \{A_i:i\in I\}\right)$.
 
Opalg said:
You may need to add an empty pair of braces before the superscript, like this: {}^{A}B. Otherwise, the superscript will attach itself to the previous element in the formula. Compare

$f\in ^I\left( \bigcup \{A_i:i\in I\}\right)$ with $f\in {}^I \left( \bigcup \{A_i:i\in I\}\right)$.

In the first case, the superscript $I$ has attached itself to the $\in$ symbol. Even when the braces are inserted, the superscript looks as though it is suspended halfway between the symbols on either side. You can eliminate that by inserting a negative space (given in TeX by \!) after the superscript, to get

$f\in {}^I \!\left( \bigcup \{A_i:i\in I\}\right)$.
Thanks to Krylov and Opalg for the help ...

Much appreciated ..

Peter
 

Similar threads

Replies
1
Views
2K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 3 ·
Replies
3
Views
3K
  • · Replies 3 ·
Replies
3
Views
8K
  • · Replies 2 ·
Replies
2
Views
2K
Replies
4
Views
3K
  • · Replies 1 ·
Replies
1
Views
6K
  • · Replies 7 ·
Replies
7
Views
3K
  • · Replies 7 ·
Replies
7
Views
3K
  • · Replies 6 ·
Replies
6
Views
2K