twpasolver.analysis.ports module#

Connectors between the TWPA and the external lines.

pydantic model twpasolver.analysis.ports.Ports[source]#

Bases: BaseModel

Connectors at the device ends and the impedance of the external lines.

Port 1 of a connector faces the external line, port 2 the TWPA. Without connectors the device is joined directly to lines of impedance Z_ext.

Show JSON schema
{
   "title": "Ports",
   "description": "Connectors at the device ends and the impedance of the external lines.\n\nPort 1 of a connector faces the external line, port 2 the TWPA. Without\nconnectors the device is joined directly to lines of impedance ``Z_ext``.",
   "type": "object",
   "properties": {
      "input": {
         "default": null,
         "description": "Connector (``TwoPortModel``) at x=0; also used at x=L when ``output`` is None.",
         "title": "Input"
      },
      "output": {
         "default": null,
         "description": "Connector at x=L.",
         "title": "Output"
      },
      "Z_ext": {
         "default": 50.0,
         "description": "Impedance of the external lines (e.g. the fridge coaxial lines).",
         "title": "Z Ext",
         "type": "number"
      }
   },
   "additionalProperties": false
}

Fields:
Validators:
  • _accept_model_as_is » input

  • _accept_model_as_is » output

field input: Any = None#

Connector (TwoPortModel) at x=0; also used at x=L when output is None.

Validated by:
  • _accept_model_as_is

field output: Any = None#

Connector at x=L.

Validated by:
  • _accept_model_as_is

field Z_ext: float = 50.0#

Impedance of the external lines (e.g. the fridge coaxial lines).

tables(freqs_hz: ndarray) → tuple[numpy.ndarray, ...][source]#

Boundary tables of the forward-backward solver at the mode frequencies.

Parameters:

freqs_hz – Mode frequencies in Hz, shape (n_freq, n_modes).

Returns:

impedance (D Ze + B) / (C Ze + A) seen by the device at x=0 and x=L, shape (n_freq, n_modes); abcd_in, abcd_out: [A, B, C, D] of the connectors, shape (n_freq, n_modes, 4). Without a connector the tables are the identity and Zout = Ze.

Return type:

Zout_in, Zout_out