Let the sum of rs 84,000 be divided between A and B in the ratio 4:3.
Thus, A's share = \( \frac{4}{7} \times 84000 = 48000 \), and B's share = \( \frac{3}{7} \times 84000 = 36000 \).
Let rs X be the amount added to each of their shares.
After adding rs X to each, the new shares become \( 48000 + X \) and \( 36000 + X \).
The new ratio is given as 5:4, so:
\[
\frac{48000 + X}{36000 + X} = \frac{5}{4}
\]
Cross-multiply to solve for \( X \):
\[
4 \times (48000 + X) = 5 \times (36000 + X)
\]
\[
192000 + 4X = 180000 + 5X
\]
\[
192000 - 180000 = 5X - 4X
\]
\[
12000 = X
\]
Thus, the value of \( X \) is rs 12,000.