"[T]a-pocketa-pocketa-pocketa-pocketa-pocketa" is an example of what's called onomatopoeia. This can be defined as a word or expression that imitates, resembles, or suggests the sound that it describes. Popular examples include "bang," "boom," and the three alleged components of a famous brand of breakfast cereal, "snap, crackle, and pop."
In "The Secret Life of Walter Mitty," our hero experiences five vivid daydreams. In the first, he imagines himself to be a brave airman on a dangerous mission:
The pounding of the cylinders increased: ta-pocketa-pocketa-pocketa-pocketa-pocketa. The Commander stared at the ice forming on the pilot window.
We can see here the use of onomatopoeia. "Ta-pocketa" imitates the sound of the plane's pounding cylinders. It's also used elsewhere in the story to imitate the sound of gunfire and the noise of a machine. But that's in Walter Mitty's fantasy world; in the real world, it's the sound that his car makes.