15 lines
837 B
Mathematica
15 lines
837 B
Mathematica
|
|
function [ output_args ] = MaxBranchDeviation( ~, Linei,Linej,Liner,Linex,Lineb,Transfori,Transforj,Transforr,Transforx,Branchi,Branchg,Branchb,Transfork0,Volt0,UAngel0,Volt,UAngel)
|
|||
|
|
%% <EFBFBD><EFBFBD><EFBFBD><EFBFBD>֧·<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ƫ<EFBFBD><EFBFBD>
|
|||
|
|
% ֧·<EFBFBD><EFBFBD><EFBFBD>ʰ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>·<EFBFBD>ͱ<EFBFBD>ѹ<EFBFBD><EFBFBD>
|
|||
|
|
%%
|
|||
|
|
[dispLineloss0 dispTransloss0]=Lineloss(Linei,Linej,Liner,Linex,Lineb,Transfori,Transforj,Transforr,Transforx,Branchi,Branchg,Branchb,Transfork0,Volt0,UAngel0);
|
|||
|
|
[dispLineloss dispTransloss]=Lineloss(Linei,Linej,Liner,Linex,Lineb,Transfori,Transforj,Transforr,Transforx,Branchi,Branchg,Branchb,Transfork0,Volt,UAngel);
|
|||
|
|
t1=(dispLineloss0(:,3) - dispLineloss(:,3))./dispLineloss0(:,3);
|
|||
|
|
t2=(dispTransloss0(:,3) - dispTransloss(:,3))./dispTransloss0(:,3);
|
|||
|
|
t11=dispLineloss0(:,3)>1e-5;% ̫С<EFBFBD><EFBFBD>ֵ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
|||
|
|
t22=dispTransloss0(:,3)>1e-5;% ̫С<EFBFBD><EFBFBD>ֵ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
|||
|
|
t3=abs([t1(t11);t2(t22)]);
|
|||
|
|
output_args=max(t3(t3~=Inf));
|
|||
|
|
end
|
|||
|
|
|