what is the efficient method for solving symbolic system of equation?

4 views (last 30 days)
Dear all,
now I am using the inverse of matrice x=inv(A)*b and A\b but it does not efficiently solve with large problem. the problem is the error of using mupadmex in command sym for inverse matrices is out of memory. so anyone could suggest me what is the best method for solving the symbolic system of equation?
thank you so much. Best regard
Chantrea

Accepted Answer

Walter Roberson
Walter Roberson on 6 Sep 2015
Symbolic solutions of larger matrices are inherently large. For example the inverse of a 5 x 5 matrix is over 200000 characters long, and 6 x 6 is over 2000000 long; each additional increment makes the inverse about 10 times larger to represent on output -- and additional memory might be required during the calculation. Multiple gigabytes to calculate the 7 x 7. Roughly 2.2 * 10^N is the output size for the symbolic inverse of a matrix N x N.
If you do not have that much memory, then either add physical memory or add "swap" (which will likely be very slow unless you are using solid state disks).
There is no "compact" or "memory efficient" symbolic inverse. Symbolic solutions are exact solutions and every portion of the solution is needed to get the right answer. You might be able to simplify() afterwards but the sizes I list above are after simplification.
What size of matrix are you trying to process?
  4 Comments
chan trea
chan trea on 7 Sep 2015
thank you very much sir, so it means that maybe the inverse of matrix, it will be the best method. But the problem is,, I cannot solve the 20x20 matrix using the inverse of matrix.
chan trea
chan trea on 7 Sep 2015
Edited: chan trea on 7 Sep 2015
I am sorry sir, I dont get your point. what you mean when we use backslash on the NUMERIC matrix. will it still be symbolic when we use NUMERIC matrix?

Sign in to comment.

More Answers (1)

Steven Lord
Steven Lord on 6 Sep 2015
Walter gave you a good answer the first time you asked this question.
Just because you WANT to be able to solve a large (by the way, what do you mean by "large"? How many symbolic variables?) system quickly doesn't mean it's POSSIBLE to solve it quickly.
  2 Comments
chan trea
chan trea on 7 Sep 2015
I am sorry sir, for repeated the same question. I try to solve the 20x20 matrix or more than this if possible. I just want to know which method that can solve this type of problem even it consumes a lot of time.. I try to use inverse matrix but I don't get the results.
I am very much appreciated for your comment.
Walter Roberson
Walter Roberson on 7 Sep 2015
How would you store the result? How many exabyte hard drives do you have on your system to store the result? What is the largest file size supported on your operating system?
How many decades do you have available just to store the data on the drive once ? The maximum sustained transfer rate I can find for commercially available hard drives (that are not solid state) is about 225 megabytes per second. That's pretty close to the storage required for a 6 x 6 matrix, so once a 7 x 7 was calculated it could be expected to require 10^1 = 10 seconds, 8 x 8 would be expected to require 10^2 = 100 seconds.. 20 x 20 would be expected to require about 10^(20-6) = 10^14 seconds. I estimate that is over 3 million years just to write out the result.

Sign in to comment.

Categories

Find more on Symbolic Math Toolbox in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!