The correct formula for weighted average The formula for a weighted average is: sum of values, multiplied by respective weights, divided by count of values. Right? That’s what I thought it was until I saw other variations, which are basically the expected value—no dividing by the count of values. 
Does the weighted average require dividing the sum of weighted values by their count or is it exactly the same as the expected value formula?
 A: The general idea is that a weighted average (or mean) is    for a variable $x$ and weights $w$ $$\bar x = \sum_i w_i x_i / \sum_i  w_i.$$ 
If additionally or alternatively, weights are defined as adding to $1$, say in this notation $w'_i = w_i/\sum_i w_i$, then it follows that you can write $\bar x = \sum_i w'_i x_i$. 
The usual unweighted average fits this pattern too. Consider the average $(1 + 2 + 3)/3,$ which we could write in terms of $w_i = 1/3$ 
$$[(1/3) 1 + (1/3) 2 + (1/3) 3] / [(1/3) + (1/3) + (1/3)]$$ 
or in terms of $w_i = 1$ 
$$[1 \times 1 + 1 \times 2 + 1 \times 3] / [1 + 1 + 1]$$ 
or indeed using any other positive constant $w_i, 42, 666,$ or whatever else takes our fancy. 
The more general weighted average is often used without using that name. Suppose the variable is the number of bedrooms per household and in $100 $ households we observe  $1$ bedroom $30$ times, $2$  bedrooms $30$ times and $3$ bedrooms $40$ times. Then the appropriate average uses the  frequencies as weights, and is thus $(30 + 60 +  120) / 100 = 2.1.$. 
The weights do not have to be integers or even counts or frequencies. Thus one simple moving average (in time series analysis, and in some other contexts) is often presented as $0.25 \times$ previous value $+\ 0.5 \times$ present value $+\ 0.25 \times$ next value. That one was called Hanning by John W. Tukey, after Julius von Hann. 
There is no requirement that weights are all positive, just that their sum $\sum w_i$ is positive. For example, negative weights arise naturally for certain moving averages in time series analysis. And zero weights are allowed too in a definition, and just result in values not being included at all. An example would be a moving average using a finite window, where implicitly or explicitly observations not in the window get zero weight. 
A: The trivial case here is the arithmetic average, for example for two numbers we have:
$$x_a=\frac{x_1+x_2}{2}=\frac{1}{2}x_1+\frac{1}{2}x_2$$
The denominator in LHS is the number of observations because this is an equal averaging. Everyone equally contributes to the final result. In the RHS, you don't see a denominator, or number of observations, since we embedded the denominator into the weights. The crucial thing is, your final weights need to sum up to $1$, which is why you divide by number of elements in arithmetic means because every summand needs to have weight $1/n$ in the final formulation.
So, it is either
$$x_a=\sum w_ix_i, \ \ \ \sum w_i=1\ \ \ \ \text{or} \ \ \ x_a=\frac{\sum w_ix_i}{\sum w_i}$$
In the second one, sum of weights is again $1$ since (call $\sum w_i=W$:
$$x_a=\frac{\sum w_ix_i}{W}=\sum\left(\frac{w_i}{W}\right)x_i\rightarrow w_i'=\frac{w_i}{W}$$
And, $$\sum \frac{w_i}{W}=\frac{1}{W}\sum w_i=\frac{W}{W}=1$$
Specifically, the $E[X]$, expected value formulation, includes probabilities:
$$E[X]=\sum p_i x_i$$
where $\sum p_i=1$, by the definition of PMFs.
Check also the wiki page provided by @corey979 .
Edit: It seems that interesting definitions exist out in the internet, in which I've never seen being used. It seems like the definition is a very debatable issue, however, I'd stick with the wiki entry, which is closer to the mathematical domain, instead of Investopedia, which uses the term to reach a specific purpose.
