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

    function N = getNumObjectives(optim)
%GETNUMOBJECTIVES Return the number of objective items
%
%  N = GETNUMOBJECTIVES(OPTIM) returns the number of objective items that
%  the optimization contains.

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


N = length(optim.Objectives);