$\text{ or }\tilde{h}_{n}=\sum_{x\in X}x\left(p_{n}(x)\right)^{2}w_{x}$