1
$\begingroup$

http://imgur.com/itkKA

I'm looking for this behavior to simulate the movement of the recoil of a gun.

I'm not sure the recoil exactly has this shape, that's a wild guess.

I'm looking for a function that does this approximately, or simulate the movement caused by recoil...

Something like f(t)=...

Any idea ?

Somebody told me about some probabilistic function of Maxwell something, but I can't use it without a time dependent formula.

  • 0
    making a game, using 32 bit precision, which is not much but quite enough. Has to be fast.2012-03-13

1 Answers 1

1

Looks somewhat like a rescaled version of $y = x e^{-x}$. Try $y=cx e^{1-cx}$ with various choices of $c>1$. For example, try entering (5x)e^(1-5x) from 0 to 1 into Wolfram Alpha.