import java.util.Scanner; public class Main { public static void main(String[] args) throws Exception { Scanner sc = new Scanner(System.in); long n = sc.nextLong(); long k = sc.nextLong(); sc.close(); long ans = 0; long end = (long) Math.sqrt(k); for (int i = 2; i <= end; i++) { if (k % i == 0) { long m1 = Math.min(i - 1, n); long v1 = Math.max(m1 - (i - 1 - m1), 0); long i2 = k / i; long m2 = Math.min(i2 - 1, n); long v2 = Math.max(m2 - (i2 - 1 - m2), 0); ans += v1 * v2; } } System.out.println(ans * 2); } }