The five dimensional discrete fourier transform over a complex array where and is given by:
for .
Now comes your turn. For a given real coefficient , suppose
Please calculate the value of
where means the real part of a complex number and means the absolute value of a real number.
输入格式
The first line of the input contains an integer indicating the total number of test cases. For each test case, a line contains five integers where , and a float number with at most significant digits.
输出格式
For each test case, output the value with the precision of digits.