Because there are 5 gallons initially, and because the net rate of change of volume is given by Z(t) - N(t) (ratein - rateout), the volume at any time t, for 0 ≤ t ≤ 12, is given by V(t) = 5 + ∫0t (Z(x) - N(x))dx.
It is easy to see by comparing Z(0) and N(0), Z0 < N0, that the volume is decreasing at t = 0. It will continue to do so until Z(t) = N(t), and thereafter the volume will increase (because Z(t) > N(t).
So, graph Z(t) and N(t) on the same axes, use a calculator to solve fo the t-coordinate of the point of intersection. Then, plug that t-value in for the upper bound of integration in the integral expression given above for V(t). That number will be the minimum volume of water in the tank (in gallons) on t ∈ [0 , 12].