#include "stdafx.h"
#include
using namespace std;
double fact(int n)
{
if (n == 0) return 1;
double res=1;
for (int i = 1; i <= n; i++)</span>
res = res*i;
return res;
}
int main()
{
double prev, act, fun = 0, x,eps;
cin >> x;
cin >> eps;
int n = 0;
prev = (pow(-1,n)*(pow(3, 2 * n) + 3)*pow(x, 2 * n) / fact(2 * n))/4;
n++;
act = prev + (pow(-1, n)*(pow(3, 2 * n) + 3)*pow(x, 2 * n) / fact(2 * n)) / 4;
while (abs(prev - act) > eps)
{
prev = act;
n++;
act = prev + (pow(-1, n)*(pow(3, 2 * n) + 3)*pow(x, 2 * n) / fact(2 * n))/ 4;
}
double b = sqrt(abs((act*act - pow(pow(cos(x), 3),2))));
return 0;
}