Sometimes it is very obvious what went wrong in your relationship, but sometimes it isn't quite so clear. These situations can be very complicated, and the real issue may be deeper than it seems. Perhaps your girlfriend yelled at you a lot for forgetting to put the toilet seat down or some other mundane thing. But the real issue was probably that you never listened to her!
Before you can even think of trying to get back with her, you have to figure out the real reason why she was unhappy with the relationship in the first place.