I read the following statement in an article about photoacoustic tomography and don't understand a detail about it.
According to Duhamel's Principle, the inhomogeneous equation \begin{equation} \label{eq:8} \begin{cases} p_{tt}-c\Delta_{x}p = f(x) & \text{$t\geq0$,$x\in\mathbb{R}^3$}\\ p(x,0)=0, p_{t}(x,0)=0 \\ \end{cases} \end{equation}
is equivalent to
\begin{equation} \label{eq:9} \begin{cases} p_{tt}-c\Delta_{x}p = 0 & \text{$t\geq0$,$x\in\mathbb{R}^3$}\\ p(x,0)=f(x), p_{t}(x,0)=0 \\ \end{cases} \end{equation}
where $f(x)$ is the original pressure.
I am a bit confused, because as far as I know Duhamel's principle states that the initial values must be chosen exactly the other way around i.e.
$p(x,0)=0, p_{t}(x,0)=f(x)$
Why is it possible to swap the two conditions? Is this always possible?
The PDE they are talking about is not the one that you wrote (with just $f(x)$ on the right-hand side), but their equation (1) which also involves a Dirac delta with respect to the time variable: $$ p_{tt} - c^2 \Delta p = \frac{\partial}{\partial t} f(x) \, \delta(t) = f(x) \, \delta'(t) ,\qquad p(x,0)=0 ,\qquad p_t(x,0)=0 . $$ So $p=q_t$, where $q$ satisfies $$ q_{tt} - c^2 \Delta q = f(x) \, \delta(t) ,\qquad q(x,0)=0 ,\qquad q_t(x,0)=0 . $$ Applying Duhamel's principle to this problem for $q$, you'll only get a contribution from $s=0$ in the integral $\int_{0}^{t} (\cdots) \, ds$, because of the Dirac delta, so $q(x,t)$ is equal to the solution of $$ q_{tt} - c^2 \Delta q = 0 ,\qquad q(x,0)=0 ,\qquad q_t(x,0)=f(x) . $$ And this means that $p=q_t$ satisfies $$ p_{tt} - c^2 \Delta p = 0 ,\qquad p(x,0)=f(x) ,\qquad p_t(x,0)=0 . $$ (Here, the initial condition for $p_t$ comes from $p_t = (q_t)_t = c^2 \Delta q$, which is zero at $t=0$ since $q=0$ at $t=0$.)