getvalue3.m
来自「数组排序,按照数组的某个元素进行排序,使用请查看」· M 代码 · 共 14 行
M
14 行
function y = getvalue3(path,F,X,table)
% path contains nodes of each stage of the table
% to get the value of the path, set it the last element of the path
s = size(path);
s = s(2);
fx = 0;
for i = 1:s
%f = fvec{i};
choice = table(1,path(i));
path(i) = X(i,choice);
fx = fx + F(choice,i);
end
path(s+1) = fx;
y = path;
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?