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

建议使用的浏览器:

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

3474:Ellipsoid

Special Judge 特殊评判
题目描述

Given a set of points randomly sampled following a uniform distribution from the interior of a 3D ellipsoid to a certain density, can you recover the directions of the ellipsoid’s principal axes?

输入解释

The input consists of multiple lines. The first line contains only an integer N (1000 ≤ N ≤ 5000). Then come N lines, each containing three real numbers xi, yi, zi, the coordinate of a sample point in the Cartesian system.

The points are sampled from the interior of an ellipsoid the lengths of whose principal axes are a, b, c (0 < a, b, c < 1) such that a ≥ 1.2b, b ≥ 1.2c. The ellipsoid may be rotated and translated, and its center lies inside the unit sphere centered at the origin.

输出解释

Output as accurate as necessary three nonzero vectors indicating the directions of the ellipsoid's principal axes. The first line should contain that of the a-axis, the second line that of the b-axis, and the third line that of the c-axis. You do not have to elaborate on accuracy. For each axis you are allowed a margin of 2.5 degrees of deviation from the parameters used to define the ellipsoid.

输出样例
0.999960540723704 0.00851802271079874 0.00252196047877843
-0.00851856901599733 0.999963695122878 0.000205956596999169
0.00252011457634247 0.000227431964495135 -0.999996798643488
提示

When testing your solution against the sample test case, you should compare your result with the naïve orthonormal basis

1 0 0
0 1 0
0 0 1

Try to figure out subtle methods aimed solely at passing the test cases.


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

源链接: POJ-3474

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

共提交 0

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