England beat India by 31 runs in first Test