Update ExponentialSpringForce.cpp
Update ExponentialSpringForce.cpp

Fixed two important bugs.

Bug 1
When the spring zero was updated due to sliding, the elastic part of the friction force was not being updated, which was causing inconsistencies in the spring cache data.

Bug 2
calcPotentialEnergy() was using the spring zero in the State. To get the correct strain energy in the friction spring, however, it needed to use the spring zero stored in the data cache (the auto update spring zero). An updated spring zero is cached when realizeSubsystemDynamicsImpl() is called.

simbody/simbody,simbody/simbody