Let $f(x) = x$ for $0 \le x \le 1$, $x-1$ for $1 < x \le 2$, $0$ for $2<x \le 3$.
I ended up writing the double integral as $\iint_{D_3 \cup D_4} f = \int_0^2 dx \int_0^1 2x dy = 2 \int_0^1 dx \int_0^1 x dy$. For $2 \int_0^1 dx \int_0^1 x dy$, it feels like I'm adding the triangle defined on $0 \le x \le 1$ twice. I wanted to know how I'm able to do this for this specific function since $f(x)$ is not continuous. If $g$ is continuous on an interval, then $g$ has an antiderivative on $I$. But since the converse doesn't always hold true, it would be nice if someone could explain how we're able to integrate the triangle defined on $1<x\le2$, since this second triangle doesn't have a point defined on $x=1$, for this discontinuous function $f$.
$\int_0^1 x.dx + \int_1^2 (x - 1).dx + \int_2^3 0.dx$