def func(a0,d,n):
    an = a0 + (n - 1) * d
    return (a0 + an)/2*n

while True:
    try:
        a = int(input())
        b = func(2,3,a)
        print(int(b))
    except:
        break