- Community Home
- :
- Discussion Forums
- :
- Most Active Software Boards
- :
- LabVIEW
- :
- Signal extrapolation with FFT

turn on suggestions

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

Topic Options

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page

01-10-2011 03:52 PM

Options

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report to a Moderator

Any idea or example to convert FFT Coefficients (z = a + i.b) to Frequency, Amplitude and Phase ?

01-19-2011 09:06 AM

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report to a Moderator

up

Solution

Accepted by topic author nferry

08-27-2015 04:09 PM

01-24-2011 10:19 AM - edited 01-24-2011 10:24 AM

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report to a Moderator

Ok I found a solution.

The VI extrapolate a given periodic signal,

it just seems that amplitude coef may be not exactly the same at reconstruction for some signals.

But demonstrating the concept.

Best regards

01-24-2011 11:05 AM

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report to a Moderator

You are kidding yourself!

All you are doing is repeating the fft with a lot of unecessary code. Please read again Darin's first reply.

01-24-2011 01:33 PM

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report to a Moderator

altenbach wrote:

You are kidding yourself!

For demonstration, compare the result of your code with a simple partial repeat of the original data. The attached quick modification shows both. (See also this honorary mention )

(Of course the "green version" needs a little bit more code in case the appended size is larger than the input array, but it should still show you the general concept. Modify as needed.)

01-24-2011 01:53 PM - edited 01-24-2011 01:54 PM

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report to a Moderator

altenbach wrote:(Of course the "green version" needs a little bit more code in case the appended size is larger than the input array, but it should still show you the general concept. Modify as needed.)

Here's one possibility that also works if the extrapolated lenght is larger thatn the input. (Make sure y is positive).

01-25-2011 03:59 AM - edited 01-25-2011 04:07 AM

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report to a Moderator

Hello Altenbach,

Think you for your contribution but

the "repeat approach" does not consider a potential change of resolution of the signal,

where FFT coef is a mathematical representation of the signal, so is more resolution independant.

The "fourier extrapolation" can also reduce the signal initial lenght, where the "repeat method" cannot without code adding.

Like Lynn says, the "repeat method" have also phases discontinuities at boundaries.

Just try with fixing a signal lenght of 733 for example.

But after verification this true also for the "Fourier extrapolation"...

I'm myself a person who looking for the "simplest/best code way",

but please be careful while applying this philosophy to mathematical representation,

because in computer science, we can think with finite discrete elements,

but keep in mind this is an approximation of the reality...

(To my mind mathematical is also an approximation...)

Neverthelees, your optimization is quite interesting, thanks.

And at final "fourier extrapolation" sound more effective for purely periodic signal.

I try to add "Wavelet decomposition" to handle aperiodic signals,

Decomposing into multiple scales signals and then apply fourier extrapolation at eaxh scale.

But the result appear to be similar to the simple fourier extrapolation way.

I provide you some signals (doppler, etc...),

whereas a humain brain can easily apply an extrapolation,

I searching a way to predict these kinds of signals, but not for purely noisy or wall street curves.

Best regards

Nicolas

PS: Please can you add a link to invite the Rube Goldberg readers to come in this forum post,

they can made there home opinion. Thanks.

01-25-2011 10:59 AM

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report to a Moderator

nferry wrote:

... where FFT coef is a mathematical representation of the signal, so is more resolution independant.

The "fourier extrapolation" can also reduce the signal initial lenght, where the "repeat method" cannot without code adding.

Just throwing more math at it does not add anything new to the data. Adding code for a "shortening" is also trivial. A simple "array subset" or "reshape array" will do. Anything is better than your monster code.

nferry wrote:

Like Lynn says, the "repeat method" have also phases discontinuities at boundaries.

Just try with fixing a signal lenght of 733 for example.

But after verification this true also for the "Fourier extrapolation"...

Of course it is also true. Both methods are mathematically equivalent! FFTs are not some magical elixier, they have an exactly defined meaning. (You are just getting potentially more rounding errors due to all the extra computations. )

nferry wrote:PS: Please can you add a link to invite the Rube Goldberg readers to come in this forum post,

they can made there home opinion. Thanks.

I thought the RG post has a link. Right? Look on the second line there.

01-25-2011 03:22 PM - edited 01-25-2011 03:23 PM

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report to a Moderator

nferry wrote:The "fourier extrapolation" can also reduce the signal initial lenght, where the "repeat method" cannot without code adding.

You don't really need to add much code to support negative y inputs, here's one possibility.

01-26-2011 03:05 AM

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report to a Moderator

Hello,

nferry wrote :

the "repeat approach" does not consider a potential change of resolution of the signal,

where FFT coef is a mathematical representation of the signal, so it is more resolution independant.

That's why, FFT can be used for interpolation (see Labview Fourier Interpolation VI)

but not for extrapolation because it performs signal repeats in the time domain,

and it suffers from boundaries discontinuities.

I credit you for a Kudo for the optimization,

and my initial hypotesis to use Fourier is wrong here.

At final extrapolation cannot be done without signal assumptions.

Nicolas