Alastair Cook dug in the opening half an hour to help England to a strong position early on