So I have a sequence
{gk}^5, k=0 = {1, 0, 4, -1, 0, 0}
and I am to generate the Fourier sequence from that one. What I'm doing is simply using the formula:
Gk = gk * e^(-j2pi * n*k/T) where T = 6, n = 0...5 € Z
and to open up the previous formula because I'm sure it might look a bit confusing with the symbols I'm using/trying to use, here's how I generated G(0):
G(0) = g(0)*e^-j2pi*0*0/6) + 0 + g(2) * e^(-j2pi*0*2/6) - e^(-j2pi*0*3/6) + 0 + 0
= 1 + 4 * e^0 - 1
= 4
and for G(1)
G(1) = g(0)*e^-j2pi*0*1/6) + 0 + g(2) * e^(-j2pi*1*2/6) - e^(-j2pi*1*3/6) + 0 + 0
= 1 + 4(cos(2pi/3)-j*sin(2pi/3)) -(cos(pi)-j*sin(pi))
= 1 - 2 + 1 + 2*sqrt(2)j
= 2*sqrt(2)j
And this is the logic I'm using to calculate the DFT, but for some reason just about every online calculator regarding DFT is giving a different answer when compared to mine and other online DFT calculators, so I'm a little bit lost here.
Is there some glaring problem with how I'm trying to calculate the DFT or is this how it's supposed to go?