# Solve PDE by getting two ODEs

My goal is to solve this PDE for $f:[-1,1] \times \mathbb{R}_{\ge 0}\rightarrow \mathbb{C}$ $$\partial_t f(x,t) = -\partial_x^2 f(x,t) + g(t)V(x)f(x,t).$$

I would consider this PDE to be solved if I get two ODEs just depending on either $x$ or $t$. $$f(x,0)$$ is specified a priori and $\int_{[-1,1]} f^*(x,t)f(x,t) dx=1$ for all $t \ge 0$.

By doing separtion of variables to the PDE $$\partial_t f(x,t) = -\partial_x^2 f(x,t) + g(t)V(x)f(x,t)$$ I ended up with the equation:

$$\frac{1}{\phi(t)} \partial_t{\phi(t)} = -\frac{1}{\psi(x)}\partial_x^2 \psi(x) + g(t)V(x)$$

where my solution is given by $f(x,t)= \phi(t) \psi(x)$ and $g$ is a $C^{\infty}$ function with compact support and $V \in C^{\infty}$. Does anybody know what the next would be? In my opinion, this result does not look very well as $x$ and $t$ are still connected via the $g,V$ term. Is there any better way to do this? Probably we need to choose $f$ differently? So, what I want to achieve is to get two separate equations for $x$ and $t$. Methods like Fourier transform seem to fail too in this general setting (cause it appears to me that we will end up with a messy convolution of the $g,V$ term that will make it difficult to solve the transformed ODE).

EDIT: Okay, this is my first question on stackexchange, probably I need to be more precise: An easy example where an integral transform seems to work is this one:

Let's start with an example $g(t) = \delta(t)$.

$$\partial_t f(x,t) = -\partial_x^2 f(x,t) + \delta(t)V(x)f(x,t).$$

If we do the Laplace transform with respect to $t$ we get:

$$sF(x,s)-f(x,0) = -\partial_x^2 F(x,s) + V(x)f(x,0).$$

Keeping in mind that $f(x,0)$ is specified a priori, we can sole this ODE(with respect to $x$) and transform it back.

Just out of curiosity: Is this calculation correct? ( I am completely new to the field of PDEs, so this is just what came to my mind). Maybe you could answer this subquestion in the comments, as this of course does not answer the more subtle problem, but it would help me to further understand what I am doing here).

I am really sorry. This is my first question, but apparently nobody wants to answer. I would really try to improve my question if anybody would comment on it.

-
In fact this PDE is not directly solvable by separation of variables. –  doraemonpaul Jun 22 at 19:38
@doraemonpaul thank you. do you know a way to do it? or a way to solve my particular example? –  Tobias Hurth Jun 22 at 20:13