#Lutece2954. Ain 的集合
Ain 的集合
Migrated from Lutece 2954 Ain 的集合
All parts of this problem, including description, images, samples, data and checker, might be broken. If you find bugs in this problem, please contact the admins.
Description
很喜欢集合与求和。
定义:
$S(n,m)=\{x|n \ mod \ x + m\ mod \ x \ge x, x\in Z^+\}$
现在,他想知道
$f(n,m)=\sum_{i=1}^n\sum_{j=1}^m\sum_{k\in S(i,j)}\varphi(k)\gcd(i,j)$
的值,你能帮助 计算出上述式子的值吗?
由于答案可能很大,你只需要输出该值对 取模的结果即可。
Input
一行两个整数 ,代表所求式中的 。
Output
一行一个整数,代表 的值。
Samples
2 2
13
Constraints
Resources
2023 UESTC ICPC Training for Math