The conditional expection of variance under risk neutral measure is
$$\mathbb{E}^Q[V_T |S_T=K]$$
where $S_T$ and $K$ represent the spot price at maturity and strike price, respectively.
Assume I know the risk neutral density $q(V,S,t)$, I want to calculate the inverse of conditional expectation of $V_T$. Should I use this formula
$$\frac{1}{\mathbb{E}^Q[V_T|S_T=K]} = \frac{1}{\int V_t \cdot q(v,s,t)\cdot dV}$$
or another formula
$$\frac{1}{\mathbb{E}^Q[V_T|S_T=K]} = \frac{\int q(v,s,t)\cdot dV}{\int V_t \cdot q(v,s,t)\cdot dV}$$
Further, if
$$g(v,s,t)\approx q(v,s,t)\cdot dv \cdot ds$$
I wonder if we can get
$$\Bbb{E}^\Bbb{Q}\left[ V_T \vert S_T = s \right] = \frac{\int_\Omega v\,q_{V_T,S_T}(v, s,T) dv}{\int_\Omega q_{V_T,S_T}(v, s,T) dv} \approx \frac{\sum v\cdot q_{V_T,S_T}(v,s,t) \cdot dv }{\sum q_{V_T,S_T}(v,s,t) \cdot dv}$$
$$= \frac{\sum v \cdot \frac{g(v,s,t)}{dv \cdot ds} \cdot dv }{\sum \frac{g(v,s,t)}{dv \cdot ds} \cdot dv} = \frac{\sum v \cdot g(v,s,t)}{\sum g(v,s,t)}$$
Thanks!