To solve the problem, we need to set up an equation based on the information given. Let's denote the number of coins given to the first son as \( X \) and the number of coins given to the second son as \( Y \).
### Step 1: Set up the equation based on the problem statement.
According to the problem, the difference between the squares of the two numbers is equal to 36 times the difference between the two numbers. This can be expressed mathematically as:
\[
X^2 - Y^2 = 36(X - Y)
\]
### Step 2: Factor the left-hand side of the equation.
The left-hand side \( X^2 - Y^2 \) can be factored using the difference of squares formula:
\[
(X - Y)(X + Y) = 36(X - Y)
\]
### Step 3: Simplify the equation.
Assuming \( X \neq Y \) (since they are different numbers), we can divide both sides of the equation by \( (X - Y) \):
\[
X + Y = 36
\]
### Step 4: Express one variable in terms of the other.
From the equation \( X + Y = 36 \), we can express \( Y \) in terms of \( X \):
\[
Y = 36 - X
\]
### Step 5: Substitute \( Y \) back into the difference of squares.
Now, we can substitute \( Y \) back into the original equation to find the values of \( X \) and \( Y \):
\[
X^2 - (36 - X)^2 = 36(X - (36 - X))
\]
### Step 6: Expand and simplify the equation.
Expanding both sides gives:
\[
X^2 - (1296 - 72X + X^2) = 36(2X - 36)
\]
This simplifies to:
\[
X^2 - 1296 + 72X - X^2 = 72X - 1296
\]
### Step 7: Rearranging the equation.
Now, we can rearrange the equation:
\[
72X - 1296 = 72X - 1296
\]
This equation holds true for all values of \( X \) and \( Y \) that satisfy \( X + Y = 36 \).
### Step 8: Find possible integer pairs for \( X \) and \( Y \).
Since \( X \) and \( Y \) must be positive integers, we can list the pairs:
- \( (1, 35) \)
- \( (2, 34) \)
- \( (3, 33) \)
- \( (4, 32) \)
- \( (5, 31) \)
- \( (6, 30) \)
- \( (7, 29) \)
- \( (8, 28) \)
- \( (9, 27) \)
- \( (10, 26) \)
- \( (11, 25) \)
- \( (12, 24) \)
- \( (13, 23) \)
- \( (14, 22) \)
- \( (15, 21) \)
- \( (16, 20) \)
- \( (17, 19) \)
- \( (18, 18) \)
### Step 9: Calculate the total number of coins.
The total number of coins \( X + Y = 36 \).
### Conclusion:
The old man had a total of 36 coins.