当前你的浏览器版本过低,网站已在兼容模式下运行,兼容模式仅提供最小功能支持,网站样式可能显示不正常。
请尽快升级浏览器以体验网站在线编辑、在线运行等功能。

建议使用的浏览器:

谷歌Chrome 火狐Firefox Opera浏览器 微软Edge浏览器 QQ浏览器 360浏览器 傲游浏览器

3596:Illuminated Planet

题目描述

A space probe is on a mission to observe a planetary system. It is instructed to shoot images of a planet, which orbits a star, using its optical camera. To ensure image quality, it must take the images only when a positive portion of the planet’s surface illuminated by the star is visible.

Given the positions and radii of the planet and the star, and the position of the space probe, determine whether images can be taken in this setting. You do not have to consider the situation that the planet is occulted by the star.

输入解释

The input contains a single test case. The first line contains four numbers (x, y, z) and r, the Cartesian coordinates of the planet and its radius. The second line contains four numbers (x, y, z) and r, the Cartesian coordinates of the star and its radius. The third line contains three numbers (x, y, z), the Cartesian coordinates of the space probe. The input is physically consistent.

输出解释

If images can be taken, print “Yes”; otherwise, print “No”.

输入样例
0 0 0 6.371e3
1.027e8 4.400e8 7.548e8 6.96e5
3.489e9 -1.036e10 -5.249e9
输出样例
Yes
提示

The sample uses the real physical setting of Earth, the Sun and the Voyager 2 space probe. Voyager 2 is located far south to the ecliptic and thus always has the illuminated side of Earth within its sight.


该题目是Virtual Judge题目,来自 北京大学POJ

源链接: POJ-3596

最后修改于 2020-10-29T07:05:39+00:00 由爬虫自动更新

共提交 0

通过率 --%
时间上限 内存上限
1000 131072