Online JudgeProblem SetAuthorsOnline ContestsUser
Web Board
Home Page
F.A.Qs
Statistical Charts
Problems
Submit Problem
Online Status
Prob.ID:
Register
Update your info
Authors ranklist
Current Contest
Past Contests
Scheduled Contests
Award Contest
User ID:
Password:
  Register

先判共线再这样

Posted by frkstyc at 2005-07-22 00:00:13
In Reply To:请教一个计算几何的初级问题,CLRS 上的 判断点在线段上的函数 ON_SEGMENT(pi,pj,pk) 返回pk 是否在线段pipj上(详内) Posted by:sunmoonstar_love at 2005-07-21 23:58:30
>  
> 
>  ON-SEGMENT(pi,pj,pk)
> 
>   if min(xi,xj) <= xk <= max(xi,xj) and min(yi,yj) <= yk <= max(yi,yj)
> 
>   then return true;
> 
>   else return false;
> 
> 
> 他为什么这么写?我觉得这是判断点pk是否在以pipj为对角线的矩形内的函数?  请教,谢谢

Followed by:

Post your reply here:
User ID:
Password:
Title:

Content:

Home Page   Go Back  To top


All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator