// Slower C++ solution:
#include <bits/stdc++.h>

using namespace std;

using ll = long long;

using ull = unsigned long long;

#define FOR(i, j, k, in) for (int i = j; i < k; i += in)

#define RFOR(i, j, k, in) for (int i = j; i >= k; i -= in)

#define REP(i, j) FOR(i, 0, j, 1)

#define RREP(i, j) RFOR(i, j, 0, 1)



namespace prime {



using u64 = uint64_t;

using u32 = uint32_t;

// using u128 = __uint128_t;



u64 binpower(u64 base, u64 e, u64 mod) {

    u64 result = 1;

    base %= mod;

    while (e) {

        if (e & 1)

            result = (u64)result * base % mod;

        base = (u64)base * base % mod;

        e >>= 1;

    }

    return result;

}



bool check_composite(u64 n, u64 a, u64 d, int s) {

    u64 x = binpower(a, d, n);

    if (x == 1 || x == n - 1)

        return false;

    for (int r = 1; r < s; r++) {

        x = (u64)x * x % n;

        if (x == n - 1)

            return false;

    }

    return true;

};



bool miller_rabin(u64 n, int iter = 5) {  // returns true if n is probably prime, else returns false.

    if (n < 4)

        return n == 2 || n == 3;



    int s = 0;

    u64 d = n - 1;

    while ((d & 1) == 0) {

        d >>= 1;

        s++;

    }



    for (int i = 0; i < iter; i++) {

        int a = 2 + rand() % (n - 3);

        if (check_composite(n, a, d, s))

            return false;

    }

    return true;

}



vector<u32> primes, lp;



void init_primes(u64 N) {

    lp.resize(N + 1, 0), primes.clear();

    for (u64 i = 2; i <= N; ++i) {

        if (lp[i] == 0) {

            lp[i] = i;

            primes.push_back(i);

        }

        for (int j = 0; j < (int)primes.size() && primes[j] <= lp[i] && i * primes[j] <= N; ++j)

            lp[i * primes[j]] = primes[j];

    }

}



unordered_map<u64, u64> factorize(u64 x) {

    unordered_map<u64, u64> ret;

    if (x > lp.size()) {

        u64 pc = primes.size();

        for (u64 j = 1; j < pc + 1; j++) {

            while (x % primes[pc - j] == 0) {

                ret[primes[pc - j]]++;

                x /= primes[pc - j];

            }

            if (x <= lp.size()) break;

        }

    }

    if (x > lp.size()) {

        ret[x]++;

        return ret;

    }

    while (x != 1) {

        ret[lp[x]]++;

        x /= lp[x];

    }



    return ret;

}



void _rec_divisors(const vector<pair<u64, u64>> &factors, int index, u64 curr, vector<u64> &ret) {

    int n = factors.size();

    if (index == n) {

        ret.push_back(curr);

        return;

    }



    u64 base = factors[index].first, exp = factors[index].second;

    for (u64 i = 0; i <= exp; i++) {

        _rec_divisors(factors, index + 1, curr, ret);

        curr *= base;

    }

}



vector<u64> divisors(u64 x) {

    if (x == 1) return {1};

    auto factor_map = factorize(x);

    vector<pair<u64, u64>> factors;

    for (const auto &el : factor_map) {

        factors.emplace_back(el.first, el.second);

    }

    vector<u64> ret;

    _rec_divisors(factors, 0, 1, ret);

    return ret;

}



vector<u64> divisor_count;



void init_divisor_count(u64 size) {

    divisor_count.resize(max((u64)2, size));

    divisor_count[1] = 1;

    FOR(i, 2, size, 1) {

        if (lp[i] == i) {

            divisor_count[i] = 2;

        } else {

            u64 count = 1;

            u64 curr = i / lp[i];

            while (curr % lp[i] == 0) {

                count++;

                curr /= lp[i];

            }

            divisor_count[i] = divisor_count[curr] * (count + 1);

        }

    }

}



}  // namespace prime



int main() {

    ios_base::sync_with_stdio(false);

    cin.tie(NULL);

    cout.tie(NULL);

    prime::u64 n;

    cin >> n;

    prime::init_primes(n + 1);

    prime::init_divisor_count(n + 1);

    prime::u64 total = 0;

    for (prime::u64 i = 1; i <= n; i++) {

        total += i * prime::divisor_count[i];

    }

    cout << total << endl;

}

// Faster C++ solution for the same problem (measured speedup: 2.923787289596822x):
#include <bits/stdc++.h>

using namespace std;

using ll = long long;

using ull = unsigned long long;

#define FOR(i, j, k, in) for (int i = j; i < k; i += in)

#define RFOR(i, j, k, in) for (int i = j; i >= k; i -= in)

#define REP(i, j) FOR(i, 0, j, 1)

#define RREP(i, j) RFOR(i, j, 0, 1)



ll range_sum(ll low, ll high) {

    if (low > high) return 0ll;

    if (low == high) return low;

    if (low == 1ll) return (high * (high + 1)) / 2;

    return (high * (high + 1)) / 2 - ((low - 1) * low) / 2;

}



int main() {

    ios_base::sync_with_stdio(false);

    cin.tie(NULL);

    cout.tie(NULL);

    ll n;

    cin >> n;

    ll d = (ll)floor(sqrt(n));

    ll total = 0;

    for (ll i = 1; i <= d; i++) {

        ll count = n / i;

        total += range_sum(1, count) * i;      // i + 2*i + ... + k*i <= n  i.e. counting where i contributes to

        total += range_sum(d + 1, count) * i;  // (d + 1)*i + ... + k*i <= n i.e. counting where the numbers bigger than d contribute to with i.

    }

    cout << total << endl;

}