IIRC, the mean is the particular case of the expected value where the transformation function is the identity function.
The general expression of the expected value, where f(x) is the probability density function and g(x) is the transformation function, is:
E[g(X)] = \int{g(x) * f(x) * dx}
Let g be the identity function (g(x) = x), then E[g(X)] is the mean.
For example, let's say that you bet on a throw of dice such than you win 2$ if the result is odd, lose 3$ if the result is 2, and win or lose nothing otherwise. Here, the event X is the throw of dice: you have 6 possible outcomes. Your transformation function is the gain you get for each outcome, therefore g(x) is defined by:
1 -> +2
2 -> -3
3 -> +2
4 -> 0
5 -> +2
6 -> 0
Then, the expected value E[g(X)] can be calculated by summing all the g(x) multiplied by the probability p(x) for all x (all outcomes).
The first point of the article, in my opinion, is more about statistics than math in general, and I believe people find it weird because of the confusion between X and x, the former being a random variable associated with a distribution function, the ater being a value in the domain of X.
The second point of the article is just ease of notation. The derivative of a function doesn't exist; a derivative is always made with respect to a variable (df/dx), but if a function has only one variable, then the derivative of the function is defined as the derivative of the function with respect to the one and only variable and we don't need to write this only variable (f'(x)).
You could always write the variables of a function (df(x, y, z)\dy instead of df/dy), but that's just a waste of time, specially when you have to write it for every line of the demonstration.