#P10182. 一径入繁华
一径入繁华
Background

Along with the Year of the Dragon, there comes the nine-province joint mock exam that Fanju really likes. In order to completely crush the final problem, Fanju seriously reviewed number theory again.
Where number theory is born, there lies a land of prosperity.
Problem Description
Fanju thinks computing the value of modulo is too easy, so he wants to compute the value of modulo .
Fanfan is not satisfied with computing it only once, so he wrote an number table , guaranteeing that the element in row and column () satisfies:
$$a_{i,j}=\sum_{d\mid \gcd(i,j)}\mu\left(\dfrac{\gcd(i,j)}{d}\right)\times (\sigma_0(d^s))^t$$Fanfan wants to know what this number table looks like, but it is far too large. So please tell him the value of modulo .
Notes:
- The meanings of the functions in the expression are explained here ( denotes the Möbius function, and denotes the divisor-counting function).
- denotes the determinant of the square matrix .
Input Format
One line with three integers .
Output Format
One line with one integer representing the answer.
2 1 2
2
2 3 4
254
19 8 10
913255725
10000000000 1 2
880793261
Hint
Sample Explanation
Matrix is:
Its determinant is .
Sample Explanation
Matrix is:
Its determinant is .
Constraints
This problem uses bundled subtasks.
For of the testdata, it is guaranteed that , .
| Subtask ID | Special Property | Score | |
|---|---|---|---|
| Subtask #1 | None | ||
| Subtask #2 | |||
| Subtask #3 | |||
| Subtask #4 | |||
| Subtask #5 | |||
| Subtask #6 | |||
| Subtask #7 | |||
| Subtask #8 | |||
| Subtask #9 | None | ||
| Subtask #10 |
If the “Special Property” column is empty, it means there is no special property. For variables whose ranges are not specified in a subtask, their values are generated within .
Time limit: .
Memory limit: .
Translated by ChatGPT 5