def solve(N, K, L):
    # If there's only one square
    if N == 1:
        return 4 * L * L
    
    # If squares are completely separated
    if K > 2 * L:
        return N * 4 * L * L
    
    # If squares overlap
    # Calculate the total area
    # Width is constant (2L)
    # Length is (N-1)*K + 2L (from leftmost edge to rightmost edge)
    length = (N - 1) * K + 2 * L
    width = 2 * L
    
    return length * width

def main():
    # Read input
    N, K, L = map(int, input().split())
    
    # Calculate and output result
    result = solve(N, K, L)
    print(result)

if __name__ == "__main__":
    main()