Turn on suggestions

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

Showing results for

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

Showing results for

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

Oct 16, 2014
05:14 AM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator

Oct 16, 2014
05:14 AM

Simple (I think) query. Convert a function to a Vector...

Hi,

I'm sure this is real easy but I can't see the wood for the trees. Given a function which uses a range variable as it's parameter. How do I convert this to a Vector for use in the fft function?

Please see attached.

Thankyou,

Mike.

Solved! Go to Solution.

1 ACCEPTED SOLUTION

Accepted Solutions

Oct 16, 2014
05:26 AM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator

Oct 16, 2014
05:26 AM

Have a look at the attached.

I have used a pre-defined function to turn your range variable into a vector and also reduced fs to 512.

4 REPLIES 4

Oct 16, 2014
05:26 AM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator

Oct 16, 2014
05:26 AM

Have a look at the attached.

I have used a pre-defined function to turn your range variable into a vector and also reduced fs to 512.

Oct 16, 2014
05:46 AM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator

Oct 16, 2014
05:46 AM

Brilliant thankyou.

I'm trying to implement a MATLAB FFT solution in MATHCAD. One quick question for anyone reading - using an fs value of 1000 I can run the FFT function within MATLAB but for MATHCAD I need to use either 512, 1024, etc. Why is this?

Thankyou.

Oct 16, 2014
05:51 AM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator

Oct 16, 2014
05:51 AM

Mike Shaw wrote:

Brilliant thankyou.

I'm trying to implement a MATLAB FFT solution in MATHCAD. One quick question for anyone reading - using an fs value of 1000 I can run the FFT function within MATLAB but for MATHCAD I need to use either 512, 1024, etc. Why is this?

Thankyou.

Because the Mathcad functions fft (, ifft, FFT and IFFT) assume vectors of length 2^m.

Use the functions cfft (,icfft, CFFT or ICFFT) instead - they allow arrays of arbitrary size.

Stuart

Oct 16, 2014
05:52 AM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator

Oct 16, 2014
05:52 AM

Great thankyou 🙂