📄 repltest.m
字号:
function rep=repltest
% REPLTEST Replicate test function. (Utility Function)
% REPLTEST determines which direction Matlab replicates a single
% number using the : operator.
% Author: Craig Borghesani
% 2/17/94
% Copyright (c) 1995-98 by The MathWorks, Inc.
% $Revision: 1.4 $
% perform replicating test with one number
x=5;
v=ones(1,5);
% newx should be a row vector with dimensions 1x5
newx = x(v);
[r,c]=size(newx);
rep=1;
% if r > 1 then matlab is replicating incorrectly
if r>1, rep=0; end
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -