I'm confused about the math in my textbook. It gives a formula $dE(x_i,y_i)=f(x_i,y_i,x_0,y_0)dx_0dy_0$ (where I give f(...) for simplicity sake) and then jumps to $E(x_i,y_i)=K*\int \int f(x_i,y_i,x_0,y_0)dx_0dy_0$
So is it always true that a double integral of an infinitesimal of a function yields the function itself? I've never seen this before, and also why does this yield a constant K?
That is true, integrating the differential of a function yields that function itself
For instance,
$\int$$dx = x + C$
$\int d(\frac{e^{x^2}}{t}) = \frac{e^{x^2}}{t} + C$
$\iint$$dA = A$
$\iiint$$dV = V$
Which becomes particularly useful in solving differential equations
In this case, $E = E(x_i,y_i)$ and the equation is written in differential form since $f$ is squashed by $dx_0dy_0$, which represents an infinitesimal patch of area. So integrating twice recovers $E(x_i,y_i)$
$\iint$$dE(x_i,y_i) = E(x_i,y_i) + C$
Where C (also seen commonly as K) is a constant that depends on the system.
But I'm not sure where K comes from in what you described since it's attached to $\iint$$fdx_0dy_0$ through multiplication.
Given a number b, it's certainly true that
$b + C \equiv kb$
for some numbers C and k, but this is not true with functions, $b = b(x)$, unless $C = 0$ and $k = 1$
Maybe it's a typo