matlab - How to Bode plot an array of transfer functions? -
i have transfer functions corresponding llc converter. each 1 different, i'm changing single parameter visualize changes in frequency response. have this:
v(1)=voutput; v(2)=voutput2; v(3)=voutput3;
then plot them using:
figure(1) optsv = bodeoptions('cstprefs'); optsv.frequnits = 'khz'; bode(v, optsv)
the problem every transfer function being plotted in different chart:
how can plot them in single chart?
use
bode(v(1),'r',v(2),'g',v(3),'b', optsv)
where v1,v2,v3
various transfer functions.
they plotted 3 lines 3 colors red, green, blue.
edit, in reply comment: if write in comments many, can create figure, call hold on
, , plot transfer functions in loop, this:
first_tf = tf(1,[1,1]); %your example of many tf. v = [first_tf,2*first_tf,3*first_tf]; figure hold on j=1:length(tfdata(v)) bode(v(j)) end
with output like:
Comments
Post a Comment