Thanks for the help.

Although I have to apologize for not understanding your anwser.

I have a 2nd question that is related to this:

How do I calculate the position of the unknown position?

You need to take the square you want to create and split it into two triangles along the diagonal. This diagonal would be the same as the diameter of the circle. To figure out the sides you just need the quadratic equation: a^{2} + b^{2} = c^{2} . Well c^{2} is the diameter.. that much should be known.. and both sides will be equal. So a^{2} = b^{2}, making it sufficient to change the equation to 2a^{2} = c^{2}.. or basically side = sqrt(diameter^{2 }/ 2). Or in terms of the radius, side = sqrt(2r^{2})

Or as C0lumbo reduced it even further:

side = sqrt(2) * r

side = 1.414213 * r