9

I typed in this question like this:

$\underbrace{\alpha \hat{\phantom{\hat{}}} \alpha \hat{\phantom{\hat{}}} \dots \hat{\phantom{\hat{}}} \alpha}_\text{n times}$

which mathjax prints as

example output

I feel there should be a more correct way to do this.

2
  • 1
    I am not sure that that is such a good idea since exponentiation is not associative: 2^(3^2) is not the same as (2^3)^2). So what exactly does 2^3^2 mean? This is probably the reason why TeX complains about double super scripts. Commented Jul 28, 2012 at 23:32
  • 2
    @PeterGrill if you look at the linked question, you'll see that the expression is referring to the number of possible results with parentheses inserted in all possible ways. Commented Jul 28, 2012 at 23:39

5 Answers 5

10

You could also type

\def\mhat{\mathbin{\hat{\vphantom{x}}}} % spacing like a binary operator 
$\underbrace{\alpha\mhat\alpha\mhat\cdots\mhat\alpha}_{\text{$n$ times}}$

enter image description here

0
3

There doesn't seem to be a circumflex (hat) symbol intended for use in maths mode, except as an accent. However, you can use the text mode version \textasciicircum (or alternatively just \^{}). This avoids the need for phantoms.

\documentclass{article}
\usepackage{amsmath}
\newcommand\mathcirc{\text{\textasciicircum}}
\begin{document}
\[
\underbrace{\alpha \mathcirc \alpha \mathcirc  \ldots \mathcirc \alpha}_{n\text{ times}}
\]
\end{document}
3

Perhaps you might like to use

\newcommand\expon{\mathbin {^\wedge}}

or, if you're quite flexible about the symbol you use, adopt Knuth's up-arrow notation:

\newcommand\expon {\mathbin {\uparrow}}
2

A variant without hat that counts the exponential operations:

$\bigl(\bigl(\bigl(\alpha
\underbrace{
  ^\alpha\bigr)^\alpha\bigr)^{\cdots}\bigr)^\alpha
}_\text{$n$ times}
= \alpha^{(\alpha^n)}$

enter image description here

2
  • But the idea of the OP is not to include the parentheses explicitly; the OP is defining an expression for counting all possible different values obtained by inserting parentheses in every possible way in the original expression. Commented Jul 29, 2012 at 0:38
  • I think that it would be better to add centered dots after the first parenthesis : \bigl(\cdots\bigl(\bigl(....
    – projetmbc
    Commented Jul 29, 2012 at 10:44
1

Just like Heiko's answer, but without the parentheses:

\alpha
\underbrace{
  {{{^{\alpha\vphantom{h}}}^{\alpha\vphantom{h}}}^{\cdots\vphantom{h}}}^{\alpha\vphantom{h}}
}_{\text{$n$ times}}
= \alpha^{(\alpha^n)}

enter image description here

(A \strut instead of \vphantom{h} gives me too much vertical space.)

(Probably better with \! after the initial \alpha.)

8
  • This unfortunately misses the point of the OP in the same way as Heiko's answer; with the additional problem that the equation you write is incorrect. Commented Jul 29, 2012 at 9:47
  • The notation without parenthesis is very ambiguous.
    – projetmbc
    Commented Jul 29, 2012 at 10:45
  • 1
    @projetmbc But wasn't it the point? I thought the OP wanted an expression where parentheses could be inserted in every possible way. (Of course, I copied the equation from Heiko, so the equality only holds for a particular way of inserting the parentheses, but I thought the LHS is what the OP wanted to express.)
    – Jellby
    Commented Jul 29, 2012 at 10:59
  • @NieldeBeaudrap: As Jellby just explained, only the LHS is important here. (Ok, then maybe he should remove the RHS). Any way, I think this is a great way of writing the expression, as you don't need to define a new exponentiation operator.
    – bodo
    Commented Jul 29, 2012 at 13:33
  • Umm... When you have an actual vertical tower of exponents, the fact that there are no parentheses doesn't make it ambiguous. The exponents are then evaluated top-down. For instance. If \alpha=2 and n=3, the result would be 16 (or 2^4). That's standard mathematical notation. It's when you introduce an explicit, non-associative boolean symbol as in the OP that ambiguity arises. Commented Jul 30, 2012 at 10:57

You must log in to answer this question.

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