skrf.network.concat_ports

skrf.network.concat_ports(ntwk_list, port_order='second', *args, **kw)[source]

Concatenate networks along the port axis

Notes

The port_order =’first’, means front-to-back, while port_oder`=’second’ means left-to-right. So, for example, when concating two 2-networks, `A and B, the ports are ordered as follows:

‘first’
a0 o—o a1 -> 0 o—o 1 b0 o—o b1 -> 2 o—o 3
‘second’
a0 o—o a1 -> 0 o—o 2 b0 o—o b1 -> 1 o—o 3

use Network.renumber to change port ordering.

Parameters:
  • ntwk_list (list of skrf.Networks) – ntwks to concatenate
  • port_order (['first', 'second']) –

Examples

>>>concat([ntwkA,ntwkB]) >>>concat([ntwkA,ntwkB,ntwkC,ntwkD], port_order=’second’)

To put for lines in parallel >>> from skrf import air >>> l1 = air.line(100, z0=[0,1]) >>> l2 = air.line(300, z0=[2,3]) >>> l3 = air.line(400, z0=[4,5]) >>> l4 = air.line(400, z0=[6,7]) >>> concat_ports([l1,l2,l3,l4], port_order=’second’)

See also

stitch()
concatenate two networks along the frequency axis
renumber()
renumber ports