Friction over time

Well, here I am with another question. How can I implement friction over time?

friction*deltatime obviously doesn’t work, it would make the friction greater than 1 if deltatime is big enough. Then I came up with the idea of Math.pow(friction, deltatime);, but it wouldn’t work either, because friction would get lower when deltatime values grow, which is not good (low framerate = big deltatime = lower friction = everything slides.) I’m out of ideas… What am I missing here?

EDIT: I get the feelling that Math.pow is still the way to go. A 0.9 friction over steps would be (0.9step1 + 0.90.9step2 + 0.90.90.9step3 + …) but how can I approximate it? Maybe “for (i=0; i<deltaTime; i++) approxfriction += 0.9*approxfriction;”?

newVelocity = oldVelocity * frictionCoefficient * (deltaTime / targetDeltaTime)

Where target delta time is what you consider a “normal” delta.

What would the frictioncoefficent be? I don’t get any significative results chaging it’s value in the 0.0-1.0 range. It’s always really slow, not matter what value I try. Maybe it’s a bug, I’ll check it.

I’m still thinking about the (0.9step1 + 0.90.9step2 + 0.90.90.9step3 + …). It should really be (0.9velocity+ 0.90.9velocity+ 0.90.90.9velocity + …). That is velocity*(0.9+0.90.9+0.90.90.9+…), the geometric series of 10.9^n (minus one), which would converge to 1/(1-friction_coefficent) (minus one). The sum for the first n tems is velocity*((1-0.9^n)/(1-0.9)-1), where n is the number of steps, or velocity*((1-Math.pow(x_friction, deltatime))/(1-x_friction)-1). Isn’t that a nice approximation? Sound good, I’m going to try both.

EDIT: Nevermind, going through a lot of math I got to your formula.
EDIT2: It’s still not working. Odd :S

I usually do something between 0.9 and 0.99. Change the coefficient to taste. What does “really slow” mean?