lmatrix.m

来自「线性代数实验及MATLAB入门,电子工业出版社出版 陈怀琛 龚杰民合著」· M 代码 · 共 10 行

M
10
字号
function L=Lmatrix(n)
% The function Lmatrix(n) generates a matrix
% of 0's and 1's. The nonzero entries are in the
% form of a letter L, that is the first column
% and the last row consist entirely of 1's and
% the remaining entries are 0.
L=zeros(n);
L(:,1)=ones(n,1);
L(n,:)=ones(1,n);

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?