Can a set of functions be orthogonal w.r.t. more than one weight function? A random thought that I had: suppose you have a set of real-valued one-dimensional functions $\{f_i(x)\}$ which are:


*

*Smooth over the domain of interest.

*Orthogonal with respect to integration against some weight function $w_1(x)$ (which is also smooth over the domain of interest):


$$\int_a^b f_i(x) f_j(x) w(x)\,dx=\delta_{ij} $$


*Complete for smooth functions defined over that interval, i.e. any smooth function can be written as a series expansion in $\{f_i(x)\}$:


$$g(x)=\sum_{n=0}^{\infty} c_n f_n(x)$$
Is it possible for the same set of functions $\{f_i(x)\}$ to be orthogonal with respect to a separate weight function $w_2(x)$, which is independent from $w_1(x)$? (i.e. the Wronskian of the two functions is non-zero everywhere)
If yes, can you provide an example?
 A: Let $[a, b]=[0,2\pi]$ and $f_n(x)=\pi^{-1/2}\cos(2nx)$ for integer $n>0$. Then all $f_n$ are normalized and mutually orthogonal on $[a, b]$ with any weight function of the form $w(x)=1+C\cos(x)$ (one can add to $w$ more terms of the form $\cos((2n+1)x)$, of course) 
Update: If the system is complete (its span is dense in $L^2([a,b], w_1 dx)$), then the answer is negative (at least for weight function $w_1$ not vanishing on $[a,b]$). Let's assume that there exists the weight function $w_2$ such that the system $(f_i)$ is orthonormal with respect to the weight $w_2$ as well. Consider the functions $g_i=f_i(x)(w_2(x)-w_1(x))/w_1(x)$. Since $g_i$ are orthogonal to all functions of the system $(f_n)$ with the weight $w_1$, they are identically zero by the hypothesis of completeness. On the other hand, all $f_i$ cannot simultaneously vanish on a set of positive measure (otherwise the characteristic function of this set would be a non-zero vector of $L^2([a,b], w_1 dx)$ orthogonal to the span of $(f_n)$, which contradicts the denseness of the latter). Therefore $w_2/w_1= 1$ almost everywhere, and since both are assumed smooth also everywhere on $[a, b]$. 
