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

    function nFreeLab = getNumFreeVariableLabels(optimstore)
%GETNUMFREEVARIABLELABELS Return the number of free variable labels 
%   NOBJ = GETNUMFREEVARIABLELABELS(OPTIMSTORE) returns the number of free
%   variable labels in the optimization
%
%   See also: CGOPTIMSTORE/GETNUMFREEVARIABLES

%  Copyright 2005-2009 The MathWorks, Inc.


opts = getOptimOptions(optimstore.OptimRunner,'full');
freelab = getFreeVariables(opts);
nFreeLab = length(freelab);