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

Community Tip - Learn all about the Community Ranking System, a fun gamification element of the PTC Community. X

15-Moonstone

Bug in symbolic integration?

I try to get formula for ellipse area in polar coordinates. I've got it but symbolic result is wrong. I can`t understand why?

One more example with strange behaviour

1 ACCEPTED SOLUTION

Accepted Solutions
24-Ruby V
(To:ifomenko)

The Mupad version licensed by PTC for Mathcad seems to be very old and also quite limited in functionality (compared to whats possible in Matlab).

14 REPLIES 14
23-Emerald III
(To:ifomenko)

No, I'd rather think it's a bug in your formulation of the integral. Why additionally integrate from 0 to 1?

15-Moonstone
(To:LucMeekes)

23-Emerald III
(To:ifomenko)

Check my attachment (I've attached the file to my first reply), and see where a difference (if any) occurs.

Success!
Luc

24-Ruby V
(To:LucMeekes)

Hi Luc!

Here's your file displayed in Mathcad 15.

The main difference seems to be Maple vs. Mupad.

Not sure though, why the plot looks different.

15-Moonstone
(To:LucMeekes)

I've got the same as Werner

24-Ruby V
(To:ifomenko)

Before evaluting the definite integral, Mathcads symbolics calculates the indefinite one and I guess that the problem lies here.

The expression MuPad calculates seems not to be valid for the full range of t (or its wrong completely?)

I guess that Lucs MC11 with Maple gives a different result

15-Moonstone
(To:Werner_E)

And,so is this Achilles' heel?

23-Emerald III
(To:Werner_E)

It is quite different,... and wide.

For the curious I've copied the symbolic result to a new equation, stretched over two lines.

(You don't want to see what symplify does):

@WernerExinger wrote:

Before evaluting the definite integral, Mathcads symbolics calculates the indefinite one and I guess that the problem lies here.

Then why is the polar plot already different?

Luc

23-Emerald III
(To:LucMeekes)

But this is interesting:

15-Moonstone
(To:LucMeekes)

unfortunately,assumptions a>0,b>0,t=real don't change situation.

what about MC Prime 4?

23-Emerald III
(To:ifomenko)

Can't check, I'm limited to express.

Luc

24-Ruby V
(To:LucMeekes)

Then why is the polar plot already different?

This has nothing to do with the math, the expression and the symbolics.

Its seems that tha way, Mathcad choses the limits if you dont do it yourself has changed since version 11. You set the upper limit for r to 6 but the lower limit was chosen automatically by MC, MC had chosen r=0, MC15 chooses r=3. If change this manually to 0, I get the very same result as seen in your screenshot (see left plot in my pic).

Mupad in Mathcad always had very big problems with indefinite and also definite integrals in the past. It was horrible in MC14 and they changed a lot with MC15, but still we find bugs and errors. This seems to be one of them again.

Not sure if it makes sense to report it to PTC as they seem to have no interest in improving or at least bug fixing Mathcad and when it comes to the symbolics (MuPad) they are dependent on Mathworks.

15-Moonstone
(To:Werner_E)

I've checked this integral in matlab.Their MuPAD provide correct result.

24-Ruby V
(To:ifomenko)

The Mupad version licensed by PTC for Mathcad seems to be very old and also quite limited in functionality (compared to whats possible in Matlab).

Announcements
Top Tags