Least squares approximation of trigonometric DFT polynomial

360 Views Asked by At

So my task is to interpolate the following 4 points: $(0,0) (0.25,1) (0.5,0) (0.75,-1)$. So I begin my using the DFT on $[0,1,0,-1]$ which results in $[0,-i,0,i]$. This gives the interpolation: $P_4(t)=sin2\pi t$ (which I have verified is correct).

Now my task is to find the best order 2 least squares approximation to this data, using the basis functions $1$ and $cos2\pi t$ but I am unsure on how to proceed. Usually using least squares approximation would just mean chopping off from the trigonometric polynomial, but now I am supposed to use basis functions.

Does this mean that I simply only want to keep the two first parts of the trigonometric polynomial (since I am using the first two basis functions), however since $P_4(t)=sin2\pi t$ only has the third part, the answer is $0$?

1

There are 1 best solutions below

0
On BEST ANSWER

I'm not entirely sure, but if I understand correctly, aren't you simply supposed to minimize

$$f(a,b)=\int_0^1\Big(\big(a+b\cos(2\pi t)\big)-\sin(2\pi t)\Big)^2\,dt$$

over $(a,b)\in\mathbb{R}^2$?