The finite difference time domain method for computing the single-particle density matrix