(By "number" below I always mean an element of $\mathbb{Z}^+\setminus $$\left\{1\right \}$.)
We all know that a number $p$ is prime iff it cannot be represented as $ab$ for any two numbers $a$ and $b$. That got me thinking: can we generalize primality to arbitrary operations? Hear me out. We can come up with the following definition:
A number $p$ is $+$-prime iff it cannot be represented as $a+b$ for any two numbers $a$ and $b$.
But such a definition is pointless, and there is nothing to investigate here: it's obvious that the only $+$-primes are $2$ and $3$.
We can go further and come up with another definition:
A number $p$ is e-prime ("e" for "exponentiation") iff it cannot be represented as $a^b$ for any two numbers $a$ and $b$.
This is a little more interesting. For example, the first five e-primes are $2$, $3$, $5$, $6$ and $7$.
We can go even further by using hyperoperations:
A number $p$ is $\uparrow ^n$-prime (for a number $n\geq2$) iff it cannot be represented as $a\uparrow ^nb$ for any two numbers $a$ and $b$.
Does such a generalization exist in mathematics already? If it does, where can I read about it (books, papers, etc.)? To me personally, for example, e-primality sounds like something I would definitely want to learn more about.
Here's a partial answer from me to my own question :)
As @coffeemath has noted above, the e-primes are the complement of the set of nontrivial perfect powers. In other words (and under my made-up terminology) the perfect powers are the e-composite numbers. So, learning about the e-primes is essentially learning about the perfect powers (e.g. here is a nice paper on the distribution of perfect powers).
As for $\uparrow ^n$-primes, I don't know anything.
An obvious thing to note is that the "deeper" down this made-up hierarchy of mine we go, the more often the primes of a particular "type" appear. That is, there are only two $+$-primes, infinitely many regular primes, infinitely many e-primes (as far as I know) - but even though there are infinitely many of these, they still seem to crop up a lot more often than regular primes. I imagine that the pattern continues with $\uparrow^n$-primes because the numbers involved grow insanely fast, hence the giant gaps between any two consecutive $\uparrow ^n$-composites.
That's a very short summary of what I've found. Feel free to add your findings :)