From cbbcbf2e039076ea22d78e7a296e64c44f24b63d Mon Sep 17 00:00:00 2001 From: facat Date: Tue, 22 Apr 2014 21:33:05 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E4=BA=86=E6=B2=A1=E6=9C=89?= =?UTF-8?q?=E8=AF=BB=E5=88=B0=E7=BA=BF=E8=B7=AF=E5=8F=82=E6=95=B0=E7=9A=84?= =?UTF-8?q?=E5=88=A4=E6=96=AD=E6=9D=A1=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: facat --- lineWithConfig.m | 8 ++++---- run.m | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/lineWithConfig.m b/lineWithConfig.m index 2761b36..16c2a87 100644 --- a/lineWithConfig.m +++ b/lineWithConfig.m @@ -1,6 +1,9 @@ function [ fs30,fs31,fs32,phaseABCY ] = lineWithConfig(setIJ,nodeNum,lineZ,lines,config,baseHighU ) phase3Entry=find(lines(:,1)==config); -if isempty(phase3Entry) +phase3Line=lines(phase3Entry,:); +phase3Line(:,4)=phase3Line(:,4)/1000; +entry=find(lineZ(:,1)==config); +if isempty(entry) fs30=0; fs31=0; fs32=0; @@ -8,9 +11,6 @@ if isempty(phase3Entry) fprintf('warning: line type %d not found.\n',config) return; end -phase3Line=lines(phase3Entry,:); -phase3Line(:,4)=phase3Line(:,4)/1000; -entry=find(lineZ(:,1)==config); phase3R=lineZ(entry+1:entry+3,:); phase3X=lineZ(entry+5:entry+7,:); phase3B2=lineZ(entry+9:entry+11,:); diff --git a/run.m b/run.m index 50fe8f6..f50c68d 100644 --- a/run.m +++ b/run.m @@ -1,8 +1,8 @@ clc clear -lineZ=readLineZ('.\feeder13\lineParameter.txt'); +lineZ=readLineZ('D:\share\feeder123\lineParameter.txt'); [ fsY0, fsY1, fsY2,phaseASpotLoadP,phaseBSpotLoadP,phaseCSpotLoadP ... - phaseASpotLoadQ,phaseBSpotLoadQ,phaseCSpotLoadQ,setIJ,nodeNum,Balance,phaseABCY]=dataRead(lineZ,'.\feeder13\data2.txt'); + phaseASpotLoadQ,phaseBSpotLoadQ,phaseCSpotLoadQ,setIJ,nodeNum,Balance,phaseABCY]=dataRead(lineZ,'D:\share\feeder123\data.txt'); a=exp(1j*2*pi/3); Tp2f=1/3*[1 1 1; 1 a a^2;