Suppose that a is a real number. When the product a×a×a×a×a is written as a5, the number 5 is called the index. When the index is a positive integer p, then ap means a×a×⋯×a, where there are p occurrences of a. It can then be shown that
For a > 0 and x a real number, we define
and again rules (i)–(vii) hold. The same notation is used in other contexts; for example, to define zp, where z is a complex number, to define Ap, where A is a square matrix, or to define gp, where g is an element of a multiplicative group. In such cases, some of the above rules may hold and others may not.