[48 - x] = 2 x [39 - x]
2x - x = (39 x 2) - 48
x = 30
ie., when the husband was 48 - 30 = 18 the wife was 39 - 30 = 9 years old ie., husband: wife:: 2: 1.
similarly
[48 - x] = 4 x [39 - x]
4x - x = (39 x 4) - 48
3x = 108
x = 36.
ie., when the husband was 48 - 36 = 12 the wife was 39 - 36 = 3 years old ie., husband: wife:: 4: 1.