Two polygons are given at the entrance (the coordinates of the vertices of these polygons are listed in the order of their traversal; however, the traversal order for different polygons can be chosen different). Is it possible to convert one polygon into another using only parallel translation and proportional scaling?
1 answer
Find some vertex supposedly common to both polygons (maximum or minimum along the coordinates)
Make the transfer of one polygon so that these vertices lie on one point
Scaling so that the neighboring point matches the corresponding point of another polygon.
Check whether the other points match. If they match, you can; no, you can't.
- It's good that the problem does not say about the turn) - Kromster
|
[..., [L_i, theta_i], ...]
, whereL_i
is the length of thei
th edge,theta_i
is the angle of rotation of the next (i+1
-th) edge regarding this (i
th). After that, the lists (with accuracy up to cyclic permutation or otherwise, depending on how the traversal order is changed) compare: the angles should be the same, and the ratio of edge lengths is constant for all comparisons. - ⷶ ⷩ ⷮ ⷪ ⷩ