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

Community Tip - Have a PTC product question you need answered fast? Chances are someone has asked it before. Learn about the community search. X

How to optimize sheet converted from MC15 to Prime

Joaberg
5-Regular Member

How to optimize sheet converted from MC15 to Prime

Hi,

 

I have a MC15 calculation-sheet of 200 pages that have been converted to Mathcad Prime 9.0 that runs extremely slowly and which im now looking to optimize. Changes in input that in MC15 would have taken 5-10 seconds to recalculate can now take upwards of 5 minutes or more before the sheet is updated.

 

I've been trying to read up on ways to speed up processing in Mathcad Prime and have read that size of matrices, the use of If-statements and possibly the use of "strings" in aforementioned matrices may be culprits.

 

Which optimizations do you believe would bring me the biggest improvements in calculation speed as opposed to how MC15 was working?

 

Does anyone have any recommendations how i should go about rewriting If-statements? (see attached picture of an example)

 

Im going to see if i can break up the sheet in parts and work on a part separately. Then i can also upload said part here for you to partake in.

 

Kind regards,

Johan

5 REPLIES 5
Werner_E
25-Diamond I
(To:Joaberg)

The very slow processing speed in Prime compared to that in Mathcad has often been criticized by users here in the forum. Even with more dramatic drops in performance than the one you describe (even if yours is bad enough).
It's hard to say which changes might bring the best speed gain - it's a case of trial and error, I guess.

 

PTC is obviously aware of the issue and there is a promise that improving speed would be a major focus in the development of the next Prime release. We will only be able to judge what this promise is worth next year...

Raiko
17-Peridot
(To:Joaberg)

Hi Johan,

 

here are my two pennies for your issue:

  • Don't divide repeatedly. Create a variable once that is the inverse of INTERVALL and multiply with that instead.
  • Try to use LOOKUP functions. I found them to be faster than comparisons.
  • Try to split up your combined AND / OR statements into single ones checking first for one condition and the the other one. That way the second subset of variables to be checked is smaller. 

Hope this helps because Prime's speed is glacial 😉

 

Raiko

JEckhardt
6-Contributor
(To:Joaberg)

I'm suffering the same realization.  Recently converted approx 350 page worksheet from 15 to Prime10.  I ended up breaking it up into 10 worksheets and even then, each one is operating at "glacial" speed (I like that term-thanks Raiko!).  I have a ton of if..then statements, approx 2 or 3 on every page.  I also have many string equations although I chopped a lot of those away, which means I have to manually duplicate descriptions and manually update changes.  The subsequent worksheets have to reference back to the original and previous worksheets to carry through some of the needed information and about 20% of the time, one of these references just quite working properly.  It is abysmal what they've done and if the performance doesn't improve soon, I'll have no choice than to entertain alternatives like Smath.  Good luck and if you discover any sure-fire tips on speed improvements, let us know!

 

Jeff

Joaberg
5-Regular Member
(To:Joaberg)

Just wanted to reaffirm that i have been unable to improve speed by any significant amount. I tried putting in Time(t) variables at different stages of the program to see if one part or another is a specific time sink but unfortunately the "glacial" speed seems to be continuous throughout the worksheet.

 

The performance is unacceptable and i dont see us as a company continuing to subscribe to PTC/Mathcad unless we see significant improvements in performance in the near future.

 

Kind regards,

Johan

JEckhardt
6-Contributor
(To:Joaberg)

Same here Johan.  To be honest, I'm finding very good luck with Smath.  I do have to re-enter all my data but the speed is such that it is still advantageous in the end.  Great job to PTC on finding a way to chase off your customer base!  It's missing a couple things like the controls but I can work around that.  It is usable and that is paramount! 

Jeff

Announcements

Top Tags