#include <bits/stdc++.h>
using namespace std;
#pragma GCC optimize("Ofast")
#pragma GCC optimize("unroll-loops")
#pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,tune=native")
const int inf = 1000000;
const double eps = 1e-12;
void solve() {
  cout << fixed << setprecision(10);
  int n, r;
  cin >> n >> r;
  double pi = 2 * acos(0);
  double sn = sin(pi / n);
  double ans = (sn * (double)r) / ((double)1 - sn);
  cout << ans << "\n";
}
int main() {
  ios::sync_with_stdio(false);
  cin.tie(nullptr);
  solve();
}
