Distance maximisation of points on a sphere and on a circle