Problem ATriangle Fun Input: Standard Input Output: Standard Output In the picture below you can see a triangle ABC. Point D, E and F divides the sides BC, CA and AB into ratio 1:2 respectively. That is CD=2BD, AE=2CE and BF=2AF. A, D; B, E and C, F…
POJ_1269_Intersecting Lines_求直线交点 Description We all know that a pair of distinct points on a plane defines a line and that a pair of lines on a plane will intersect in one of three ways: 1) no intersection because they are parallel, 2) intersect in…
题目传送门 题意:三角形三等分点连线组成的三角形面积 分析:入门题,先求三等分点,再求交点,最后求面积.还可以用梅涅劳斯定理来做 /************************************************ * Author :Running_Time * Created Time :2015/10/22 星期四 12:55:27 * File Name :UVA_11437.cpp *********************************************…
http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&page=show_problem&problem=2432 题目大意: 如图,定义三角形ABC,在BC,CA,AB上分别取边D,E,F,使得CD=2BD,AE=2CE,BF=2AF,求三角形PQR的面积. 思路: 先求出D,E,F三点坐标,然后求出PQR三点坐标,最后对pr,pq进行叉乘,所得的一般即为答案. #include<cstdi…
计算几何: 直线交点: #include<cstdio> using namespace std; struct node { double x,y; node(,):x(x),y(y){ } }a,b,c,d,e,f,p,q,r; node operator-(node u,node v){return node(u.x-v.x,u.y-v.y);} node operator+(node u,node v){return node(u.x+v.x,u.y+v.y);} node opera…
http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=9 题意: Morlery定理是这样的:作三角形ABC每个内角的三等分线.相交成三角形DEF.则DEF为等边三角形,你的任务是给你A,B,C点坐标求D,E,F的坐标 思路: 根据对称性,我们只要求出一个点其他点一样:我们知道三点的左边即可求出每个夹角,假设求D,我们只要将向量BC 旋转rad/3的到直线BD,然后旋转向量CB然后得到CD,然后就是求两直线的交点了.…
Mirror and Light Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 650    Accepted Submission(s): 316 Problem Description The light travels in a straight line and always goes in the minimal path b…
题目:http://poj.org/problem?id=1269 相关知识: 叉积求面积:https://www.cnblogs.com/xiexinxinlove/p/3708147.html什么是叉积:https://blog.csdn.net/sunbobosun56801/article/details/78980467        其二维:https://blog.csdn.net/qq_38182397/article/details/80508303计算交点:    方法1:面…
public class Fan { public static void main(String[] args) { Fan fan1 = new Fan(), fan2 = new Fan(); fan1.modifySpeed(FAST); fan1.modifyRadius(10); fan1.modifyColor("yellow"); fan1.modifyOn(true); System.out.println(fan1.toString()); fan2.modifyS…
这个月月初我们一行三人去湖南参加了ccpc湖南程序设计比赛,虽然路途遥远,六月的湘潭天气燥热,不过在一起的努力之下,拿到了一块铜牌,也算没空手而归啦.不过通过比赛,还是发现我们的差距,希望这几个月自己努力思考,积极刷题,为九月份acm网络赛做准备! 言归正传说说这道题目,这也是这次比赛想到AC比较高的题目,不过我们还是没能完成,下面我就来总结一下此题的一些思路和方法. Magic Triangle Problem Description: Huangriq is a respectful acm…