accuracy of real numbers multiplication

2 visualizzazioni (ultimi 30 giorni)
biky27
biky27 il 7 Feb 2018
I am trying to implement an algorithm from an article that solves a matrix equation, similar to the Sylvester one. The article is Consistency and efficient solution of the Sylvester equation for *-congruence, by de Teran, Dopico.
In the real case for dimension n=1 the equation simply results in a*x+x*b=c for the unknown x.
In said article there is an analysis on the bound of the relative residual and is found that the norm of the relative residual is bounded by a quantity proportional to u*n^(5/2), where u is the machine precision. To test if the program that I wrote worked i plotted together the residual and the bound from the article for many values of n, but in some cases i get that the bound is not verified for n=1.
Is this simply due to the fact that computations are affected by errors? Because i'm pretty sure that for n=1 my code is not the problem since the equation is simply solved by computing x=c/(a+b). I also found this problem in the complex case, but thought better to try and understand the simpler real case first.

Risposte (0)

Community Treasure Hunt

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

Start Hunting!

Translated by