main content

combine s-凯发k8网页登录

combine s-parameters to form cascade network

description

example

s_params= cascadesparams(s1_params,s2_params,...,sk_params) cascades the scattering parameters (s-parameters) of k input networks described by the s-parameters. each input network must be a 2n-port network described by a 2n-by-2n-by-m array of s-parameters for m frequency points. all networks must have the same reference impedance.

note

the cascadesparams function uses abcd-parameters. alternatively, one can use s-parameters and abcd-parameters (or t-parameters) to cascade s-parameters together by hand (assuming identical frequencies)

s_params= cascadesparams(___,kconn) creates the cascaded networks based on the number of cascaded connections between the networks specified by kconn. use this option with the input arguments in the previous syntax.

hs= cascadesparams(hs1,hs2,...,hsk) cascades k s-parameter objects to create a cascade network. the function checks that the impedance and frequencies of each object is equal and that the parameters of each object contain 2n-by-2n-by-m array of s-parameters for m frequency points.

examples

assemble a 2-port cascaded network from two sets of 2-port s-parameters operating at 2 ghz and at 2.1 ghz.

create two sets of 2-port s-parameters.

ckt1 = read(rfckt.amplifier,'default.s2p');
ckt2 = read(rfckt.passive,'passive.s2p');
freq = [2e9 2.1e9];
analyze(ckt1,freq);
analyze(ckt2,freq);
sparams_2p_1 = ckt1.analyzedresult.s_parameters;
sparams_2p_2 = ckt2.analyzedresult.s_parameters;

cascade the s-parameters.

sparams_cascaded_2p = cascadesparams(sparams_2p_1,sparams_2p_2)
sparams_cascaded_2p = 
sparams_cascaded_2p(:,:,1) =
  -0.4332   0.5779i   0.0081 - 0.0120i
   2.6434   1.2880i   0.5204 - 0.5918i
sparams_cascaded_2p(:,:,2) =
  -0.1271   0.3464i  -0.0004 - 0.0211i
   3.8700 - 0.6547i   0.4458 - 0.6250i

assemble a 3-port cascaded network from a set of 3-port s-parameters and a set of 2-port s-parameters.

three_port_cascade_network.png

create one set of 3-port s-parameters and one set of 2-port s-parameters.

ckt1 = read(rfckt.passive,'default.s3p');
ckt2 = read(rfckt.amplifier,'default.s2p');
freq = [2e9 2.1e9];
a1 = analyze(ckt1,freq);
a2 = analyze(ckt2,freq);
sparams_3p = sparameters(a1);
sparams_2p = sparameters(a2);

cascade the two sets by connecting one port between them.

kconn = 1;
sparams_cascaded_3p = cascadesparams(sparams_3p,sparams_2p,kconn)
sparams_cascaded_3p = 
  sparameters: s-parameters object
       numports: 3
    frequencies: [2x1 double]
     parameters: [3x3x2 double]
      impedance: 50
  rfparam(obj,i,j) returns s-parameter sij

assemble a 3-port cascaded network from a set of 3-port s-parameters and a set of 2-port s-parameters, connecting the second port of the 3-port network to the first port of the 2-port.

three_port_to_two_port_cascade_network.png

ckt1 = read(rfckt.passive,'default.s3p');
ckt2 = read(rfckt.amplifier,'default.s2p');
freq = [2e9 2.1e9];
a1 = analyze(ckt1,freq);
a2 = analyze(ckt2,freq);
sparams_3p = sparameters(a1);
sparams_2p = sparameters(a2);

reorder the second and third ports of the 3-port network

sparams_3p_2 = snp2smp(sparams_3p,[1 3 2]);

cascade the two sets by connecting one port between them

kconn = 1;
sparams_cascaded_3p_2 = cascadesparams(sparams_3p_2,...
     sparams_2p,kconn)
sparams_cascaded_3p_2 = 
  sparameters: s-parameters object
       numports: 3
    frequencies: [2x1 double]
     parameters: [3x3x2 double]
      impedance: 50
  rfparam(obj,i,j) returns s-parameter sij

assemble a 3-port cascaded network from a set of 3-port s-parameters and two sets of 2-port s-parameters.

cascade_multiple_sparams.png

ckt1 = read(rfckt.passive,'default.s3p');
ckt2 = read(rfckt.amplifier,'default.s2p');
ckt3 = read(rfckt.passive,'passive.s2p');
freq = [2e9 2.1e9];
a1 = analyze(ckt1,freq);
a2 = analyze(ckt2,freq);
a3 = analyze(ckt3,freq);
sparams_3p = sparameters(a1);
sparams_2p_1 = sparameters(a2);
sparams_2p_2 = sparameters(a3);

connect one port between each set of adjacent networks.

kconn = [1 1];
sparams_cascaded_3p_3 = cascadesparams(sparams_3p,...
     sparams_2p_1,sparams_2p_2,kconn)
sparams_cascaded_3p_3 = 
  sparameters: s-parameters object
       numports: 3
    frequencies: [2x1 double]
     parameters: [3x3x2 double]
      impedance: 50
  rfparam(obj,i,j) returns s-parameter sij

assemble a 3-port cascaded network from a set of 3-port s-parameters and two sets of 2-port s-parameters, connecting the 3-port network to both 2-port networks.

ckt1 = read(rfckt.passive,'default.s3p');
ckt2 = read(rfckt.amplifier,'default.s2p');
ckt3 = read(rfckt.passive,'passive.s2p');
freq = [2e9 2.1e9];
analyze(ckt1,freq);
analyze(ckt2,freq);
analyze(ckt3,freq);
sparams_3p = ckt1.analyzedresult.s_parameters;
sparams_2p_1 = ckt2.analyzedresult.s_parameters;
sparams_2p_2 = ckt3.analyzedresult.s_parameters;

cascade sparams_3p and sparams_2p_1 by connecting one port between them.

kconn = 1;
sparams_cascaded_3p = cascadesparams(sparams_3p, ...
  sparams_2p_1, kconn);

reorder the second and third ports of the 3-port network.

sparams_cascaded_3p_3 = snp2smp(sparams_cascaded_3p, ...
  50, [1 3 2]);

cascade sparams_3p and sparams_2p_2 by connecting one port between them.

sparams_cascaded_3p_4 = cascadesparams(sparams_cascaded_3p_3, ...
  sparams_2p_2, kconn)
sparams_cascaded_3p_4 = 
sparams_cascaded_3p_4(:,:,1) =
   0.1724 - 0.9106i   0.0240   0.0134i   0.0104   0.0971i
  -3.7923   6.1234i  -0.7168 - 0.6498i  -0.5855   1.6475i
   0.1214   0.0866i   0.0069   0.0090i   0.6289 - 0.6145i
sparams_cascaded_3p_4(:,:,2) =
  -0.3014 - 0.6620i   0.0072 - 0.0255i  -0.0162   0.1620i
   6.3709   2.2809i  -0.5349   0.3637i   1.4106   0.2587i
   0.0254   0.1011i   0.0087 - 0.0075i   0.5477 - 0.6253i

compute cascaded s-parameters using t-parameters.

t = tparameters('passive.s2p');
freq = t.frequencies;
for i = 1:length(freq)
    tcascade(:,:,i) = t.parameters(:,:,i)*t.parameters(:,:,i);
end
tcasc = tparameters(tcascade,freq);
scasc_t = sparameters(tcasc);
rfplot(scasc_t)

figure contains an axes object. the axes object with xlabel frequency (ghz), ylabel magnitude (db) contains 4 objects of type line. these objects represent db(s_{11}), db(s_{21}), db(s_{12}), db(s_{22}).

validate results using cascadesparams.

s = sparameters(t);
scasc = cascadesparams(s,s);
rfplot(scasc)

figure contains an axes object. the axes object with xlabel frequency (ghz), ylabel magnitude (db) contains 4 objects of type line. these objects represent db(s_{11}), db(s_{21}), db(s_{12}), db(s_{22}).

input arguments

s-parameters data, specified as a complex 2n-by-2n-by-m array.

s-parameter object, specified as a sparameters function object.

number of cascade connections, specified as a positive scalar or vector.

  • if kconn is a scalar, cascadesparams makes the same number of connections between each pair of consecutive networks.

  • if kconn is a vector, the ith element of kconn specifies the number of connections between the ith and the i 1th networks.

more about

port ordering

the function assumes that the port ordering of the network and it is shown in the image.

port order: 1,n,n 1, and 2n in a network

based on this ordering, the function connects ports n 1 through 2n of the first network to ports 1 through n of the second network. therefore, when you use this syntax:

  • each network has an even number of ports

  • every network in the cascade has the same number of ports.

to use this function for s-parameters with different port arrangements, use the snp2smp function to reorder the port indices before cascading the networks.

kconn

cascadesparams always connects the last kconn(i) ports of the ith network and the first kconn(i) ports of the i 1th network. the ports of the entire cascaded network represent the unconnected ports of each individual network, taken in order from the first network to the nth network.

also, when you specify kconn:

  • each network can have either an even or odd number of ports.

  • every network in the cascade can have a different number of ports.

version history

introduced in r2008a

see also

| | | |

网站地图