www.gusucode.com > mbcdata 工具箱 matlab 源码程序 > mbcdata/@cgoptimoutput/getNumRuns.m

    function nRuns = getNumRuns(obj)
%GETNUMRUNS Return the number of runs.
%
%   NRUNS = GETNUMRUNS(OBJ) returns the number of runs that the
%   optimization performed.
%
%   See also CGOPTIMOUTPUT/GETNUMSOLUTIONS.

%  Copyright 2005 The MathWorks, Inc. and Ford Global Technologies, Inc.


if ~isempty(obj.outputData)
    nRuns = size(obj.outputData{1}, 1);
else
    nRuns = 0;
end