It is easy to find the fourier coefficient and fourier expansion of $f(x)$ function.
But I want solve the inverse problem by using Mathematica
How to find the function $f(x)$, if I know its fourier coefficient (or fourier expantion)?
for example:
$$a_n=\frac{1}{\pi^2n^2}$$
$$b_n=0$$
$$a_0=\frac{1}{6}$$ or
$$f(x)=\frac{1}{6}-\sum_{n=1}^{\infty}\frac{\cos2xn\pi}{(n\pi)^2}$$
I tried:
Simplify[1/6 - Sum[Cos[2 x Pi n]/(Pi n)^2, {n, 1, Infinity}]]
Plot[%, {x, -3, 3},PlotRange -> 1]
this is a fourier series of $f(x)=x(1-x).$ with $0 \leq x \leq 1$
but how can I get $x(1-x)$ from $\frac{1}{6}-\sum_{n=1}^{\infty}\frac{\cos2xn\pi}{(n\pi)^2}$?
or in other word,
How to solve the system of integral equations for $f(x)$ by using Mathematica?
$$ \begin{cases} \int_{a}^{b}f(x)dx=conts.\\ \int_{a}^{b}f(x)\sin(n x)dx=A(n)\\ \int_{a}^{b}f(x)\cos(n x)dx=B(n) \end{cases} $$





Assuming[0 <= x <= 1, FullSimplify[FunctionExpand[FourierSequenceTransform[If[k == 0, 1/6, -(1/(2 (π k)^2))], k, x, FourierParameters -> {1, -2 π}]] // PowerExpand]]– J. M.'s missing motivation Dec 19 '16 at 11:16PowerExpandwhich uses generic identities like (a^b)^c == a^(b c) that are not always true. – Greg Hurst Jul 19 '20 at 01:01PowerExpand[ FunctionExpand[-(1/\[Pi]^3) I (-\[Pi]^2 Log[1 - E^(I \[Pi] x)] + \[Pi]^2 Log[ E^(-I \[Pi] x) (-1 + E^(I \[Pi] x))] + 2 \[Pi]^2 Log[1 + E^(I \[Pi] x)] - 2 \[Pi]^2 Log[E^(-I \[Pi] x) (1 + E^(I \[Pi] x))] - 2 PolyLog[3, -E^(-I \[Pi] x)] + 2 PolyLog[3, E^(-I \[Pi] x)] + 2 PolyLog[3, -E^(I \[Pi] x)] - 2 PolyLog[3, E^(I \[Pi] x)])]]does not work (see a more complicated case in https://mathematica.stackexchange.com/questions/226148/sum-of-fourier-sine-series-not-giving-original-function). – user64494 Jul 19 '20 at 16:15