Problem 44386. Circumscribed Pentagon?
Can there be a mistake about the answer for the last test suite? y_correct is given as 3 so the case where all edges are tangent to circle but when I draw it I see a pentagon that does not touch the circle at all and it is clearly visible without zooming so I don't think error is less than 0.02. I find the answer as y=4 which I think is correct. Can you please check it?
I do believe that it was within the tolerance, though that last case did not touch the pentagon, as you mentioned. I slightly increased the radius in that test case to reduce the gap between the pentagon and circle.
Hi, goc3. Nice problem. I have one piece of feedback. I anticipated in a "Cody5:Hard" problem that the pentagon & circle couldn't be assumed to have the same centre if it weren't stated in the problem, but roughly they do seem to share a centre in the present Test Suite. If that is the case, then I suggest either explicitly mentioning it in the Problem Statement, or else adding more test cases where the shapes don't share a centre. An example of the latter would be a tiny circle centred midway along one of the edges of a large pentagon (correct answer 2, but would probably be misclassified if centres assumed equal). Regards, DIV
Agree with David.
Moreover it is not mentioned that pentagon is regular (didn't check all cases, but most of them are regular).
Solution CommentsShow comments
Problem Recent Solvers63
Compute a dot product of two vectors x and y
Relative ratio of "1" in binary number
Pernicious Anniversary Problem
Number of Even Elements in Fibonacci Sequence
More from this Author139
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!Start Hunting!