I had a buick that would do that, and it turned out to be a bad computer chip. THe main chip also controlled the cruise control, and when the chip went south, so did the cruise. Also, I've had this happen on another car when a vaccum line was leaking. The cruise control uses vaccum to set the speed and accelerate, etc. I don't know if the x would have these type of systems, but a vaccum check is pretty easy, anyway, and a computer check can be free at some auto parts stores. Hope you find the problem, I don't want to drive behind you if you keep speeding up and slowing down!