3. Full API Reference
3.1. Direct methods
|
Define a paramter of the active solver in term of new paramter(s) |
|
Add structure to the ones to be monitored for internal modes. |
|
Connect two structures in the active Solver |
|
Connect in the active solver the two structures using all the pins with the matching basename |
|
Set up and additional logfile for debug |
|
Function building a block diagonal array for list of array |
|
Switch log output to file |
|
Maps a pin of the current active solver |
Raise all pins in the solver. |
|
|
Set default parameters for the solver |
|
Solve active solver and returns the model |
Update default parameters for the solver |
3.2. Model
3.2.1. Base Models
|
Class Model |
|
Class for storing data of a solver mode. |
3.2.2. Methods
|
This function expands the model by adding additional modes. |
|
Function for returning complex amplitude of the transmission between two ports |
|
Function for returning the phase of the transmission between two ports |
|
Function for returning the energy transmission between two ports |
|
Returns the outputs from all ports of the model given the inputs amplitudes |
|
Parse the pins for locating the pins with the same base name |
Function that print self. |
|
|
Function for changing the names of the pins of a model |
|
Function for nice printing of scattering matrix in agreement with pins |
Check if the model is empty |
|
|
Function for putting a model in a Solver object, and eventually specify connections |
Function for printing pins of model |
|
|
Function for returning the solved model |
|
Update the parameters of model, setting defaults when value is not provides |
|
Function for returning transmission data between two ports |
|
Function for getting the output do the system given the inputs |
|
Function for returning data from monitors |
|
Methods for setting the function and mapping for monitors |
Returns the scattering matrix for all the solved parametes in form of padas DataFrame |
|
|
Export scattering matrix in InPulse format |
3.2.3. Functional Models
|
Model of attenuator in dB |
|
Model of variable ration beam splitter |
|
Simplified model of FPR circle mount |
|
Simplified model of FPR circle mount based on Gaussian beams. |
|
Model of Free Propagation Region. |
|
Model of attenuator in absolute unit |
|
Piecewise linear interpolator in N > 1 dimensions. |
|
Model of partially reflected Mirror |
|
Class for model from InPulse S-Matrix RAW DATA file |
|
Model of perfect mirror (only one port), 100% reflection |
|
Model of multimode variable phase shifter |
|
Model of a 2 modes polarization rotator |
Like partial, but keywords provided at creation cannot be overwritten al call time |
|
|
Model of multimode variable phase shifter |
Model of 1x2 Splitter |
|
|
Model of 1x2 Splitter with possible reflection between the 2 port side. |
|
Model of thermal phase shifter (dispersive waveguide + phase shifter) |
|
Template for a user defined waveguide |
|
Model of a simple waveguide |
3.3. Solver
|
Class Solver This class defines the simulations. |
3.3.2. Methods
Make the Solver the active solver |
|
|
Define a paramter of the solver in term of new paramter(s) |
|
Add a structure to the solver |
|
Connect two different structures in the solver by the specified pins |
|
Connect the two structures using all the pins with the matching basename |
|
Remove structure from solver, cutting all the connections to other structures (pins in connected structure are not removed, but freed again) |
Collapse the hyerarchycal structure of the solver in only one level. |
|
Flatten top level of a solver |
|
|
Print the full hierarchy of the solver |
|
Add mapping of pins |
Function for automatically map all pins. |
|
|
Add structure to the ones to be monitored for internal modes |
Remove dead branch in the solver hierarchy (the ones ending with an empy solver) |
|
|
Function for putting a Solver in another Solver object, and eventually specify connections |
|
Remove structure from solver, also removing all the connections to other structures |
|
Set a value for one parameter. |
Print all connected pins in the solver |
|
Print the names of all the top-level parameters and corresponding default value |
|
Print all pins of the structure in the solver whcih are not connected. |
|
If a pin mapping is defined, print only mapped pins |
|
Print all structures in the solver |
|
|
Calculates the scattering matrix of the solver |
|
Update the parameters of solver, setting defaults when value is not provides. |
3.4. Structure
|
Class defining a single element of the photonic circuit |
3.4.2. Methods
|
Add connection between a self pin and a pin in another structure |
|
Add pin to structure |
Creates the scattering matrix of the components |
|
Recreates the scattering matrix as ndarray |
|
|
Remove all connection to target structure. |
Find pins of self with are connected from a target structure |
|
|
Retunrn model corresponding to structure |
Find pins of self with are connected to a target structure |
|
|
Used to generate the function for monitoring the modes between two structures |
|
Join two structures to create the one cotaining the merged structure |
Alllows the feeding of the sintax structure.pin['pin_name'] where the tuple of structure and pin is required |
|
Print the connection of this structure to other ones |
|
Print the mappping between the pins and the entries of the scatterng matrix |
|
Print all pins of the structures, divided in self pins and contained pins |
|
|
Remove all connection to target structure. |
|
Remove pin from structure |
Reset the mapping that keeps track of the solving |
|
|
Divide pins to be connected providing inputs pins |
|
Divide pins to be connected providing output pins |
|
Created the scattering matrix object with left pins separated from right pins |
|
Updated the parametes dictionary of the represented optic componet |
3.5. S_matrix
|
Class implmenting the scattering matrix object and recursion alghoritms for joining two of them |
3.5.2. Methods
|
Print scattering matrix as numpy array |
|
Recursion algorith for joining two matrices |
Calculated determinat of scattering matrix |
|
|
Function for computing the internal modal coefficients between two structures |
Return scattering matrix as ndarray |
3.6. Pin
|
Class representing a pin in the circuit. |
3.6.2. Methods
|
Creates an pin in the solver and maps it to the given pin. |