Hacker News new | ask | show | jobs
by hammock 4862 days ago
Imagine you are watching the ball, but instead of traveling along a line, it is tracing a circle- however you are viewing it from the one-dimensional angle. Is that smoothstep, or would that be a different equation? They look similar to my naked eye.
3 comments

The reason smoothstep looks similar to a sinusoid is because it is a polynomial approximation. I remember Dan Perlin discussing it in his (book|paper|website), but googling around doesn't seem to show anything that I remember. For Perlin Noise, a sinusoid was the highest-quality interpolation because it was continuous everywhere, even at the endpoints. Smooth-step is discontinuous at the endpoints, but it is close enough for discrete computer graphics.
Do you mean "smooth everywhere"? The Weierstrauss function is continuous everywhere, but you wouldn't use it for interpolation:

http://en.wikipedia.org/wiki/Weierstrass_function

Yes, thank you. After reading a bit more, smoothness is what I'm looking for. One of the _derivatives_ of the smoothstep is discontinuous at the endpoint.
I wouldn't call smoothstep an approximation to a sinusoid - both are sigmoidal, but that's about it. This smoothstep in particular is just a natural cubic spline interpolator, arguably the simplest sigmoidal interpolating function.
Minor correction: Ken Perlin - http://mrl.nyu.edu/~perlin/
Thank you!
Smoothstep is a polynomial approximation of a sine wave through (0, 0) and (1, 1), but it's pretty darn close.

http://www.onlinefunctiongrapher.com/?f=3*x%5E2-2*x%5E3|.5-c...

That would be a sinusoidal function. Smoothstep looks similar but is different.