문제는 n 개 개체 사이의 n * n 거리를 알고, 위치를 얻는 방법입니다.
1. Put the first one, say a, at (0,0)
2. Put the second one b at (|b-a|, 0)
3. For the third one c, it is at the one of the two intersections of the two circles:
|p-a|=|c-a| and |p-b|=|c-b|.
Solve this system of quadratic equations using the well-known formula, choose
either of the solutions as the position of c.
4. For any other points p, do the same thing as we're done for c, but choose one of the
two solutions that is consistent with the distance |p-c|. And check the distance
between p and all previous points. If the check fails, return with failure.
어떤 종류의 조정을하고 계십니까? –
무언가가 물건을 무작위로 또는 임의로 배치하지 못하게합니까? 예 : 정적 또는 동적으로 안정적인 게재 위치를 찾고 있습니까? –
중력 시뮬레이션을 수행하려는 경우이를 n 바디 문제 또는 n 바디 시뮬레이션이라고합니다. 심지어 2-d에서도 n이 2보다 크면 분석적 해결책이 없을 것입니다. Wikipedia의 [N-body simulation] (http://en.wikipedia.org/wiki/N-body_simulation) 기사에서 이 문제에 대한 수치 적 해결책을 유도/구현합니다. –