If however, I use the BuddyPress profile page to change the picture, then the correct image is displayed in the toolbar and wordpress profile page, as well as the buddypress profile.
I discovered that if I delete the ‘Gravatar’ directory in the WordPress installation, the correct images are picked up by the BuddyPress profile.
However, the WordPress profile doesn’t show a profile picture, nor does the top bar.
If I deactivate BuddyPress, then WordPress picks up the Gravatar images correctly.