Classical Newtonian dynamics is analytic and the energy of an isolated system is conserved. The energy of such a system, obtained by the discrete “Verlet” algorithm commonly used in molecular dynamics simulations, fluctuates but is conserved in the mean. This is explained by the existence of a “shadow Hamiltonian” [S. Toxvaerd, Phys. Rev. E 50, 2271 (1994)] , i.e., a Hamiltonian close to the original H with the property that the discrete positions of the Verlet algorithm for H lie on the analytic trajectories of . The shadow Hamiltonian can be obtained from H by an asymptotic expansion in the time step length. Here we use the first non-trivial term in this expansion to obtain an improved estimate of the discrete values of the energy. The investigation is performed for a representative system with Lennard-Jones pair interactions. The simulations show that inclusion of this term reduces the standard deviation of the energy fluctuations by a factor of 100 for typical values of the time step length. Simulations further show that the energy is conserved for at least one hundred million time steps provided the potential and its first four derivatives are continuous at the cutoff. Finally, we show analytically as well as numerically that energy conservation is not sensitive to round-off errors.