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

建议使用的浏览器:

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

3962:Dome of Circus

Special Judge 特殊评判
题目描述
A travelling circus faces a tough challenge in designing the dome for its performances. The circus has a number of shows that happen above the stage in the air under the dome. Various rigs, supports, and anchors must be installed over the stage, but under the dome. The dome itself must rise above the center of the stage and has a conical shape. The space under the dome must be air-conditioned, so the goal is to design the dome that contains minimal volume.
You are given a set of n points in the space; (xi, yi, zi) for 1 <= i <= n are the coordinates of the points in the air above the stage that must be covered by the dome. The ground is denoted by the plane z = 0, with positive z coordinates going up. The center of the stage is on the ground at the point (0, 0, 0).
The tip of the dome must be located at some point with coordinates (0, 0, h) with h > 0. The dome must have a conical shape that touches the ground at the circle with the center in the point (0, 0, 0) and with the radius of r. The dome must contain or touch all the n given points. The dome must have the minimal volume, given the above constraints.

输入解释
The first line of the input file contains a single integer number n (1 <= n <= 10 000) — the number of points under the dome. The following n lines describe points with three floating point numbers xi, yi, and zi per line — the coordinates of i-th point. All coordinates do not exceed 1000 by their absolute value and have at most 2 digits after decimal point. All zi are positive. There is at least one point with non-zero xi or yi.
输出解释
Write to the output file a single line with two floating point numbers h and r — the height and the base radius of the dome. The numbers must be precise up to 3 digits after decimal point.
输入样例
#1 1
1.00 0.00 1.00
#2 2
1.00 0.00 1.00
0.00 1.50 0.50
#3 3
1.00 0.00 1.00
0.00 1.50 0.50
-0.50 -0.50 1.00
输出样例
#1 3.000 1.500
#2 2.000 2.000
#3 2.000 2.000

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

源链接: POJ-3962

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

共提交 0

通过率 --%
时间上限 内存上限
3000 65536