Anonymous User

# How would you find the equation on mathematica

Anonymous User
Posted 9 years ago
3282 Views
|
|
1 Total Likes
|
 Find the equation of a circle that contains points (4,-3),(-4,5), and (-2,7)
 Hi, what about this? First we generate a list of the points: points = {{4, -3}, {-4, 5}, {-2, 7}} Then we generate the equations: Table[(x - a)^2 + (y - b)^2 == R^2 /. {x -> points[[i, 1]], y -> points[[i, 2]]}, {i, 1, 3}] which gives {(4 - a)^2 + (-3 - b)^2 == R^2, (-4 - a)^2 + (5 - b)^2 == R^2, (-2 - a)^2 + (7 - b)^2 == R^2} Note that we used the general form of the equation that generates a circle. These determine the unknowns $a,b,R$. sols = Solve[Table[(x - a)^2 + (y - b)^2 == R^2 /. {x -> points[[i, 1]], y -> points[[i, 2]]}, {i, 1, 3}], {a, b, R}] That gives {{a -> 1, b -> 2, R -> -Sqrt[34]}, {a -> 1, b -> 2, R -> Sqrt[34]}} It is easy to check that the circle ((x - a)^2 + (y - b)^2 == R^2 /. sols[[2]]) which is (-1 + x)^2 + (-2 + y)^2 == 34 fulfils the conditions: Table[((x - a)^2 + (y - b)^2 == R^2 /. sols[[2]]) /. {x -> points[[i, 1]], y -> points[[i, 2]]}, {i, 1, 3}] evaluates to {True, True, True} Cheers,Marco