import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		int N = scan.nextInt();
		int L = scan.nextInt();
		//math.abs()
		double avg = 0.5 * (2 * L + N - 1);
		int[] apples = new int[N + 1];
		int sum = (int) (0.5 * N * (2 * L + N - 1));
		int min = 10000;
		for (int i = 1; i <=N; i++) {
			apples[i] = L + i - 1;
			if (Math.abs(apples[i]) < Math.abs(min)) {
				min = apples[i];
			}
		}
		System.out.println(sum - min);
	}
} import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		int N = scan.nextInt();
		int L = scan.nextInt();
		//math.abs()
		double avg = 0.5 * (2 * L + N - 1);
		int[] apples = new int[N + 1];
		int sum = (int) (0.5 * N * (2 * L + N - 1));
		int min = 10000;
		for (int i = 1; i <=N; i++) {
			apples[i] = L + i - 1;
			if (Math.abs(apples[i]) < Math.abs(min)) {
				min = apples[i];
			}
		}
		System.out.println(sum - min);
	}
} Main public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		int N = scan.nextInt();
		int L = scan.nextInt();
		//math.abs()
		double avg = 0.5 * (2 * L + N - 1);
		int[] apples = new int[N + 1];
		int sum = (int) (0.5 * N * (2 * L + N - 1));
		int min = 10000;
		for (int i = 1; i <=N; i++) {
			apples[i] = L + i - 1;
			if (Math.abs(apples[i]) < Math.abs(min)) {
				min = apples[i];
			}
		}
		System.out.println(sum - min);
	} main {
		Scanner scan = new Scanner(System.in);
		int N = scan.nextInt();
		int L = scan.nextInt();
		//math.abs()
		double avg = 0.5 * (2 * L + N - 1);
		int[] apples = new int[N + 1];
		int sum = (int) (0.5 * N * (2 * L + N - 1));
		int min = 10000;
		for (int i = 1; i <=N; i++) {
			apples[i] = L + i - 1;
			if (Math.abs(apples[i]) < Math.abs(min)) {
				min = apples[i];
			}
		}
		System.out.println(sum - min);
	} Scanner scan = new Scanner(System.in); scan new Scanner(System.in) int N = scan.nextInt(); N scan.nextInt() scan.nextInt scan int L = scan.nextInt(); L scan.nextInt() scan.nextInt scan double avg = 0.5 * (2 * L + N - 1); avg 0.5 * (2 * L + N - 1) 0.5 (2 * L + N - 1) 2 * L + N 2 * L 2 L N 1 int[] apples = new int[N + 1]; apples new int[N + 1] N + 1 N 1 int sum = (int) (0.5 * N * (2 * L + N - 1)); sum (int) (0.5 * N * (2 * L + N - 1)) 0.5 * N * (2 * L + N - 1) 0.5 N (2 * L + N - 1) 2 * L + N 2 * L 2 L N 1 int min = 10000; min 10000 for (int i = 1; i <=N; i++) {
			apples[i] = L + i - 1;
			if (Math.abs(apples[i]) < Math.abs(min)) {
				min = apples[i];
			}
		} int i = 1; int i = 1; i 1 i <=N i N i++ i++ i {
			apples[i] = L + i - 1;
			if (Math.abs(apples[i]) < Math.abs(min)) {
				min = apples[i];
			}
		} {
			apples[i] = L + i - 1;
			if (Math.abs(apples[i]) < Math.abs(min)) {
				min = apples[i];
			}
		} apples[i] = L + i - 1 apples[i] apples i L + i - 1 L + i L i 1 if (Math.abs(apples[i]) < Math.abs(min)) {
				min = apples[i];
			} Math.abs(apples[i]) < Math.abs(min) Math.abs(apples[i]) Math.abs Math apples[i] apples i Math.abs(min) Math.abs Math min {
				min = apples[i];
			} min = apples[i] min apples[i] apples i System.out.println(sum - min) System.out.println System.out System System.out sum - min sum min String[] args args public class Main {
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		int N = scan.nextInt();
		int L = scan.nextInt();
		//math.abs()
		double avg = 0.5 * (2 * L + N - 1);
		int[] apples = new int[N + 1];
		int sum = (int) (0.5 * N * (2 * L + N - 1));
		int min = 10000;
		for (int i = 1; i <=N; i++) {
			apples[i] = L + i - 1;
			if (Math.abs(apples[i]) < Math.abs(min)) {
				min = apples[i];
			}
		}
		System.out.println(sum - min);
	}
} public class Main {
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		int N = scan.nextInt();
		int L = scan.nextInt();
		//math.abs()
		double avg = 0.5 * (2 * L + N - 1);
		int[] apples = new int[N + 1];
		int sum = (int) (0.5 * N * (2 * L + N - 1));
		int min = 10000;
		for (int i = 1; i <=N; i++) {
			apples[i] = L + i - 1;
			if (Math.abs(apples[i]) < Math.abs(min)) {
				min = apples[i];
			}
		}
		System.out.println(sum - min);
	}
} Main
import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		int N = scan.nextInt();
		int L = scan.nextInt();
		//math.abs()
		double avg = 0.5 * (2 * L + N - 1);
		int[] apples = new int[N + 1];
		int sum = (int) (0.5 * N * (2 * L + N - 1));
		int min = 10000;
		for (int i = 1; i <=N; i++) {
			apples[i] = L + i - 1;
			if (Math.abs(apples[i]) < Math.abs(min)) {
				min = apples[i];
			}
		}
		System.out.println(sum - min);
	}
}
