Updated Exampple 40.
Added diagonal springs and more influencing forces.
Cleaned up code and added some documentation.