Brauer groups and Tate-Shafarevich groups