1

From documentation it has been specified that we can use 1,2 or as the second parameter of LinearAlgebra`MatrixConditionNumber command, but when I use 2 as p, Mathematica outputs the following error:

LinearAlgebra`MatrixConditionNumber::nrmp: 
The value 2 of the option Norm is incorrect. It should be 1 or Infinity.

I use Mathematica v9.0 and this is my code:

n = 10; (* n= 20 *)
A = Table[0, {n + 1}, {n + 1}];
x = Sort[RandomReal[1, n + 1, WorkingPrecision -> 4]];
For[i = 0, i <= n, i++,
  For[j = 0, j <= n, j++,
    A[[i + 1, j + 1]] = x[[i + 1]]^j;
    ];
  ];
LinearAlgebra`MatrixConditionNumber[A , Norm -> 2]

enter image description here

Qaher
  • 313
  • 4
  • 9
  • in V10.02, I get The value 2 of the option Norm is incorrect. It should be 1 or Infinity so may be you are looking at old documentation?.. I also tried it on V9 now, and it gives same error message. only 1 and Infinity are allowed. Where does it say 2 is allowed? Can you include screen shot? hard to search these pages with a link to large web page and having to scroll looking. – Nasser Jan 31 '15 at 13:28
  • ..if you are looking at Norm[], then you can use 2 there. But this API could only support 1 and infinity and does not support norm 2. – Nasser Jan 31 '15 at 13:36
  • @Nasser the statement I have declared, is clearly stated in the picture above! (screenshot from the webpage in the link) – Qaher Jan 31 '15 at 13:50
  • the screen shot helps. Yes, it looks like the documentation there is wrong. But notice what it says at top of the page Additional functionality related to this tutorial has been introduced in subsequent versions of Mathematica. For the latest information, see Matrices and Linear Algebra. so it looks like this was valid at one point but no longer. At least not on V9 and V10. – Nasser Jan 31 '15 at 13:53
  • @Nasser I have already done that, but there is no information about that command there! and thank you for your link, it maybe solve my problem. – Qaher Jan 31 '15 at 13:56
  • But there are solutions given in the above link to find what you want? None of those solutions worked for use to find the norm 2? for example using SVD? – Nasser Jan 31 '15 at 14:00
  • @Nasser it works! thank you. – Qaher Jan 31 '15 at 14:19

0 Answers0