Mercurial > hg > octave-lyh
comparison scripts/linear-algebra/expm.m @ 10635:d1978e7364ad
Print name of function in error() string messages.
author | Rik <octave@nomad.inbox5.com> |
---|---|
date | Sun, 16 May 2010 22:26:54 -0700 |
parents | 84398271118c |
children | 3140cb7a05a1 |
comparison
equal
deleted
inserted
replaced
10634:60542efcfa2c | 10635:d1978e7364ad |
---|---|
90 ## @end deftypefn | 90 ## @end deftypefn |
91 | 91 |
92 function r = expm (a) | 92 function r = expm (a) |
93 | 93 |
94 if (! ismatrix (a) || ! issquare (a)) | 94 if (! ismatrix (a) || ! issquare (a)) |
95 error ("expm requires a square matrix"); | 95 error ("expm: input must be a square matrix"); |
96 endif | 96 endif |
97 | 97 |
98 n = rows (a); | 98 n = rows (a); |
99 ## Trace reduction. | 99 ## Trace reduction. |
100 a(a == -Inf) = -realmax; | 100 a(a == -Inf) = -realmax; |