h,r=map(float,input().split()) print(-8.245+6.807*h+7.073*3.1415926535898*r*2)