Answer
$p = e^{t^{3}/3-t+C}-1$
Work Step by Step
$dp/dt = t^2p - p + t^2 -1$
We need to rearrange the equation so that it becomes separable:
$dp/dt = p(t^2 - 1) + (t^2 -1)$
$dp/dt = (t^2 - 1)(p + 1)$
$(1/(p+1))dp = (t^2 -1 ) dt$
Now let's integrate both sides:
$\int(1/(p+1))dp =\int (t^2 -1 ) dt$
$ln|p+1| = t^3/3 -t + C$
Now to isolate p, we can include "e" on both sides:
$e^{ln|p+1|} = e^{t^3/3 -t + C}$
$p+1 = e^{t^3/3 -t + C}$
$p = e^{t^3/3 -t + C}-1$