From Kaczmarz algorithm to potential theory