Calculation performance
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Calculation performance
Hi,
I have a Mathcad sheet that calculates a 13X3 matrice and then returns a 13X(3^13) matrice. It is a lot of calculations. I have a HP computer with Intel I7 processor and 64Mb RAM. Task manager say it uses about 10-12% of processor and 3-5MB of memory. So far it´s been working on this for about four hours, and it´s not finnished.
What is missing to make the calculation go faster? Are there any parameters that I can change in Mathcad so it uses more power?
Solved! Go to Solution.
- Labels:
-
Mathcad Usage
-
Other
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi,
Filled out all the ones and with the two changes defining large matrices to full size get 25 seconds
Trick is to calculate the size of Combos before hand
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Your resulting matrix will contain
elements, assuming they are reals, no complex values that will take up
bytes, or
MB of RAM, With 64 MB, your PC doesn't even have half of that amount (although I doubt that a PC with an I7 processor only has 64 MB of RAM, Prime 10 alone takes up a good 140 MB, so you couldn't even run it.).
The speed of your calculation will depend on how the result array is created. Without further information on the algorithm, there's little to say about what you could do to speed it up.
Success!
Luc
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
My bad, offcourse it shall be 64GB. And yes they are reals.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi,
Could you enclose the worksheet then more guidance can be given to speed it up.
Cheers
Terry
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
... also, I let it run over night and it wasn´t finnished. So I terminated it after approx 16 hours.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi
Added a timer at start and finish and it calculates in about 40 seconds? I have a very fast machine with bags of memory but it should not make this much of a difference.
Processor AMD Ryzen 9 5950X 16-Core Processor, 3401 MHz, 16 Core(s), 32 Logical Processor(s)
Installed Physical Memory (RAM) 128 GB
I can see some opportunity for change leave it with me.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Did you fill the right part of the matric with "1"? If not you only calculated 34992 columns. "Antal_Rader=34992"? If so, it sounds pretty much the same as I have
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi,
Do you have a sheet with the 1's to calculate the 13x3^13 matrix. Or can you show me where the 1's go with screenshots.
Speeding it up:
Putting sign[133 = 0 at the top preassigning this whole matrix speeds it up to 25 seconds.
Putting a predefinition of Combos size drops performance to 1.7 seconds
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Since It take so long for the calculation I can´t save a copy where it´s filled.
Open up the Excel component
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi,
Filled out all the ones and with the two changes defining large matrices to full size get 25 seconds
Trick is to calculate the size of Combos before hand
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Cool, that predefiniton made the difference.
Time got down to 34 sec.!
