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

建议使用的浏览器:

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

6901:August

Special Judge 特殊评判
题目描述
“Remember when I pulled up and said get in the car, and then cancelled my plans just in case you’d call, back when I was living for the hope of it all.”

After death by a thousand cuts, he found his love. He has two parameter a and b, and he wants to show his lover a piece of drawing bounded by the following math curves.

$$
\begin{cases}
y = \sqrt{a^2 - (x-a)^2} \\
y = \sqrt{a^2 - (x+a)^2} \\
y = \frac{2b}{\pi} \left( \arccos \left(\frac{x+a}{a}\right) - \pi \right) \\
y = \frac{2b}{\pi} \left( \arcsin \left(\frac{x-a}{a}\right) - \frac{\pi}{2} \right)
\end{cases}
$$

Now his lover wants to know the area bounded by the close curve. Can you tell him?
输入解释
The first line contains T (1 ≤ T ≤ 1000), the count of testcases.

Then the next T lines, each of them contains two integer a and b (1 ≤ a,b ≤ 1000).
输出解释
For each test case, output a number for the answer with an absolute or relative error of at most $10^{-4}$.

Precisely speaking, assume that your answer is a and and the jury’s answer is b, your answer will be considered correct if $\frac{|a-b|}{max\{1,|b|\}}$ ≤ $10^{-4}$, where max{x,y} means the maximum of x and y and |x| means the absolute value of x.
输入样例
2
3 4
1000 1000
输出样例
76.27433388
7141592.65358979

提示
August sipped away like a bottle of wine.

This is the rendered picture for the example.
来自杭电HDUOJ的附加信息
Recommend liuyiding

该题目是Virtual Judge题目,来自 杭电HDUOJ

源链接: HDU-6901

最后修改于 2021-06-22T18:18:47+00:00 由爬虫自动更新

共提交 4

通过率 25.0%
时间上限 内存上限
2000/1000MS(Java/Others) 262144/262144K(Java/Others)