www.pudn.com > Classify.rar > unfeasible_3.m, change:2009-07-27,size:244b


P = [-1 0 1 2;2 1 2 1]; 
T = [1 0 0 1]; 
net = newp([1 2;1 2]); %建立网络 
handle = plotpc(net.iw{1},net.b{1}); 
net.trainParam.epochs = 100; 
net = train(net,P,T); 
figure; 
plotpv(P,T); 
handle = plotpc(net.iw{1},net.b{1},handle); %画出分界线