# What are derivatives?

## Recommended Posts

Hi,

This is something I really don't understand and I didn't find anything in the Houdini help. Can anyone explain it in simple terms?

Is it only useful in shading?

Thanks

##### Share on other sites

My half-remembered high school definition of a derivative is its the rate of change of a curve.

Here's a good visual example of 'eyeballing' the derivative of a curve (the rest of the course looks like a good intro too)

If you plot an object's position as it moves around, and take the derivative of its position, that's its velocity. If you take the derivative of its velocity, that's its acceleration. A sillier way to say that is velocity is the rate-of-change of its position, and the acceleration is the rate-of-change of the rate-of-change of the position.

That's also explained here (integrals, or antiderivatives, are the opposite of derivatives):

Obviously this sort of stuff can be useful for simulation and shading (eg, you can think of a bump map as a rate-of-change for the surface normal), but its more something to keep in the back of your mind; whenever you find that you need to measure the rate of change of something, hey presto, you're talking derivatives.

##### Share on other sites

And a 'Jerk' is the acceleration of the acceleration.

##### Share on other sites

Derivatives are often used in surface shading as a way to antialias. In order for texture mipmapping to work, you need to have an idea of how far apart in UV space a sample and its neighbour are. If they are less than a texel apart in UV space, you can use the highest resolution mip level. But if they're several texels apart, you want to blend all those intermediate texels together to get an approximation of the colors blurring together, and thus use a lower-resolution mip level which has pre-baked this blur in the form of a downscaled texture. In order to determine the mip level to use, the shader takes the difference of the UVs with its neighbours at each sample - the "derivative".

They can also be used to determine a reference frame on a surface, which you need to do tangent-space normal mapping.

At the discrete level computer graphics operates at, a derivative is simply the difference of two values over an interval - (V1 - V0) / (P1 - P0).

##### Share on other sites

4 hours ago, malexander said:

They can also be used to determine a reference frame on a surface, which you need to do tangent-space normal mapping.

Is it property of such tangents that they are inconsistent on uv seams?

##### Share on other sites

• 4 years later...

"A derivative is a financial security with a value that is reliant upon or derived from, an underlying asset or group of assets—a benchmark. The derivative itself is a contract between two or more parties, and the derivative derives its price from fluctuations in the underlying asset."

##### Share on other sites

On 5/27/2016 at 5:12 AM, kleer001 said:

And a 'Jerk' is the acceleration of the acceleration.

did you have use case for jerk ?

##### Share on other sites

I once implemented derivatives up to 8th and it become quite hard to use them meaningfully but jerk still showed something that could at least be visualized easily sort of like the uneven acceleration of a car by a new driver that jerks.

## Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

×   Pasted as rich text.   Paste as plain text instead

Only 75 emoji are allowed.

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×