Let's denote:
The problem states:
For each box \(i\), the number of blue balls is equal to the total number of white balls in all other boxes:
\[ b_i = \sum_{j
eq i} w_j \]
For each box \(i\), the number of white balls is equal to the total number of red balls in all other boxes:
\[ w_i = \sum_{j
eq i} r_j \]
Let \(R\), \(B\), and \(W\) be the total number of red, blue, and white balls, respectively.
\[ R = \sum_{i=1}^4 r_i \]
\[ B = \sum_{i=1}^4 b_i \]
\[ W = \sum_{i=1}^4 w_i \]
The total number of balls is \(T = R + B + W\).
From the first condition:
\[ b_i = W - w_i \]
Summing over all \(i\):
\[ B = \sum_{i=1}^4 (W - w_i) = 4W - \sum_{i=1}^4 w_i = 4W - W = 3W \]
From the second condition:
\[ w_i = R - r_i \]
Summing over all \(i\):
\[ W = \sum_{i=1}^4 (R - r_i) = 4R - \sum_{i=1}^4 r_i = 4R - R = 3R \]
So, we have the relationships:
\[ B = 3W \]
\[ W = 3R \]
Substituting the second equation into the first:
\[ B = 3(3R) = 9R \]
The total number of balls is:
\[ T = R + B + W = R + 9R + 3R = 13R \]
We are given that the total number of balls \(T\) is even and less than 50.
\[ T = 13R < 50 \]
Since \(R\) must be a positive integer (number of balls), the possible values for \(R\) are:
If \(R = 1\), then \(T = 13 \times 1 = 13\) (odd, not valid).
If \(R = 2\), then \(T = 13 \times 2 = 26\) (even, and < 50, valid).
If \(R = 3\), then \(T = 13 \times 3 = 39\) (odd, not valid).
If \(R = 4\), then \(T = 13 \times 4 = 52\) (even, but > 50, not valid).
The only valid case is \(R = 2\), which gives \(T = 26\).
Let's check if we can find a distribution of balls for \(R=2\).
If \(R=2\), then \(W = 3R = 3 \times 2 = 6\).
And \(B = 3W = 3 \times 6 = 18\).
Total balls \(T = R + B + W = 2 + 18 + 6 = 26\).
Now we need to distribute these balls into 4 boxes such that the conditions are met.
Let's try to set \(r_1 = 2, r_2 = 0, r_3 = 0, r_4 = 0\). So \(R=2\).
Then for box 1: \(w_1 = R - r_1 = 2 - 2 = 0\).
For boxes 2, 3, 4: \(w_2 = R - r_2 = 2 - 0 = 2\), \(w_3 = R - r_3 = 2 - 0 = 2\), \(w_4 = R - r_4 = 2 - 0 = 2\).
Total white balls \(W = w_1 + w_2 + w_3 + w_4 = 0 + 2 + 2 + 2 = 6\). This matches \(W=6\).
Now let's check the blue balls.
For box 1: \(b_1 = W - w_1 = 6 - 0 = 6\).
For box 2: \(b_2 = W - w_2 = 6 - 2 = 4\).
For box 3: \(b_3 = W - w_3 = 6 - 2 = 4\).
For box 4: \(b_4 = W - w_4 = 6 - 2 = 4\).
Total blue balls \(B = b_1 + b_2 + b_3 + b_4 = 6 + 4 + 4 + 4 = 18\). This matches \(B=18\).
So, one possible distribution is:
Let's verify the conditions for Box 1:
Blue balls in Box 1 = 6.
White balls in other boxes = \(w_2 + w_3 + w_4 = 2 + 2 + 2 = 6\). (Condition met)
White balls in Box 1 = 0.
Red balls in other boxes = \(r_2 + r_3 + r_4 = 0 + 0 + 0 = 0\). (Condition met)
Let's verify the conditions for Box 2:
Blue balls in Box 2 = 4.
White balls in other boxes = \(w_1 + w_3 + w_4 = 0 + 2 + 2 = 4\). (Condition met)
White balls in Box 2 = 2.
Red balls in other boxes = \(r_1 + r_3 + r_4 = 2 + 0 + 0 = 2\). (Condition met)
The total number of balls is 26, which is even and less than 50.
Ответ: 26