Community Tip - Did you get called away in the middle of writing a post? Don't worry you can find your unfinished post later in the Drafts section of your profile page. X
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.
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.
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.
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.
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
Great thankyou 🙂