Quantcast

Documentation Center

  • Trial Software
  • Product Updates

snp2smp

Convert single-ended N-port S-parameters to single-ended M-port S-parameters

Syntax

s_params_mp = snp2smp(s_params_np)
s_params_mp = snp2smp(s_params_np,Z0,n2m_index,ZT)

Description

s_params_mp = snp2smp(s_params_np) converts the single-ended N-port S-parameters, s_params_np, into the single-ended M-port S-parameters, s_params_mp. M must be less than or equal to N.

s_params_mp = snp2smp(s_params_np,Z0,n2m_index,ZT) converts the S-parameter data using the optional arguments Z0, n2m_index, and ZT that control the conversion.

The following figure illustrates how to use the optional input arguments to specify the ports for the output data and the termination of the remaining ports.

Input Arguments

s_params_np

s_params_np is a complex N-by-N-by-K array representing K N-port S-parameters.

Z0

Z0 is the reference impedance, in ohms, of s_params_np and s_params_mp.

Default: 50

n2m_index

n2m_index is a vector of length M specifying how the ports of the N-port S-parameters map to the ports of the M-port S-parameters. n2m_index(i) is the index of the port from s_params_np that the function converts to the ith port of s_params_mp. For example, the setting [1, 2] means that M is 2, and the first two ports of the N-port S-parameters become the ports of the M-port parameters. The function terminates any additional ports with the impedances specified by ZT.

Default: [1, 2]

ZT

ZT is a scalar, vector, or cell array specifying the termination impedance of the ports. If M is less than N, snp2smp terminates the NM ports not listed in n2m_index using the values in ZT. If ZT is a scalar, the function terminates all NM ports not listed in n2m_index by the same impedance ZT. If ZT is a vector of length K, ZT[i] is the impedance that terminates all NM ports of the ith frequency point not listed in n2m_index. If ZT is a cell array of length N, ZT{j} is the impedance that terminates the jth port of the N-port S-parameters. The function ignores impedances related to the ports listed in n2m_index. Each ZT{j} can be a scalar or a vector of length K.

The following figure illustrates how to use the optional input arguments to specify the ports for the output data and the termination of the remaining ports.

Default: Z0

Examples

Convert 3-port S-parameters to 3-port S-parameters with port indices swapped from [1 2 3] to [2 3 1]:

ckt = read(rfckt.passive,'default.s3p');
%default.s3p represents a real counterclockwise circulator
s3p = ckt.NetworkData.Data;
Z0 = ckt.NetworkData.Z0;
s3p_new = snp2smp(s3p,Z0,[2 3 1])

Convert 3-port S-parameters to 2-port S-parameters by terminating port 3 with an impedance of Z0:

ckt = read(rfckt.passive,'default.s3p');
s3p = ckt.NetworkData.Data;
Z0 = ckt.NetworkData.Z0;
s2p = snp2smp(s3p,Z0);

Convert 16-port S-parameters to 4-port S-parameters by using ports 1, 16, 2, and 15 as the first, second, third, and fourth ports; terminate the remaining 12 ports with an impedance of Z0:

ckt = read(rfckt.passive,'default.s16p');
s16p = ckt.NetworkData.Data;
Z0 = ckt.NetworkData.Z0;
s4p = snp2smp(s16p,Z0,[1 16 2 15],Z0)

Convert 16-port S-parameters to 4-port S-parameters by using ports 1, 16, 2, and 15 as the first, second, third, and fourth ports; terminate port 4 with an impedance of 100 ohms and terminate the remaining 11 ports with an impedance of 50 ohms:

ckt = read(rfckt.passive,'default.s16p');
s16p = ckt.NetworkData.Data;
Z0 = ckt.NetworkData.Z0;
ZT = {}; 
ZT(1:16) = {50};
ZT{4} = 100;
s4p = snp2smp(s16p,Z0,[1 16 2 15],ZT)

See Also

| | | |

Was this topic helpful?