L’s in a Circle

Packing problems are often very interesting. In this problem we will try to put five L’s in a circle. But before that we will try to define L-shape for this problem. We can divide a 2a × 2a square into four a × a squares as shown in figure 1. Now if we remove one of those smaller squares from the figure, the new shape we get is referred as L-shape or L in this problem. The length of the smaller sides of this shape is a. Figure 1: Defining L Figure 2: Packing 5 identical L’s in a circle of minimum radius Figure 2 shows how five identical Ls can be put into a circle of minimum possible radius (This is found by David Cantrell but not formally proved). Given the length of the smaller side a of an L, your job is to find the minimum possible radius of the circle in which five such L’s can be put in the fashion shown in figure 2. Input Input file contains at most 5000 lines of inputs. Each line contains a floating-point number a (0 < a < 10000). The meaning of a is given in the problem statement. This floating-point numbers should have 7 digits after the decimal point. Input is terminated by a line containing a − 1. This line should not be processed. Output For each line of input produce one line of output. This line contains a floating-point number R that denotes the Minimum possible radius of the desired circle. This value should have 10 digits after the decimal point. Errors less than max(10−9,10−9 ∗RJ) will be ignored. Here RJ is the value of R produced by judge solutions. Sample Input 0.0000010 0.0000001 -1

2/2 Sample Output 0.0000026406 0.0000002641