TeX source:
\operatorname{dist}(\mathrm{C}, \mathrm{W})+\operatorname{dist}(\mathrm{W}, \mathrm{D})=\operatorname{dist}(\mathrm{C}, \mathrm{W})+\operatorname{dist}\left(\mathrm{W}, \mathrm{D}^{*}\right)