Skip to main content
1-Visitor
July 13, 2024
Question

Assume and Simplify not simplifying fully

  • July 13, 2024
  • 2 replies
  • 1074 views

I am trying to simplify the following:

TH_11302993_2-1720840548416.png

However, it leaves the absolute value symbol around cos(t), even though I limited it to only when those functions are positive. It's even weirder that it removes the absolute value symbols from sin(t). It's not a problem for something small like this, but it becomes a problem when I do something more complicated or want to use that calculated expression for something else. How can I get it to simplify it better?

I'm using Mathcad Prime 10.0.0.0

2 replies

25-Diamond I
July 13, 2024

I'm afraid there's not much you can do about it.
The "assume" modifier has always been a bit problematic and has often not worked as desired.
Apart from that, the symbolics in Mathcad and Prime is not at the level of Mathematica or Maple or MatLab with the current muPad implementation.
Different symbolic engines also 'simplify' differently. Prime 6 was the only version in which two engines were integrated - an ancient version of muPad (as it was also integrated in Mathcad 14 & 15 and Prime 1 to 5) and PTC's current in-house development based on friCAS/Axiom.
Here is a screenshot of Prime 6.

Werner_E_1-1720847503052.png


You can see that the new engine is still dragging along even two unnecessary absolute value functions - around sin(t) as well as around cos(t). In this respect, Prime 10 is already a small improvement. With PTC and Prime, you just have to be prepared for program development at glacial speed .... 😉

 

BTW, good old Mathcad 11 had a version of Maple integrated for symbolic calculations - one of the reasons that this version is considered by many long-standing Mathcad users as the best ever.

 

EDIT: Here some results of Prime 10

Werner_E_2-1720848203723.png

 

23-Emerald IV
July 13, 2024

Here are some results of Mathcad 11/Maple:

LucMeekes_0-1720852262734.png

This doesn't work:

LucMeekes_1-1720852290309.png

Instead, you'd have to do:

LucMeekes_2-1720852328574.png

But the assume apparently doesn't help. Other results are:

LucMeekes_3-1720852368449.png

LucMeekes_4-1720852431257.png

LucMeekes_5-1720852449995.png

LucMeekes_0-1720852766369.png

 

As demonstrated, it is hard to control the output of the symbolic processor.

But eventually:

LucMeekes_2-1720853092347.png

 

Success!
Luc

 

25-Diamond I
July 13, 2024

Hmmm,  interesting - looks like MC15 with muPad does a better job in this case as MC11 with Maple.

 

In Prime (and also MC15) "realrange" is not supported, its treated as any unknown identifier.

Werner_E_0-1720868967643.png