import java.util.*; public class Main { public static void main (String[] args) { Scanner sc = new Scanner(System.in); int n = sc.nextInt(); if (n == 1) { System.out.println(0); return; } else if (n == 2) { System.out.println(4); return; } long total = n + n - 1; long left = 2; long right = n; if (n % 2 == 1) { while (right - left > 1) { total += left * right + left * (right - 2); left++; right--; } total += left * right; } else { while (right - left > 2) { total += left * right + left * (right - 2); left++; right--; } total += left * right + left * (right - 1); } System.out.println(total); } }