Alright, now I want to shift gears again, one final time, before winding down.
What will we cover now?
Over the course of this discussion, we've been looking at different variations of prime counting functions, right?
Sure.
That has been my main goal here, of course. But just briefly, I want to draw attention to another, deeply related function, to highlight a really fruitful connection. So, first, as always, let's return to our basic prime counting function. So we have, as before,
Right, right.
Okay, so here's the trick in two steps. First, what is the identity element for multiplication?
That's $1$, because any number times $1$ is itself.
Good. So let's use the letter $I$ to denote the identity element. Then I think you would understand what I meant if I were to rewrite our function like so:
Sure.
Good. Now, what's the corresponding identity element for addition?
$0$, of course, as any number $+ 0$ is, once again, just itself.
Exactly. Well, now what we'll do to make our new function is simply change the division operation to subtraction instead. So that should look like this:
And as the function name there suggests, this change makes the function compute harmonic numbers, the function defined by $\displaystyle H_n = \sum_{k=1}^n \frac{1}{k}$
So this new function looks like this:
I imagine $g_1(n,1)$ is a horribly inefficient way to compute harmonic numbers, though.
That's true. On the other hand, there are lots of fascinating cases where the prime counting function and harmonic numbers have analogous identities. And the parallel we've just covered above is a good window in to why that is that case, although it really is just scratching the surface.
Huh, interesting.
I'll mostly drop this thread here, but if that sounds interesting, you can check this article series for more discussion about these striking parallels.
Previously, we ended each discussion by connecting the recursive definition to the logarithm of the Riemann zeta function somehow.
Right. Is there something similar we can do here?
Yes... or, well, the mechanics are the same, although the end result is much simpler than the notoriously perplexing Riemann zeta function.
So, first, start by generalizing the recursive function $g_k(n,j)$ above by adding a scaling parameter $e^{s j}$, like so:
$$g_k(n,j)=\rec{\rr{e^{s j} \cdot} (\frac{1}{k}-g_{k+1}(n-j,1)) + g_k (n, j+1)}$$Similar to the $j^s$ parameter from the previous cases, right?
Exactly. Anyway, then, just as before, with a bit of rearrangement and an aggressive unrolling of sums, that function becomes
$$g_1(n,1)=\sum_{ {j_1}=1}^n { e^{-s j_1}}- \frac{1}{2} \sum_{ {j_1}=1}^n \sum_{ {j_2}=1}^{n-j_1} e^{-s({j_1} + {j_2})}+ \frac{1}{3} \sum_{ {j_1}=1}^n \sum_{ {j_1}=1}^{n-j_1} \sum_{ {j_3}=1}^{n-j_1-j_2} e^{-s({j_1} + {j_2} + {j_3})}- ...$$And then, for suitably chosen values of $s$, we can take a limit as $n$ goes to infinity. And if we do that, we'll find that this expression turns into
$$\log \left(\frac{1}{1-e^s}\right)=\sum _{k=1}^{\infty } \frac{(-1)^{k+1}}{k} \left(\frac{1}{1-e^s}-1\right)^k$$So these two identities show two universes, one that is additive and one that is multiplicative, right?
You can certainly look at them that way, sure. But I do want to wind down suggesting a different way to connect them, via a new generalization.
What is that?
Start by noting we can rewrite the core idea of our recursive prime counting function like so:
And now, $$f_1(\log(1+n),1) = \Pi(1+n)$$
Okay, I suppose I follow. And so we've replaced multiplication with the combination of addition and function application, right? But what's the advantage of this?
Well, suppose you had the following function, $\theta(x) = \frac{(1+x)^z-1}{z}$. What happens if you take a limit as $z \to 0$?
Then in that case, $\theta(x) = \log(1+x)$, right?
And if $z=1$?
Then $\theta(x) = x$, it seems.
Right. And so what would happen if we generalized our recursive definition like so?
with initial condition $$ f_1( \theta(n), 1) $$
Well, given that definition I suppose the if $z=1$, the function yields $H_n$. And if you take the limit as $z \to 0$, the function must yield the weighted count of prime powers $\Pi(1+n)$.
Exactly! Pretty striking, right?
Sure. But now that we have this generalization, what happens when $z$ takes on other values?
That seems like an interesting question to me.
It does! In fact, let me clarify my question. If $z=1$, the function yields $H_n$. And if we take the limit at $z=0$, the function yields $\sum_p H_{\lfloor \log_p n \rfloor}$. So both of those are expressed in terms of harmonic numbers. Are there sums in terms of harmonic numbers for other values of $z$?
It's fascinating, right?
Or what happens if we try to generalize it with a complex parameter $s$, to connect it to $\log \zeta(s)$ and $\log \left(\frac{1}{1-e^s}\right)$?
You mean like this?
Right. What does that converge to for other values of $z$? Or, I don't know, where does it equal $0$ or go to infinity if it's analytically continued?
I'll be honest; I have no idea about any of that. So I'll just note that I find this entire topic quite fascinating, too, and let it at that.
Anyway, I think we've covered a lot. Let's draw this all to a close.