A Handbook of Mathematical Discourse
superscript
A string of characters is a superscript to a character if the string is placed immediately after the character and raised above the base line of the text.
Example 1 In the expression $x^{23}$, the string 23 is a superscript to $x$.
Superscripts are heavily overloaded in mathematical usage. They are used:
- a) To indicate a multiplicative power of a number or a function. Citation: (75), (237), (335).
- b) To indicate repeated composites of a function. Thus $f^{2}(x)$ means $f(f(x))$. It perhaps could be used to mean $f(x)f(x)$, but I have not found a citation for that usage. It appears to me that $f(x)f(x)$ would customarily be written $(f(x))^{2}$. Citation: (97).
- c) As an index. A superscript used as an index may indicate contravariance. Citation: (140).
- d) To indicate the domain of a function space. Citation: (345).
- e) To indicate the dimension of a space. Citation: (432).
- f) To indicate the application of an operator. This is common with the notation $T$ for transpose. Citation: (211), (386).
- g) As a bound on an operator, for example summation, product and integral. Citation: (293), (152).
- h) A few authors use a superscript to the left of the base character, as in $^{23}x$. This may be an index or have some other specially defined meaning. Citation: (405).
Difficulties A serious confusion in lower level college math courses occurs between $f^{-1}$ as the reciprocal of a function and $f^{-1}$ as the inverse. This is a special case of items (1) and (2) above.
Remark 1 Sometimes in my classes students give answers that show they think that the Cartesian power $\{ 1, 2, 3\}^{2}$ (which is $\{ 1, 2, 3\}\times \{ 1, 2, 3\}$) is $\{ 1, 4, 9\}$.

Pages 238–239 of the book (PDF).