📄 bipart_perturb.m
字号:
function W = bipart_perturb(X,W,Ea,T)
% W = bipart_perturb(X,W,Ea,T)
% Method for graphbipart example supplied with SA Tools.
% See http://www.frostconcepts.com/software for information on SA Tools.
%
% W = bipart_perturb(X,W,Ea,T) ;
%
% X = {N, A}
% N = # of vertices.
% A = Adjacency matrix.
% W = vector of +1, -1 partition of length N
% Ea = (not used) average energy at current temperature.
% T = (not used) current temperature
%
% Flips the sign of a random element of W.
%
n = X{1} ;
i = 1 + floor(n*rand) ;
W(i) = -W(i) ;
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -