Mercurial > matrix-functions
comparison toolbox/jordbloc.m @ 0:8f23314345f4 draft
Create local repository for matrix toolboxes. Step #0 done.
author | Antonio Pino Robles <data.script93@gmail.com> |
---|---|
date | Wed, 06 May 2015 14:56:53 +0200 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:8f23314345f4 |
---|---|
1 function J = jordbloc(n, lambda) | |
2 %JORDBLOC Jordan block. | |
3 % JORDBLOC(N, LAMBDA) is the N-by-N Jordan block with eigenvalue | |
4 % LAMBDA. LAMBDA = 1 is the default. | |
5 | |
6 if nargin == 1, lambda = 1; end | |
7 | |
8 J = lambda*eye(n) + diag(ones(n-1,1),1); |