\documentclass[a4paper,12pt]{article}
\newcommand{\ds}{\displaystyle}
\newcommand{\un}{\underline}
\newcommand{\undb}{\underbrace}
\newcommand{\pl}{\partial}
\parindent=0pt
\begin{document}

{\bf Question}

Find all the solutions of $u_t+cu_x=0$ where $c$ is a constant
which satisfy $u_t(x,0)+ku(x,0)=\phi(x)$, where $k$ is a constant
and $\phi$ is a given function.

\medskip

{\bf Answer}

The general solution of $u_t+cu_x=0$ is given by:

$\ \ \ds\frac{dt}{d\xi}=1,\ \ds\frac{dx}{d\xi}=c,\
\ds\frac{du}{d\xi}=0$

$\ds\frac{dt}{dx}=\ds\frac!{}{c},\ u=const$

$\Rightarrow \ds\frac{dx}{dt}=c,\ u=const$

$\Rightarrow x=\alpha+ct,\ u=\beta\ \ \ \ \ (alpha,\ beta=const.)$

Therefore $\left\{\begin{array} {rcl} x-ct & = & const\\ u & = &
const \end{array} \right.$

$\Rightarrow \un{u=f(x-ct)}$

Therefore boundary condition is satisfied by:

$$-cf'(x)+kf(x)=\phi(x)$$

(1st order linear: solve with integrating factor
$e^{\frac{-kx}{c}}$)

This ODE can be solved to give:

$\ \ f'(x)-\ds\frac{k}{c}f9x)=\ds\frac{1}{c}\phi(x)$

$\Rightarrow
e^{\frac{-kx}{c}}f'(x)-\ds\frac{k}{c}e^{\frac{-kx}{c}}f(x)
=\ds\frac{e^{\frac{-kx}{c}}}{c}\phi(x)$

$\Rightarrow \ds\frac{d}{dx}\left[e^{\frac{-kx}{c}}f(x)\right]=
\ds\frac{e^{\frac{-kx}{c}}}{c}\phi(x)$

$\Rightarrow e^{\frac{-kx}{c}}f(x)=\ds\frac{1}{c}\ds\int_a^x
d\eta\phi(\eta)e^{\frac{-kx}{c}}$

$\Rightarrow \un{f(x)=\ds\frac{e^{\frac{-kx}{c}}}{c} \ds\int_a^x
d\eta\phi(\eta)e^{\frac{-kx}{c}}}$

where $a$ is an arbitrary constant.

So the specific solution is:

$$u(x,t)=\ds\frac{e^{\frac{k(x-ct)}{c}}}{c}\ds\int_a^{x-ct}
e^{\frac{-k\eta}{c}}\phi(\eta)d\eta$$

where $a$ is an arbitrary constant.

\end{document}
