Got Questions? Get Answers.
Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Thread Subject:
Extract values from fourier images

Subject: Extract values from fourier images

From: Aron Sceidt

Date: 3 Jul, 2012 16:35:07

Message: 1 of 5

Perhaps more than a Matlab question or i don't know if matlab comes up with something. Is there a way to extract values from a 2D DFT image? I am training a model and i need values that are extracted from the 2D DFT image of the object. I do know what the frequency domain is, and how it can be visually interpreted, but I cant seem to know how to extract values from it? any help or direction?

Many thanks

Subject: Extract values from fourier images

From: Nasser M. Abbasi

Date: 3 Jul, 2012 18:21:38

Message: 2 of 5

On 7/3/2012 11:35 AM, Aron Sceidt wrote:
>Is there a way to extract values from a 2D DFT image?
>

Please explain what you mean by the above. Extracting
a value from 2D DTF image is the same as extracting
a value from any image. It is a matrix. Hence you use
the same methods of extracting values from a matrix,
i.e. use indexing.

--Nasser

Subject: Extract values from fourier images

From: Aron Sceidt

Date: 3 Jul, 2012 18:40:08

Message: 3 of 5

Sorry for not making myself clear. What i really want is something like getting a single value from the whole DFT image (upon some calculation) that would represent some property in the DFT image. I will be using these values to train a classifier.

 "Nasser M. Abbasi" <nma@12000.org> wrote in message <jsvd7g$gga$2@speranza.aioe.org>...
> On 7/3/2012 11:35 AM, Aron Sceidt wrote:
> >Is there a way to extract values from a 2D DFT image?
> >
>
> Please explain what you mean by the above. Extracting
> a value from 2D DTF image is the same as extracting
> a value from any image. It is a matrix. Hence you use
> the same methods of extracting values from a matrix,
> i.e. use indexing.
>
> --Nasser
>

Subject: Extract values from fourier images

From: Nasser M. Abbasi

Date: 3 Jul, 2012 19:11:33

Message: 4 of 5

On 7/3/2012 1:40 PM, Aron Sceidt wrote:
> Sorry for not making myself clear. What i really want is something
>like getting a single value from the whole DFT image (upon some calculation)
>that would represent some property in the DFT image. I
>will be using these values to train a classifier.

I still do not understand. A(1,1) is a single value.
So now what? btw, you need to take the absolute of
the FFT2 and phase, just like we do with standard 1D fft.
The 2D fft is complex as is, just like 1D fft.

I forgot some of this, but I think, assuming you did not do
an fftshift2 on the frequency image then if you just take the 1D
ftt (normal fft) on each ROW of the spatial image, and let
the result be called A'

Now apply a 1D fft on each COLUMN of A' then this gives
you the 2D fft image that you would obtain from fft2.

ps. if you did fftshift2, then the DC value will be in
the middle of the fft image. Otherwise it will be the (1,1)
value. The DC value represents the average brightness of
the spatial image if I remember right.

I am not sure if this helps. I think what you are asking for
is still not clear.

--Nasser

Subject: Extract values from fourier images

From: saad

Date: 30 Sep, 2013 11:33:07

Message: 5 of 5

"Nasser M. Abbasi" wrote in message <jsvg53$okt$1@speranza.aioe.org>...
> On 7/3/2012 1:40 PM, Aron Sceidt wrote:
> > Sorry for not making myself clear. What i really want is something
> >like getting a single value from the whole DFT image (upon some calculation)
> >that would represent some property in the DFT image. I
> >will be using these values to train a classifier.
>
> I still do not understand. A(1,1) is a single value.
> So now what? btw, you need to take the absolute of
> the FFT2 and phase, just like we do with standard 1D fft.
> The 2D fft is complex as is, just like 1D fft.
>
> I forgot some of this, but I think, assuming you did not do
> an fftshift2 on the frequency image then if you just take the 1D
> ftt (normal fft) on each ROW of the spatial image, and let
> the result be called A'
>
> Now apply a 1D fft on each COLUMN of A' then this gives
> you the 2D fft image that you would obtain from fft2.
>
> ps. if you did fftshift2, then the DC value will be in
> the middle of the fft image. Otherwise it will be the (1,1)
> value. The DC value represents the average brightness of
> the spatial image if I remember right.
>
> I am not sure if this helps. I think what you are asking for
> is still not clear.
>
> --Nasser

Hi Mr. Nasser
I am Saad from Libya, i am working on the digital relays in power system, and one of the things that i am working on is the DFT method as a filter. I want to ask you if you know algorithm in Matlab to extract the magnitude of one frequency in that signal, and the change of that magnitude with time, because the signal is transient and decaying with time to steady state value. I would be appreciated if you inhance me.

Thanks,

Tags for this Thread

No tags are associated with this thread.

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Contact us