hahaha I was in this situation once, but not in exactly the same circumstance.
I could just ride it out until I clocked someone else saying their name, then forced myself to remember it. you, on the other hand, Mr. One-on-one, are most likely screwed.
Or you could try that tactic above.
Or you could devise a way to get her to write it down... subtly. Maybe compliment her handwriting and get her to write her number and name down in your diary or address book or something.
Edit:
Quote: all of the "tell her the truth" posts above me.
Yes, go for this first; but if you feel too much like you're going to piss her off, then do what I said above. But I'm going by the assumption you've known her a long time. A week or two is nothing to ask her name.
Say something like. "For some bizarre reason I keep thinking your name is X"... to ease into an apology and an answer.