Group Abstract Group Abstract

Message Boards Message Boards

0
|
763 Views
|
8 Replies
|
3 Total Likes
View groups...
Share
Share this post:

Solve geometric quantities using GeometricScene

Posted 2 months ago

I constructed the following GeometricScene with parameters {s,r}. The scene consists of a circle of radius r, and an equilateral triangle {a,b,c} inscribed in the circle. s being the length of one side of the triangle. I want to calculate the value of s, dependent on the value of r.

scene=GeometricScene[{{a,b,c,o},{s,r}},{CircleThrough[{a,b,c},o,r],GeometricAssertion[Triangle[{a,b,c}],"Equilateral"],s==TriangleMeasurement[{a,b,c},"Perimeter"]}];
RandomInstance[scene]
s/.%["Quantities"]

It returns 4.41219 as the value of s. I'm guessing behind the scenes, Mathematica chose a value for r and use that value for s. Is there any way to get an analytical solution of s dependent on r?

POSTED BY: Xiangyang Zhou
8 Replies

Eliminate gives necessary conditions, not always sufficient. Try this:

GeometricScene[{{a, b, c, o}, {s, r}}, {CircleThrough[{a, b, c}, o, r],
    GeometricAssertion[Triangle[{a, b, c}], "Equilateral"], 
   s == TriangleMeasurement[{a, b, c}, "Perimeter"], 
   s != 3 Sqrt[3] r}]["Conclusions"]
POSTED BY: Gianluca Gorni
Posted 2 months ago
POSTED BY: Xiangyang Zhou
Posted 2 months ago
POSTED BY: Xiangyang Zhou

"Quantities" gave the values for the particular instance of the scene found by RandomInstance. You can use GeometricSolveValues on the abstract scene instead:

scene = GeometricScene[{{a, b, c, o}, {s, 
     r}}, {CircleThrough[{a, b, c}, o, r], 
    GeometricAssertion[Triangle[{a, b, c}], "Equilateral"], 
    s == TriangleMeasurement[{a, b, c}, "Perimeter"]}];

GeometricSolveValues[scene, s]

{ConditionalExpression[s, 
  Sqrt[(Indexed[a, {1}] - Indexed[b, {1}])^2 + (Indexed[a, {2}] - 
        Indexed[b, {2}])^2] + 
     Sqrt[(Indexed[a, {1}] - Indexed[c, {1}])^2 + (Indexed[a, {2}] - 
        Indexed[c, {2}])^2] + 
     Sqrt[(Indexed[b, {1}] - Indexed[c, {1}])^2 + (Indexed[b, {2}] - 
        Indexed[c, {2}])^2] == 
    s && (Indexed[a, {1}] - Indexed[b, {1}])^2 + (Indexed[a, {2}] - 
       Indexed[b, {2}])^2 == (Indexed[b, {1}] - 
       Indexed[c, {1}])^2 + (Indexed[b, {2}] - 
       Indexed[c, {2}])^2 == (Indexed[a, {1}] - 
       Indexed[c, {1}])^2 + (Indexed[a, {2}] - 
       Indexed[c, {2}])^2 && (Indexed[a, {1}] - 
       Indexed[o, {1}])^2 + (Indexed[a, {2}] - 
       Indexed[o, {2}])^2 == (Indexed[b, {1}] - 
       Indexed[o, {1}])^2 + (Indexed[b, {2}] - 
       Indexed[o, {2}])^2 == (Indexed[c, {1}] - 
       Indexed[o, {1}])^2 + (Indexed[c, {2}] - Indexed[o, {2}])^2 == 
    r^2 && r > 0]}

GeometricSolveValues output for abstract scene

POSTED BY: Ian Ford

You can check that s == r*Sqrt[3] is not a solution this way:

sols = Reduce[Most[eqs] && s == r*Sqrt[3]] // Reduce
Implies[sols, r == 0] // Reduce
POSTED BY: Gianluca Gorni
POSTED BY: Gianluca Gorni
Posted 2 months ago
POSTED BY: Xiangyang Zhou

This may be a start:

eqs = scene["AlgebraicFormulation"]
Eliminate[Most[eqs], Cases[eqs, _Indexed, All]]
Solve[%, r]
POSTED BY: Gianluca Gorni
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard