#include <iostream>

using namespace std;
int pol(int h)
{
    int k = 0, s = h;
    while(h != 1){

        k+=h;
        h--;
    }
    return k + s;
}
int main()
{
    int h, w, k = 0;
    cin >> h >> w;
    k = h * w + pol(h) * w;
    cout << k;
    return 0;
}
