#include <bits/stdc++.h>
using namespace std;
const int N = 1e5 + 7;
__int128 C(__int128 n, __int128 m) {
  if (n < m) return 0;
  if (n - m < m) return C(n, n - m);
  __int128 ans = 1;
  for (__int128 i = n; i >= n - m + 1; i--) ans *= i;
  for (__int128 i = 1; i <= m; i++) ans /= i;
  return ans;
}
__int128 c0, c1;
__int128 check(__int128 mid, __int128 &sum) {
  sum = 0;
  __int128 cnt = 0;
  for (int y = 0; y <= 30; y++) {
    if (mid - y * c1 < 0) break;
    __int128 xx = (mid - y * c1) / c0, v = C(y + xx + 1, y + 1);
    cnt += v;
    sum += (y + 1) * C(y + xx + 1, y + 2) * c0 + y * c1 * v;
  }
  return cnt;
}
int main() {
  int n, C0, C1;
  scanf("%d%d%d", &n, &C0, &C1);
  c0 = C0, c1 = C1;
  if (c0 > c1) swap(c0, c1);
  if (c0 == 0) {
    printf("%lld\n", (long long)((n - 1) * (c0 + c1)));
    return 0;
  }
  __int128 l = 0, r = 1ll * 30 * c1;
  while (l < r) {
    __int128 mid = (l + r) / 2, sum, cnt;
    if ((cnt = check(mid, sum)) < n - 1)
      l = mid + 1;
    else
      r = mid;
  }
  __int128 sum;
  __int128 cnt = check(l - 1, sum);
  printf("%lld\n", (long long)(sum + l * (n - 1 - cnt) + (n - 1) * (c0 + c1)));
  return 0;
}
