¡@

Home 

python Programming Glossary: mostfar

python: Help to implement an algorithm to find the minimum-area-rectangle for given points in order to compute the major and minor axis length

http://stackoverflow.com/questions/13542855/python-help-to-implement-an-algorithm-to-find-the-minimum-area-rectangle-for-gi

yielding an area of 187.451 units. Note that the code uses mostfar to advance each index. The mx my parameters to mostfar tell.. mostfar to advance each index. The mx my parameters to mostfar tell it what extreme to test for as an example with mx my 1.. it what extreme to test for as an example with mx my 1 0 mostfar will try to maximize rx where rx is the rotated x of a point..

Python: implement a script in a function. Some suggestions

http://stackoverflow.com/questions/13553884/python-implement-a-script-in-a-function-some-suggestions

problem . The code develop by jwpat7 is import math def mostfar j n s c mx my # advance j to extreme point xn yn hull j 0 hull.. theta math.cos theta yC hull i 0 s hull i 1 c xP yP iP mostfar iP n s c 0 1 if i 0 iR iP xR yR iR mostfar iR n s c 1 0 xL yL.. i 1 c xP yP iP mostfar iP n s c 0 1 if i 0 iR iP xR yR iR mostfar iR n s c 1 0 xL yL iL mostfar iL n s c 1 0 area yP yC xR xL..