I'm trying to show that the space ($X$) of measurable functions on $[a,b]$ such that for a fixed, positive, function $h$, and $\forall f \in X$, $\int_a^b |f(x)|^2 h(x) < \infty$ is a Hilbert space with respect to the inner product $\langle f,g \rangle= \int_a^b f(x) {g^*(x)} h(x)dx$.
I'm mainly wondering about showing that this space is complete and separable. I have the corresponding proofs for $L^2([a,b])$ which I could just modify, but I am wondering if there is an easier way to prove this since the space is so similar to $L^2[a,b]$
Alternatively, i.e without considering $L^2$ spaces with respect to measures different from the Lebesgue measure, we can notice that $$X = \left\{f : f. h^{\frac{1}{2}} \in L^{2}[a, b] \right\}$$ and $$\forall f \in X, ||f||_{X} = ||f. h^{\frac{1}{2}}||_{L^{2}}$$ From there, it is not hard to prove that $X$ is both complete and separable.
For completeness:
Let $(f_{n})_{n \geq 1}$ be a Cauchy sequence in $X$.
Then $\left(f_{n}. h^{\frac{1}{2}}\right)_{n \geq 1}$ is a Cauchy sequence in $L^{2}[a, b]$ and hence, since $L^{2}[a, b]$ is complete, it converges to some $g \in L^{2}[a, b]$ with respect to $||.||_{L^{2}}$.
Therefore, $\frac{g}{h^{\frac{1}{2}}} \in X$ and $(f_{n})_{n \geq 1}$ converges to $\frac{g}{h^{\frac{1}{2}}}$ with respect to $||.||_{X}$.
$X$ is separable:
Since $L^{2}[a, b]$ is separable, there is a dense sequence $(f_{n})_{n \geq 1}$ in $L^{2}[a, b]$ with respect to $||.||_{L^{2}}$.
Then $\left(\frac{f_{n}}{h^{\frac{1}{2}}}\right)_{n \geq 1}$ is a dense sequence in $X$ with respect to $||.||_{X}$.