It’s called a sinusoidal grating because the grayscale values vary according to the sine function.
If you plot the values along a horizontal line of the grating, you’ll get a plot of a sine function
Sinusoidal gratings can have different orientations…
…and different frequencies—these are spatial frequencies, not temporal ones
There's one more parameter that defines a sinusoidal grating: the phase. Gratings with a different phase are shifted with respect to each other…
Or even better, you can use a function of both x and y to make any grating
And therefore, you can reconstruct the image by adding all of those sinusoidal gratings together.
The more gratings you add, the closer the result is to the actual image
Here's another example
and another one…
There's a lot more than can fit in a single thread.
If you want to read more detail, and go through the step-by-step writing of the code to decompose & recostruct *any* image, read full article here:
QOTO: Question Others to Teach Ourselves
An inclusive, Academic Freedom, instance
All cultures welcome.
Hate speech and harassment strictly forbidden.