0

I'm trying to get to grips with tikzpicture and am looking at the Fourier expansion example (see Replicate the Fourier transform time-frequency domains correspondence illustration using TikZ )

In Shuhao Cao's answer there is this piece of script:

\foreach \y in {0.5,1.5,...,5.5}{
\draw [cyan!50, domain=0:2*pi,samples=200,smooth] 
plot (\y,\x, {sin(4*\y*\x r)/\y });

But I can't see where 'r' is defied in '{sin(4*\y*\x r)/\y }'? is this an intrinsic function? I've ran Shuhao Cao's script and it works fine, but I don't understand what r is. Perhaps it simply stands for the units "radian"?

1 Answers1

1

Page 923 of the manual covers various aspects of PGF's parsing of mathematical expressions. These include:

Various functions are recognized, so it is possible to parse sin(.5*pi r)*60, which means “the sine of 0.5 times π radians, multiplied by 60”. The argument of functions can be any expression.

cfr
  • 198,882