cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Need to share some code when posting a question or reply? Make sure to use the "Insert code sample" menu option. Learn more! X

Wrong result for keyword fourier transform?

Cornel
19-Tanzanite

Wrong result for keyword fourier transform?

Hello,

 

Input:

CornelBejan_4-1681912076479.png

where 

CornelBejan_5-1681912272266.png

is the step function:

 

CornelBejan_6-1681912305376.png

 

 

CornelBejan_0-1681911767041.png 

Rewriting the above result:

CornelBejan_3-1681911926719.png

 

And calculating fourier transform by definition for the above input, results:

CornelBejan_1-1681911773844.png (which is the correct answer)

 

 

So, where is the mistake?

The 2 above results should not have been equal?

 

Mathcad Prime 8 file attached.

 

 

ACCEPTED SOLUTION

Accepted Solutions
Cornel
19-Tanzanite
(To:LucMeekes)

@Werner_E @-MFra- @ttokoro 

 

I think I discovered where the difference comes from:

 

CornelBejan_0-1681975712896.png

 

CornelBejan_1-1681975729284.png

CornelBejan_2-1681975736085.png

 

CornelBejan_3-1681975782594.png

 

So, fourier transform in keyboard has this definition for calculation of fourier transform:

CornelBejan_5-1681975964497.png

 

and not

CornelBejan_6-1681975975003.png

 

The difference comes from that - sign, as Werner points out in Wolfram Alpha.

 

Is this definition used by fourier transform from keyword correct?

 

From what I know the fourier transform is defined in this way:

CornelBejan_7-1681976185931.png

So, including that - sign.

 

 

 

 

View solution in original post

7 REPLIES 7
LucMeekes
23-Emerald III
(To:Cornel)

The mistake is in Prime.

If Mathcad 11 may be the judge:

LucMeekes_3-1681913546296.png

Chances are this bug has been solved in Prime 9, otherwise/anyway you can/should report this bug to PTC.

 

Success!
Luc

 

P.S. this is what Prime 7 produces:

LucMeekes_1-1681913436571.png

LucMeekes_2-1681913490404.png

 

Werner_E
25-Diamond I
(To:LucMeekes)

Prime is a work in (sloooow) progress - maybe some day it will get it right.

Werner_E_0-1681916511455.png

 

Werner_E_0-1681916007749.png

Werner_E_1-1681916038179.png

Werner_E_2-1681916076371.png

 

Once more its clear - when it comes to symbolic math, Mathcad 11 with Maple rules!

 

 

Werner_E
25-Diamond I
(To:Werner_E)

BTW, here is Wolfram Alpha

Werner_E_0-1681917552223.png

EDIT:

Ahh! Got it!

Werner_E_1-1681918104534.png

 

I was aware of different scaling/normalization in the definitions of the fourier transform, but not of something like this "oscillatory factor"!

As far as I could see there is no definition of the fourier transform mentioned in the Mathcad and Prime help.

Different "oscillatory factors" may be an explanation for Primes results !?

 

 

Cornel
19-Tanzanite
(To:LucMeekes)

@Werner_E @-MFra- @ttokoro 

 

I think I discovered where the difference comes from:

 

CornelBejan_0-1681975712896.png

 

CornelBejan_1-1681975729284.png

CornelBejan_2-1681975736085.png

 

CornelBejan_3-1681975782594.png

 

So, fourier transform in keyboard has this definition for calculation of fourier transform:

CornelBejan_5-1681975964497.png

 

and not

CornelBejan_6-1681975975003.png

 

The difference comes from that - sign, as Werner points out in Wolfram Alpha.

 

Is this definition used by fourier transform from keyword correct?

 

From what I know the fourier transform is defined in this way:

CornelBejan_7-1681976185931.png

So, including that - sign.

 

 

 

 

Cornel
19-Tanzanite
(To:Cornel)

CornelBejan_2-1681977601294.png

Rewriting the above expression:

CornelBejan_4-1681977616547.png

 

CornelBejan_3-1681977607794.png

 

CornelBejan_5-1681977654665.png

 

CornelBejan_1-1681977580749.png

CornelBejan_6-1681977679592.png

 

 

 

Werner_E
25-Diamond I
(To:Cornel)


From what I know the fourier transform is defined in this way:

CornelBejan_7-1681976185931.png


I am not an expert, but basically this is also the only definition I am aware of.

That was also the reason I was confused about of Wolfram Alphas ""oscillatory factor".
Perhaps Wolframs explanation can help to understand: https://mathworld.wolfram.com/FourierTransform.html

 

-MFra-
21-Topaz II
(To:Cornel)

A few years ago a list of all the "defective" calculations of MATHCAD 15 was published in the MATHCAD community. In Prime some have been corrected, but I see that others remain...

Announcements

Top Tags