import java.io.*; import java.util.*; public class Solution { public static void main(String[] args) throws IOException { InputReader in = new InputReader (System.in); long a = in.readLong (); long b = in.readLong (); long time = in.readLong (); a = a >>> 1; b = b >>> 1; int result = 0; for (long i=1; i<=time; i++) { result += (a*i)+(b*i); } System.out.println ((long)((result)%(Math.pow(10,9) + 7))); } static final class InputReader { private final InputStream stream; private final byte[] buf = new byte[1024]; private int curChar; private int numChars; public InputReader(InputStream stream) { this.stream = stream; } private int read() throws IOException { if (curChar >= numChars) { curChar = 0; numChars = stream.read(buf); if (numChars <= 0) { return -1; } } return buf[curChar++]; } public final int readInt() throws IOException { return (int)readLong(); } public final long readLong() throws IOException { int c = read(); while (isSpaceChar(c)) { c = read(); if (c == -1) throw new IOException(); } boolean negative = false; if (c == '-') { negative = true; c = read(); } long res = 0; do { res *= 10; res += c - '0'; c = read(); } while (!isSpaceChar(c)); return negative ? -res : res; } public final int[] readIntArray(int size) throws IOException { int[] array = new int[size]; for (int i=0; i