# Moments of a Wiener process evaluated at some random time.

Assume that we have a random variable $$T$$ that takes values in $$[0, \infty)$$, and we know that for any continuous integrable function we have that for all $$k \in \mathbb{N}$$ the following holds $$\mathbb{E}[\left(f(T)\right)^k] = \left(\int_0^\infty f(t)g_k(t) dt\right)^k$$ for some bounded function $$g_k$$ that depends on $$k$$.

Is it true that, assuming that $$T$$ is independent from a Wiener process $$W$$, the following holds for each $$k \in \mathbb{N}$$ $$\mathbb{E}[(W(T))^k] = \mathbb{E}\left[\left(\int_0^\infty W(t) g_k(t) dt\right)^k\right].$$

What I would like to find out is that if we know all the moments of $$f(T)$$, via a nice simple formula, then if we can use this formula when we replace $$f$$ by a stochastic process with continuous paths. I hope that it makes sense.