Research in math (and probablyI assume in general) is hard. It doesn't get better over time, but rather we seem to get used to the accompanying depression and angst.
When I feel down, I try to remind myself that I do math because I enjoy it, not because I want to be the best at it, and for some reason people continue to pay me money to do it. If they stop, I'll figure out something else. In the meantime, I get to think about problems that I love, even if the process of that thinking isn't always fun.
The above is also hard. There are still rough days. It helps me to know that other people, including really smart people doing great math, experience the same feelings.
If you want to switch fields, go ahead. But in general, any field will have someone (seemingly) faster than you - this is not personal, we all feel like this.
[Picture Credit: David Whittaker]
I would recommend reflecting upon why you are in mathematics in the first place. If you're in it because you love doing it, does it matter if someone else is a bit faster? There is plenty of mathematics to go around.