WOLFRAM

NFourierCosCoefficient[expr,t,n]

gives a numerical approximation to the n^(th) coefficient in the Fourier cosine series expansion of expr, where expr is a periodic function of t with period 2π.

Details and Options

Examples

Basic Examples  (1)Summary of the most common use cases

Use different definitions to calculate numerical approximations for a Fourier cosine coefficient:

Out[2]=2
Out[3]=3

Compare with the answer from symbolic evaluation:

Out[4]=4
Out[5]=5
Out[6]=6