看板ACMCLUB
标 题Re: [问题] 多边形面积
发信站批踢踢兔 (Mon Jan 31 18:27:24 2005)
转信站ptt!Group.NCTU!grouppost
※ 引述《[email protected] (got my nerve)》之铭言:
: ※ 引述《watershed (临界点)》之铭言:
: : 公式:http://acm.uva.es/p/v1/109.html
: : 输入一个n,代表n边形
: : 接着输入n个座标(x,y)
: : 求n边形面积( 必须是最小的面积 )
: : input:6
: : 40 20
: : 20 20
: : 20 40
: : 40 40
: : 30 30
: : 25 25
: : output: 250
: : 我想不出来怎麽将这6个座标排列完後,套用109下面的公式
: : 得到此多边形最小的面积
: convex hull??
: http://www.csie.ntu.edu.tw/~b91089/convexhull.pdf
: I did this just for fun, don't take it too serious.
Sorry, I misunderstood that.
It needs concave one.(40,40)-(30,30)-(40,20)-(25,25)-(20,20)-(20,40)-(40,40)
--
※ 发信站: 批踢踢兔(ptt2.cc)
◆ From: 61.225.211.231