Lewis Hamilton is prepared to hit the books over the next few days in a bid to get an edge on Mercedes team-mate Nico Rosberg.

Hamilton and Rosberg conjured up a stunning battle in Sunday's Bahrain Grand Prix, with the Briton producing a brilliant defensive performance over the closing laps to hold off the German and claim back-to-back wins for the first time in four years.

Hamilton, however, has revealed how Rosberg studied up on him ahead of the race under the newly installed lights at the Bahrain International Circuit after the 2008 world champion had thoroughly dominated the previous Sunday's event in Malaysia.

"Someone in the team did a huge study on my pace in Malaysia, and as we arrived in Bahrain Nico had this big document showing all the places where I was quick, and he used that to his advantage," Hamilton revealed.

"So now I'll do the same and hopefully I can capitalise.

"I have to study hard, work hard, over these next two weeks. I'm going to be giving it a lot of digestion.

"But what an incredible team this is with their determination, putting the car together, taking it apart, pit stops...they are just faultless.

"Naturally, we are going to be on the limit, and every now and again we will all make mistakes, but I'm very, very proud to be working with these people."

Hamilton's skills were put to the test when, holding a comfortable lead over Rosberg, a crash involving Pastor Maldonado and Esteban Gutierrez brought the safety car into play.

Both Mercedes drivers pitted for a second time in the race, with Hamilton forced to take on medium tyres while Rosberg went to the slightly quicker softs, so it appeared that the advantage was with the German.

"When the safety car came out and he switched to options and I was on primes, I thought 'Shoot, it's going to take a miracle for me to hold him back' because there were six-tenths between those tyres," the British driver added.

"And he had so much grip behind me. It felt like one of the best calculated races I've had, how I was using my power, how I was positioning my car.

"He would catch me down the back straight and then stick with me into the first corner, and he had 10k on me.

"I had to accept he was going to come past, so I couldn't go to the inside and block.

"I had to move a little bit to make him think I would, then move back and accept he was going to come back, but I had to get back.

"I don't know how I did it all the time, but I did it. It's important, but it's also the most satisfying experience."

Hamilton is often portrayed as the more instinctive of the Mercedes duo, with Rosberg characterised as being stronger in terms of race strategy and preparation.

But the former McLaren racer insisted he put in plenty of homework before the race in Bahrain.

"I worked so hard over the weekend. I stayed extra, extra long after qualifying on Saturday to find every little detail because I knew I didn't have the ultimate pace this week as I did in Malaysia," he said.

"You can't be the quickest at every single track. There are going to be tracks where someone gets it a bit better than you, and he was particularly strong there.

"When you have that kind of pressure on you, you want to make sure you are on the limit without making mistakes, and I didn't make any mistakes, so I couldn't be any happier."

The Mercedes duel demonstrated that the new era of Formula One could provide racing excitement, despite Ferrari president Luca Di Montezemolo criticising the lack of noise and the "taxi-driving" approach to saving on fuel during races.

Hamilton enjoyed the action but admitted it would be tough to sustain that sort of drama all the time.

"I don't think it will always be like that," he said.

"I hope there are more races like that, but not always like that because my career will be a lot shorter! Ho w much heart and energy you need to put races like that together, I don't know how you can go with it.

"I hope for the fans will see more and more of that throughout the pack, and that they saw it was great fun."

Hamilton admitted he and Rosberg were "on a knife edge" and, when asked whether they could race like that all season without hitting one another, replied: "W hen it's like that, the risk increases.

"Undoubtedly, we were on the limit, and maybe next time we'll come back a little, but I was not letting up this time.