Extensions of the molecular dynamics simulation method. II. Isothermal systems