# Calculating the Inverse Discrete time Fourier transform

## Homework Statement

Let the DTFT (Discrete time Fourier transform) of a signal be

Y(f)=
{1 0≤lfl< $\frac{fs}{8}$
{0 Otherwise

Calc y(k)

## Homework Equations

$y(k)=\frac{1}{f_{s}}$$\int Y(f) e^{jk2\pi fT}df lkl≥0$

## The Attempt at a Solution

So what I understand from this is that my Y(f) is basically 1 when f is between the boundaries of 0 and $\frac{f_{s}}{8}$

So I basically get just the exponential in my inverse formula right?

So $y(k)= \frac{1}{f_{s}}\int e^{jk2/pi ft}$

$\frac{1}{f_{s}} e^{jk2 \pi ft}$

However i feel this is incorrect as I dont know what to really do with my limit of fs/8?

Thanks for any hlep..

Related Engineering and Comp Sci Homework Help News on Phys.org
I like Serena
Homework Helper
Hi Evo8!

## Homework Statement

Let the DTFT (Discrete time Fourier transform) of a signal be

Y(f)=
{1 0≤lfl< $\frac{fs}{8}$
{0 Otherwise

Calc y(k)

## Homework Equations

$y(k)=\frac{1}{f_{s}}$$\int Y(f) e^{jk2\pi fT}df \quad |k|≥0$
Didn't you say you were doing a "discrete" fourier transform?
In that case you should have a summation instead of an integral.

Furthermore, your exponential does not look quite right.
It shouldn't have a "k" as well as a "T" in it - one or the other.

What are the boundaries of this integral?

And what is the point of including |k|≥0?
This would always be true.

## The Attempt at a Solution

So what I understand from this is that my Y(f) is basically 1 when f is between the boundaries of 0 and $\frac{f_{s}}{8}$

So I basically get just the exponential in my inverse formula right?

So $y(k)= \frac{1}{f_{s}}\int e^{jk2/pi ft}$

$\frac{1}{f_{s}} e^{jk2 \pi ft}$

However i feel this is incorrect as I dont know what to really do with my limit of fs/8?

Thanks for any hlep..
Yes, the limit of fs/8 should be used as a boundary to the integral.

Hi I Like Serena!

Correct I did say Discrete time FT. However Im given the DTFT and need to calculate the inverse. To find just plain y(k). That is why I have the integral instead. Im using the equation i listed under relevant equations.

Good point on the |k|≥0. This was just how it was defined in my book.

Both of my definitions for DTFT and IDTFT have k AND T in the exponential? Why do you say it should be one or the other? Am I missing something?

The boundaries to this integral from my book are -fs/2 and fs/2.... Maybe I dot fully understand what fs is in this case?

As always thanks for the replies and help! Much appreciated!

P.s. What are the tags for absolute value? I havent been able to find them?

I like Serena
Homework Helper
Hi I Like Serena!

Correct I did say Discrete time FT. However Im given the DTFT and need to calculate the inverse. To find just plain y(k). That is why I have the integral instead. Im using the equation i listed under relevant equations.

Good point on the |k|≥0. This was just how it was defined in my book.

Both of my definitions for DTFT and IDTFT have k AND T in the exponential? Why do you say it should be one or the other? Am I missing something?

The boundaries to this integral from my book are -fs/2 and fs/2.... Maybe I dot fully understand what fs is in this case?
No, sorry, I mixed up your IDTFT with the DFT.

I didn't realize before but fs is the sampling frequency and T is the sampling time interval.
So fs=1/T.

As always thanks for the replies and help! Much appreciated!

P.s. What are the tags for absolute value? I havent been able to find them?
It's the vertical line | that is on the same key as the backslash \.

## The Attempt at a Solution

So what I understand from this is that my Y(f) is basically 1 when f is between the boundaries of 0 and $\frac{f_{s}}{8}$
It's also 1 when f is between $-\frac{f_{s}}{8}$ and 0, due to the absolute value of f.

So I basically get just the exponential in my inverse formula right?

So $y(k)= \frac{1}{f_{s}}\int e^{jk2\pi fT}$
Can you include the boundaries to your integrals?
Those are rather important for stuff like this.
So it should be:
$$y(k)= \frac{1}{f_{s}}\int_{-f_s \over 2}^{f_s \over 2} Y(f) e^{jk2\pi fT} df$$

Since Y(f) is 1 or 0, you can replace the boundaries by the appropriate boundaries where Y(f) is 1.

$\frac{1}{f_{s}} e^{jk2 \pi ft}$
Not quite. You didn't integrate integrate properly.

Can you include the boundaries to your integrals?
Those are rather important for stuff like this.
So it should be:
Sorry about that I wasnt sure how to add the limits. I have figure it out though. Ill be sure to do so in the future.

It's also 1 when f is between −fs8 and 0, due to the absolute value of f.
So really my Y(f) is 1 between

$-\frac{f_{s}}{8} and \frac{f_{s}}{8}$?

So my formula should look like this

$y(k)=\int_{-\frac{f_{s}}{8}}^{\frac{f_{s}}{8}}Y(f) e^{jk2 pi fT}df$

But if my Y(f) is either 1 or 0 what happens when it is 0? Wont it wipe out the e altogether? If its 1 I get just the exponential integrated at the shown limits. Which IIRC the integral of an exponential is the exponential plus a constant C?

So I would get

$\frac{1}{f_{s}} e^{jk2 pi fT} +C?$

I dont think I integrated this properly because I did not included any limits into my work. hmmm. I have to go back and review on how to integrate with a limit?

So below ive integrated with limits so i think anyway. Its been a while.

$y(k)= \frac{1}{f_{s}} (e^{j2 pi fT \frac{f_{s}}{8}}-e^{-j2 pi fT \frac{f_{s}}{8}} +C)$

Im not sure about that +C though...

I like Serena
Homework Helper
Sorry about that I wasnt sure how to add the limits. I have figure it out though. Ill be sure to do so in the future.

So really my Y(f) is 1 between

$-\frac{f_{s}}{8} and \frac{f_{s}}{8}$?

So my formula should look like this

$y(k)=\int_{-\frac{f_{s}}{8}}^{\frac{f_{s}}{8}}Y(f) e^{jk2 pi fT}df$

But if my Y(f) is either 1 or 0 what happens when it is 0? Wont it wipe out the e altogether?
Yep!

That's why the boundaries are adjusted.
Where Y(f) is 0 everything is wiped out, so we bring that outside the boundaries.

If its 1 I get just the exponential integrated at the shown limits. Which IIRC the integral of an exponential is the exponential plus a constant C?

So I would get

$\frac{1}{f_{s}} e^{jk2 pi fT} +C?$
The integral of an exponential is indeed an exponential.
But you appear to forget the chain rule.
What would you get if you calculate the derivative of what you have?

The constant C is the integration constant for indeterminate integrals, that is, integrals for which you do not know the boundaries.
Since you do have the boundaries, you should leave the constant C out.

I dont think I integrated this properly because I did not included any limits into my work. hmmm. I have to go back and review on how to integrate with a limit?

So below ive integrated with limits so i think anyway. Its been a while.

$y(k)= \frac{1}{f_{s}} (e^{j2 pi fT \frac{f_{s}}{8}}-e^{-j2 pi fT \frac{f_{s}}{8}} +C)$

Im not sure about that +C though...
You still left "f" in the expression.
You're supposed to replace "f" with each boundary.

Ah yes the chain rule. I have looked up this rule and remember it vaguely.

So I would have the integral of Y(f)*the integral of the exponential's with the limits

The integral of Y(f) in the limits would just be f correct?

The integral of the exponential in the limits and my integral of the function Y(f) would be?

$y(k)=\frac{f}{f_{s}}(e^{jk2 \pi t \frac{fs}{8}}-e^{jk2 \pi t \frac{-fs}{8}})$

EDIT: Origionally I thought the boundaires replaced the k's in the expression but now I see that it replaces the f's because the integral variable is f. Denoted by the df. So I added the k's back in. Now where does that leave me as I have k's in the exponential?

Last edited:
I like Serena
Homework Helper
The chain rule says that if you have a function like:
$$f(x)=e^{Ax}$$
then the integral is:
$$\int_a^b e^{Ax} dx = {1\over A} e^{Ax} \big|_a^b = {1 \over A}(e^{Ab} - e^{Aa})$$

Can you map this on your integral?
Basically I'm missing the 1/A factor.

Btw, your t should be a T, since it's not a time variable, but a sampling interval.

Last edited:
Right i sometimes put that lower case t there even though I realize that it should be T. I will include the upper case from now on. Thanks for pointing it out.

So if ive done things correctly this is what I have

$y(k)=\frac{1}{f_{s}jk2 \pi T}(e^{j \frac{k2 \pi T f_{s}}{8}}-e^{-j \frac{k2 \pi Tf_{s}}{8}})$

Now should that first term be $\frac{f}{f_{s}jk2 \pi T}$ ?

From taking the integral of my Y(f)? Or is what I have written above for y(k) more correct?

Thanks again

I like Serena
Homework Helper
What you have written for y(k) is correct now! :)

It should definitely not include f.
The integral is calculated with respect to f, eliminating f.
The resulting function y(k) is dependent on k only and not on f.

Btw, your formula for y(k) can be simplified using Euler's formula.
Are you aware of that?

That was my next thought was weather or not i could simplify with euler formula.

I just gave it a try and everything basically cancels out? So I'm left with simply

$y(k)= \frac{1}{f_{s}jk2 \pi T}$?

This makes sense when i think about it as the operator between the cos and j*sin is either +/- depending on the exponential sign. Since once is + and the other is - and the two exponential's are subtracted then all the terms have an opposite sign copy that get canceled. Did I make a mistake in my algebra?

I like Serena
Homework Helper
The exponentials do not cancel out since they have a different power (different by a minus sign).
(And even if they did cancel, then you wouldn't be left with your result, because it would be zero.)

Perhaps you can reread how you can express the sine in exponentials?

hmm good point. It would be 0 not 1 like i thought.

Ok well I think im lost. If I replace all that is in the power of my exponential with $\Theta$

Then I would get

$\frac{1}{f_{s}jk2 \pi T} [(cos (\theta) + j sin (\theta) - cos(\theta) - j sin(\theta))]$

??

I like Serena
Homework Helper
hmm good point. It would be 0 not 1 like i thought.

Ok well I think im lost. If I replace all that is in the power of my exponential with $\Theta$

Then I would get

$\frac{1}{f_{s}jk2 \pi T} [(cos (\theta) + j sin (\theta) - cos(\theta) - j sin(\theta))]$

??
Perhaps you could try the following (carefull with parentheses and minus signs!)?
$$\frac{1}{f_{s}jk2 \pi T} [(cos (\theta) + j sin (\theta)) - (cos(-\theta) + j sin(-\theta))]$$

Perhaps you could try the following (carefull with parentheses and minus signs!)?
$$\frac{1}{f_{s}jk2 \pi T} [(cos (\theta) + j sin (\theta)) - (cos(-\theta) + j sin(-\theta))]$$
Please push Ronald Mcdonald down the stairs. Right. Order of operations is something I apparently didnt think to apply to this last night. I apologize for such a novice mistake. Im working long overnight shifts and i was a bit fatigued last night.

So I undersand $$\frac{1}{f_{s}jk2 \pi T} [(cos (\theta) + j sin (\theta)) - (cos(-\theta) + j sin(-\theta))]$$ is in correct form.

Im assuming it could also be
$$\frac{1}{f_{s}jk2 \pi T} [(cos (\theta) + j sin (\theta)) - (cos(\theta) - j sin(\theta))]$$ as well correct?

Im not sure I understand how to simplify this more. However i realize that its possible. When I use my calculator to simplify I get
$2 sin(\theta)j$

So I would then get
$\frac{2 sin(\theta)j}{f_{s}jk2 \pi T}$

I like Serena
Homework Helper
Yes!
And you can simplify it further since you have common factors in the nominator and denominator that cancel against each other.

I like Serena
Homework Helper
Please push Ronald Mcdonald down the stairs.
Now why would you want me to do that?
Did he make a mistake too?

Now why would you want me to do that?
Did he make a mistake too?
Ha!

Thanks again for the assistance! You break things down in a way that makes sense when something seems unclear. I really appreciate it!

I like Serena
Homework Helper
You're welcome! :)