I am looking at the formula of entropy on Wikipedia, where $P(X)$ is a probability mass function.
\begin{equation} H(X) = -\sum_{i=1}^{n}P(x_i)log_bP(x_i) \end{equation}
I got curious why they use capital $P$ here because I am used to seeing lower case $p$ for the probability of a specific event. So why is $P$ used instead of $p$? On the page of probability mass function they use other notations too
\begin{equation} p_X(x_i)=P(X=x_i) \end{equation}
but both of those notations are different from $P(x_i)$. Perhaps this is nit-picking but I feel that there is not a lot of leeway when using formulas correctly.
So is the notation in the entropy formula incorrect, or is it another valid alternative? If so, is $p(x_i)$ also correct?