How to calculate convolution of piecewise function $\phi$ Let $\phi: \mathbb R \to \mathbb R, \phi(t)=\begin{cases} 1- \cos{(t)}, & t \in [0,2\pi]\\
0, &\text{else} \end{cases}$
Define $g = \phi^{'}$ and $h(x)=\int_{-\infty}^{x}dt\phi(t)$
I have been asked to to show that  $(g*h)(x)=\begin{cases} >0 , &x \in (0,4\pi)\\
=0, & \text{else} \end{cases}$
$(g*h)(x)=\int_{\mathbb R}dyg(x-y)h(y)=\int_{\mathbb R}dy\sin(x-y)1_{\{(x-y)\in [0,2\pi]\}}\int_{-\infty}^{y}dt\phi(t)$
but now we know that $h(y):=\begin{cases} c \text{ i.e.  constant}, &y \geq 2\pi \\
0, &y < 0\\
\int_{0}^{y}dt\phi(t), &y \in [0,2\pi] \end{cases}$
But I am more concerned about the term  $\sin(x-y)1_{\{(x-y)\in [0,2\pi]\}}$. There must be some smart way to treat it. 
 A: Let us first generalize your problem, just for the pleasure of it. Consider $0 \ne \phi \in C _0 ^1 (\mathbb R)$ (differentiable functions with compact support) such that $\phi \ge 0$.
Let $g = \phi'$ and let $h(x) = \int _{-\infty} ^x \phi (t) \ \mathrm d t$.
Let $U = \{ x \in \mathbb R \mid \phi (x) > 0 \}$ and let $V = U + U = \{ x+y \mid x, y \in U \}$.
We shall show that $(g * h) (x) \begin{cases} >0, & x \in V \\ =0, & x \notin V \end{cases} .$
Integrating by parts (and noticing that $\phi$ vanishes at $\pm \infty$), you have
$$(g * h) (x) = \int _{-\infty} ^\infty g(x-y) \ h(y) \ \mathrm d y = \int _{-\infty} ^\infty \phi' (x-y) \left( \int _{-\infty} ^y \phi (t) \ \mathrm d t \right) \mathrm d y = \\
- \int _{-\infty} ^\infty \frac {\mathrm d} {\mathrm d y} [ \phi (x-y) ] \left( \int _{-\infty} ^y \phi (t) \ \mathrm d t \right) \mathrm d y = - \phi (x-y) \left( \int _{-\infty} ^y \phi (t) \ \mathrm d t \right) \Bigg| _{-\infty} ^\infty + \int _{-\infty} ^\infty \phi (x-y) \ \phi (y) \ \mathrm d y = \\
\int _{-\infty} ^\infty \phi (x-y) \ \phi (y) \ \mathrm d y = (\phi * \phi) (x) \ .$$
Since $\phi \ge 0$, it is immediate that $g * h \ge 0$.
In the following we shall use several times the following elementary property about integrals: if $F \ge 0$ then $\int F > 0 \iff \exists z$ such that $F(z) > 0$.
If $(g * h) (x) > 0$ then $\int _{-\infty} ^\infty \phi (x-y) \ \phi (y) \ \mathrm d y > 0$ so, since $\phi \ge 0$, we deduce that there exists $z \in \mathbb R$ with $\phi (x-z) \ \phi (z) > 0$, so in particular $x - z \in U$ and $z \in U$, so $x = (x-z) + z \in U + U = V$.
Conversely, if $x \in V$ then there exists $z \in U$ such that $x = (x-z) + z$ and $x - z \in U$. Since $z, x-z \in U$, then $\phi (x-z) \ \phi (z) > 0$ and, since $\phi \ge 0$, we deduce that $(g * h) (x) = \int _{-\infty} ^\infty \phi (x-y) \ \phi (y) \ \mathrm d y > 0$.
We have shown, then, that $(g * h) (x) >0 \iff x \in V$, which is exactly what we wanted.
