Let $X$ and $Y$ be i.i.d with $X \sim \mathcal U([a,b])$. I want to determine the probability density function of $f_{X+Y}$ and I obtained the following: $f_{X+Y}(t) = ({1 \over b-a})^2 ((b-t) \boldsymbol{1}_{[0 \le t \le b-a]} + (t-a) \boldsymbol{1}_{[a-b \le t \le 0]})$. Is that correct?
I also want to ask if someone has a general form for $f_{X+Y}(t)$ if $X \sim \mathcal U([a,b])$ and $Y \sim \mathcal U([c,d])$.