fm_vs.m

来自「用于电力系统的一个很好的分析软件」· M 代码 · 共 47 行

M
47
字号
function fm_vs(k,idx0)% FM_VS computes determinants and eigenvalues during%       time domain integrations%% FM_VS(K)%      K    integration step number%      IDX0 starting index of the output array%%Author:    Federico Milano%Date:      11-Nov-2002%Version:   1.0.0%%E-mail:    Federico.Milano@uclm.es%Web-site:  http://www.uclm.es/area/gsee/Web/Federico%% Copyright (C) 2002-2008 Federico Milanoglobal Settings Bus DAE Varout Line% AsAs = DAE.Fx - DAE.Fy*(DAE.Gy\DAE.Gx);AutoState = round(eig(full(As))*1e5)/1e5]';% JlfJlf = build_gy(Line);detJlf = det(Jlf);Jlfr = (Jlf(Bus.v,Bus.v)-Jlf(Bus.v,Bus.a)* ...        (Jlf(Bus.a,Bus.a)\Jlf(Bus.a,Bus.v)));AutoJlfr = eig(full(Jlfr))';% JlfvdetGy = det(DAE.Gy);Gyr = (DAE.Gy(Bus.v,Bus.v)-DAE.Gy(Bus.v,Bus.a)*...       (DAE.Gy(Bus.a,Bus.a)\DAE.Gy(Bus.a,Bus.v)));AutoJlfv = eig(full(Jlfr))';% JlfdJlfd = (DAE.Gy - DAE.Gx*(DAE.Fx\DAE.Fy));detJlfd = det(Jlfd);Jlfdr = (Jlfd(Bus.v,Bus.v)-Jlfd(Bus.v,Bus.a)* ...         (Jlfd(Bus.a,Bus.a)\Jlfd(Bus.a,Bus.v)));AutoJlfd = eig(full(Jlfdr))';vars = [detJlf,detGy,detJlfd,AutoState,AutoJlfr,AutoJlfv,AutoJlfd];idxs = Varout.idx(find(Varout.idx>idx0))-idx0;Varout.vars(k,[idx0+1:end]) = vars(idxs);

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?