:py:mod:`simcats.sensor` ======================== .. py:module:: simcats.sensor .. autoapi-nested-parse:: SimCATS subpackage containing all functionalities related to the sensor simulation. Subpackages ----------- .. toctree:: :titlesonly: :maxdepth: 3 barrier_function/index.rst deformation/index.rst Package Contents ---------------- Classes ~~~~~~~ .. autoapisummary:: simcats.sensor.SensorPeakInterface simcats.sensor.SensorRiseInterface simcats.sensor.SensorInterface simcats.sensor.SensorScanSensorInterface simcats.sensor.SensorPeakGaussian simcats.sensor.SensorPeakLorentzian simcats.sensor.SensorRiseGLF simcats.sensor.SensorGeneric simcats.sensor.SensorScanSensorGeneric Functions ~~~~~~~~~ .. autoapisummary:: :nosignatures: simcats.sensor.sensor_response_gauss simcats.sensor.sensor_response_lorentz Package Implementation Details ------------------------------ .. py:class:: SensorPeakInterface Bases: :py:obj:`abc.ABC` .. autoapi-inheritance-diagram:: simcats.sensor.SensorPeakInterface :parts: 1 Interface for all sensor peak functions, which are used to define the Coulomb Peaks of sensor dots for the simulation of CSDs. Implementations of the SensorInterface can consist of multiple peaks. .. py:property:: mu0 :type: Optional[float] :abstractmethod: Mu0 of the sensor peak. This property represents the potential value at which the sensor peak reaches its maximum. The method is needed for the generation of labels of scans. An example for that is the generation of labels for sensor scans. .. py:method:: sensor_function(mu_sens) :abstractmethod: This method has to be implemented in every object which should be used as sensor peak function during the simulation of CSDs. The electrochemical potential at the sensor should be given as one- or two-dimensional numpy array to this function. The parameters for this sensor peak function should be attributes of this class. This function should return the sensor (peak) values which result from the given electrochemical potential. :param mu_sens: The sensor potential, stored in a numpy array with the axis mapping to the CSD axis. :type mu_sens: np.ndarray :returns: The sensor response (for the corresponding peak), calculated from the given potential. It is stored in a numpy array with the axis mapping to the CSD axis. :rtype: np.ndarray .. py:class:: SensorRiseInterface Bases: :py:obj:`abc.ABC` .. autoapi-inheritance-diagram:: simcats.sensor.SensorRiseInterface :parts: 1 Interface for all sensor rise functions that model a final rise of the sensor response. This type of rise is needed to simulate the rise at the end of a sensor function, that can be observed in sensor scans. .. py:property:: fully_conductive :type: float :abstractmethod: Potential value of the point at which the sensor rise reaches its maximum. .. py:method:: sensor_function(mu_sens, offset) :abstractmethod: This method has to be implemented in every object which should be used as sensor rise function during the simulation of CSDs. This function should return the sensor (rise) values which result from the given electrochemical potential. :param mu_sens: The sensor potential, stored in a numpy array with the axis mapping to the scan axis. :type mu_sens: np.ndarray :param offset: Potential value to which the fully conductive point is shifted. :type offset: float :returns: The sensor response (for the corresponding rise), calculated from the given potential. It is stored in a numpy array with the axis mapping to the CSD axis. :rtype: np.ndarray .. py:class:: SensorInterface(sensor_peak_function, alpha_dot, alpha_gate, offset_mu_sens) Bases: :py:obj:`abc.ABC` .. autoapi-inheritance-diagram:: simcats.sensor.SensorInterface :parts: 1 Interface for all sensor functions, which are used in the simulation of CSDs. Initializes an object of the class for the simulation of the sensor response for a CSD. :param sensor_peak_function: An implementation of the SensorPeakInterface. It is also possible to supply a list of such peaks, if a sensor with multiple peaks should be simulated. :type sensor_peak_function: SensorPeakInterface :param alpha_dot: Lever-arm to the dots. The values should be negative. Influences the strengths of the edges in the CSD. :type alpha_dot: np.ndarray :param alpha_gate: Lever-arm to the double dot (plunger) gates. The values should be positive. :type alpha_gate: np.ndarray :param offset_mu_sens: Electrochemical potential of the sensor dot for zero electrons in the dots and no applied voltage at the gates. :type offset_mu_sens: float .. py:method:: sensor_response(mu_sens) :abstractmethod: This method has to be implemented in every object which should be used as sensor function during the simulation of CSDs. The electrochemical potential at the sensor should be given as one- or two-dimensional numpy array to this function. The parameters for this sensor function should be attributes of this class. This function should return the sensor response which result from the given electrochemical potential. :param mu_sens: The sensor potential, stored in a 2-dimensional numpy array with the axis mapping to the CSD axis. :type mu_sens: np.ndarray :returns: The sensor response, calculated from the given potential. It is stored in a numpy array with the axis mapping to the CSD axis. :rtype: np.ndarray .. py:method:: sensor_potential(occupations, volt_limits_g1, volt_limits_g2) :abstractmethod: Simulates the electrochemical potential at the sensing dot. This is done in dependency on the electron occupation in the double dot and the voltages applied at the double dot (plunger) gates. :param occupations: Occupation in left and right dot per applied voltage combination. The occupation numbers are stored in a 3-dimensional numpy array. The first two dimensions map to the axis of the CSD, while the third dimension indicates the dot of the corresponding occupation value. :type occupations: np.ndarray :param volt_limits_g1: Contains the beginning and ending of the swept range for the first (plunger) gate. :type volt_limits_g1: np.ndarray :param volt_limits_g2: Contains the beginning and ending of the swept range for the second (plunger) gate. :type volt_limits_g2: np.ndarray :returns: The electrochemical potential at the sensing dot. :rtype: np.ndarray .. py:class:: SensorScanSensorInterface(sensor_peak_function, alpha_dot, alpha_gate, alpha_sensor_gate, offset_mu_sens) Bases: :py:obj:`SensorInterface` .. autoapi-inheritance-diagram:: simcats.sensor.SensorScanSensorInterface :parts: 1 Interface for all sensor functions, which are used in the simulation of CSDs. This method initializes an object of the class SensorScanSensorInterface. :param sensor_peak_function: An implementation of the SensorPeakInterface. It is also possible to supply a list of such peaks, if a sensor with multiple peaks should be simulated. :type sensor_peak_function: Union[SensorPeakInterface, List[SensorPeakInterface], None] :param alpha_dot: Lever-arm of the dots for the sensor potential(s). The values should be negative. :type alpha_dot: np.ndarray :param alpha_gate: Lever-arm of the gates for the sensor potential(s). The values should be positive. :type alpha_gate: np.ndarray :param alpha_sensor_gate: Lever-arm of the sensor gates for the sensor potential(s). The values should be positive. :type alpha_sensor_gate: np.ndarray :param offset_mu_sens: Electrochemical potential of the sensor dot for zero electrons in the dots and no applied voltage at the gates. :type offset_mu_sens: np.ndarray .. py:method:: sensor_potential(occupations, volt_limits_g1, volt_limits_g2, volt_limits_sensor_g1, volt_limits_sensor_g2) :abstractmethod: Simulates the electrochemical potential at the sensor dot and both barriers. This is done in dependency on the electron occupation in the double dot, the voltages applied at the double dot (plunger) gates, and voltages applied at the gates of sensor. Either the double dot gates or the sensor gates can be swept. :param occupations: Occupation in left and right dot per applied voltage combination. The occupation numbers are stored in a 3-dimensional numpy array. The first two dimensions map to the axis of the CSD, while the third dimension indicates the dot of the corresponding occupation value. :type occupations: np.ndarray :param volt_limits_g1: Voltages applied to the first (plunger) gate of the double dot. When a fixed voltage is applied this is a float and when this gate should be swept it is a numpy array with the minimum and maximum of the sweep. :type volt_limits_g1: Union[np.ndarray, float, None] :param volt_limits_g2: Voltages applied to the second (plunger) gate of the double dot. When a fixed voltage is applied this is a float and when this gate should be swept it is a numpy array with the minimum and maximum of the sweep. :type volt_limits_g2: Union[np.ndarray, float, None] :param volt_limits_sensor_g1: Voltages applied to the first sensor gate. When a fixed voltage is applied this is a float and when this gate should be swept it is a numpy array with the minimum and maximum of the sweep. :type volt_limits_sensor_g1: Union[np.ndarray, float, None] :param volt_limits_sensor_g2: voltages applied to the second sensor gate. When a fixed voltage is applied this is a float and when this gate should be swept it is a numpy array with the minimum and maximum of the sweep. :type volt_limits_sensor_g2: Union[np.ndarray, float, None] :returns: The electrochemical potential of the sensor dot, and both barrier. It is returned as a three-dimensional array with the shape (3, occupations.shape[0], occupations.shape[1]). The first dimension corresponds to the three potentials involved. It is structured as follows: [sensor dot potential, barrier 1 potential, barrier 2 potential] The remaining two dimensions correspond to the swept voltages. :rtype: np.ndarray .. py:method:: get_sensor_scan_labels(volt_limits_g1, volt_limits_g2, volt_limits_sensor_g1, volt_limits_sensor_g2, potential) :abstractmethod: This method returns the labels of the sensor scans. There are two labels for sensor scans: the conductive area mask and the Coulomb peak mask. Both masks are numpy arrays that consist of integers. The conductive area mask marks the non-conductive area, sensor oscillation regime, and fully conductive area. The non-conductive area is marked with 0. This is the area in which no electron can tunnel or flow through the sensor dot. The sensor oscillation regime is the area in which the barriers are open enough for oscillations to occur, as electrons tunnel periodically. This area is marked with 1. In the third area, the conductive area, both barriers are fully open and transport occurs as a continuous current rather than through a well-defined sensor dot. The fully conductive area is marked with 2. The Coulomb peak mask marks the peaks of the Coulomb peak as integers. The wave fronts are marked with values higher or equal to one. All maxima belonging to the same Coulomb peak are marked with the same integer. Depending on the potential value, the various Coulomb peaks are marked with ascending values. :param volt_limits_g1: Voltages applied to the first double dot (plunger) gate. When a fixed voltage is applied this is a float and when this gate should be swept it is a numpy array with the minimum and maximum of the sweep. None can also be passed if no voltage is applied. :type volt_limits_g1: Union[np.ndarray, float, None] :param volt_limits_g2: Voltages applied to the second double dot(plunger) gate. When a fixed voltage is applied this is a float and when this gate should be swept it is a numpy array with the minimum and maximum of the sweep. None can also be passed if no voltage is applied. :type volt_limits_g2: Union[np.ndarray, float, None] :param volt_limits_sensor_g1: Voltages applied to the first sensor gate. When a fixed voltage is applied this is a float and when this gate should be swept it is a numpy array with the minimum and maximum of the sweep. None can also be passed if no voltage is applied. :type volt_limits_sensor_g1: Union[np.ndarray, float, None] :param volt_limits_sensor_g2: Voltages applied to the second sensor gate. When a fixed voltage is applied this is a float and when this gate should be swept it is a numpy array with the minimum and maximum of the sweep. None can also be passed if no voltage is applied. :type volt_limits_sensor_g2: Union[np.ndarray, float, None] :param potential: Numpy array that contains the potential of the area for which labels should be generated. This potential must correspond to the voltages specified for volt_limits_g1, volt_limits_g2, volt_limits_sensor_g1 and volt_limits_sensor_g2. :type potential: np.ndarray :returns: Tuple with the two numpy arrays of the two labels of sensor scan. The returned tuple looks like: (conductive area mask, coulomb peak mask). Both arrays have the same shape as the provided potential. :rtype: (np.ndarray, np.ndarray) .. py:method:: sensor_response(mu_sens) :abstractmethod: This method has to be implemented in every object which should be used as sensor function during the simulation of CSDs. The electrochemical potential at the sensor should be given as one- or two-dimensional numpy array to this function. The parameters for this sensor function should be attributes of this class. This function should return the sensor response which result from the given electrochemical potential. :param mu_sens: The sensor potential, stored in a 2-dimensional numpy array with the axis mapping to the CSD axis. :type mu_sens: np.ndarray :returns: The sensor response, calculated from the given potential. It is stored in a numpy array with the axis mapping to the CSD axis. :rtype: np.ndarray .. py:class:: SensorPeakGaussian(mu0 = 0, sigma = 1, height = 1, offset = 0) Bases: :py:obj:`simcats.sensor.SensorPeakInterface` .. autoapi-inheritance-diagram:: simcats.sensor.SensorPeakGaussian :parts: 1 This class contains the necessary parameters and methods for Gaussian sensor peak functions. Creates a new Gaussian sensor peak object. :param mu0: Position of the maximum of the Gaussian bell curve. Default is 0. :type mu0: float :param sigma: Influences the width of the Gaussian bell curve. Should always be greater than 0. Default is 1. :type sigma: float :param height: Scaling factor for the height of the Gaussian bell curve. Default is 1. :type height: float :param offset: Lowest (y-)value of the Gaussian bell curve. Default is 0. :type offset: float .. py:property:: mu0 :type: float Position of the maximum of the Gaussian bell curve. .. py:property:: sigma :type: float Influences the width of the Gaussian bell curve. Should always be greater than 0. .. py:property:: height :type: float Scaling factor for the height of the Gaussian bell curve. .. py:property:: offset :type: float Lowest (y-)value of the Gaussian bell curve. .. py:method:: sensor_function(mu_sens) Returns the sensor peak function values at the given electrochemical potentials. :param mu_sens: The sensor potential, stored in a numpy array with the axis mapping to the CSD axis. :type mu_sens: np.ndarray :returns: The sensor response (for the corresponding peak), calculated from the given potential. It is stored in a numpy array with the axis mapping to the CSD axis. :rtype: np.ndarray .. py:function:: sensor_response_gauss(mu_sens, mu0 = 0, sigma = 1, height = 1, offset = 0) Calculates the sensor response out of the given sensing dot potential by simulating the sensor behavior with a Gaussian function. :param mu_sens: The sensor potential, stored in a numpy array with the axis mapping to the CSD axis. :type mu_sens: np.ndarray :param mu0: Position of the maximum of the Gaussian bell curve. Default is 0. :type mu0: float :param sigma: Influences the width of the Gaussian bell curve. Should always be greater than 0. Default is 1. :type sigma: float :param height: Scaling factor for the height of the Gaussian bell curve. Default is 1. :type height: float :param offset: Lowest (y-)value of the Gaussian bell curve. Default is 0. :type offset: float :returns: The sensor response (for the corresponding peak), calculated from the given potential. It is stored in a numpy array with the axis mapping to the CSD axis. :rtype: np.ndarray .. py:class:: SensorPeakLorentzian(mu0 = 0, gamma = 1, height = 1, offset = 0) Bases: :py:obj:`simcats.sensor.SensorPeakInterface` .. autoapi-inheritance-diagram:: simcats.sensor.SensorPeakLorentzian :parts: 1 Lorentzian sensor peak function implementation of the SensorPeakInterface. Creates a new Lorentzian sensor peak object. :param mu0: Position of the maximum of the Lorentz curve. Default is 0. :type mu0: float :param gamma: The gamma of the Lorentzian. Influences the width of the Lorentz curve. Default is 1. :type gamma: float :param height: Scaling factor for the height of the Lorentz curve. Default is 1. :type height: float :param offset: Lowest (y-)value of the Lorentz curve. Default is 0. :type offset: float .. py:property:: mu0 :type: float Position of the maximum of the Lorentz curve. .. py:property:: gamma :type: float The gamma of the Lorentzian. Influences the width of the Lorentz curve. .. py:property:: height :type: float Scaling factor for the height of the Lorentz curve. .. py:property:: offset :type: float Lowest (y-)value of the Lorentz curve. .. py:method:: sensor_function(mu_sens) Returns the sensor peak function values at the given electrochemical potentials. :param mu_sens: The sensor potential, stored in a numpy array with the axis mapping to the CSD axis. :type mu_sens: np.ndarray :returns: The sensor response (for the corresponding peak), calculated from the given potential. It is stored in a numpy array with the axis mapping to the CSD axis. :rtype: np.ndarray .. py:function:: sensor_response_lorentz(mu_sens, mu0 = 0, gamma = 1, height = 1, offset = 0) Calculates the sensor response out of the given sensing dot potential by simulating the sensor behavior with a Lorentz function. :param mu_sens: The sensor potential, stored in a numpy array with the axis mapping to the CSD axis. :type mu_sens: np.ndarray :param mu0: Position of the maximum of the Lorentz curve. Default is 0. :type mu0: float :param gamma: The gamma of the Lorentzian. Influences the width of the Lorentz curve. Default is 1. :type gamma: float :param height: Scaling factor for the height of the Lorentz curve. Default is 1. :type height: float :param offset: Lowest (y-)value of the Lorentz curve. Default is 0. :type offset: float :returns: The sensor response (for the corresponding peak), calculated from the given potential. It is stored in a numpy array with the axis mapping to the CSD axis. :rtype: np.ndarray .. py:class:: SensorRiseGLF(mu0, asymptote_left, asymptote_right, growth_rate, asymmetry, shape_factor, denominator_offset = 1, fully_conductive_percentage = 0.99) Bases: :py:obj:`simcats.sensor.SensorRiseInterface` .. autoapi-inheritance-diagram:: simcats.sensor.SensorRiseGLF :parts: 1 This class realizes the SensorRiseInterface using a GLF. For further information on the GLF see: https://en.wikipedia.org/wiki/Generalised_logistic_function. Creates a new GLF sensor rise function. :param mu0: Potential shift of the GLF from the zero point. If the offset is positive, the function is shifted to the right and if it is negative, it is shifted to the left. :type mu0: float :param asymptote_left: Originally called A. This parameter is the left horizontal asymptote of the function. Any rational number can be used as the left asymptote. :type asymptote_left: float :param asymptote_right: Originally called K. Specifies the right horizontal asymptote of the function when denominator_offset=1. If asymptote_left=0 and denominator_offset=1 then this parameter is also called the carrying capacity. This parameter may take any rational number. :type asymptote_right: float :param growth_rate: Originally called B. The growth rate of the function. The value must be a float and can be any rational number. Be careful with negative values, because the function is mirrored on a vertical straight line for these. This line passes through the point where the potential equals `offset`. :type growth_rate: float :param asymmetry: Originally called nu. This parameter introduces skew and affects symmetry. It also affects near which asymptote maximum growth occurs. The value of asymmetry must be a rational number greater than zero. - `asymmetry > 1`: the curve rises more gradually before the midpoint and more sharply after. - `asymmetry < 1`: the curve rises quickly early on and levels off more slowly. :type asymmetry: float :param shape_factor: Originally called Q. is related to the value Y(0) and adjusts the curve’s value at the y-intercept. Thereby it changes the shape of the function without changing the asymptotes. The shape factor can be any rational number. :type shape_factor: float :param denominator_offset: Originally called C. A constant added to the denominator inside the power. Controls the initial level of the denominator.This parameter must be a rational number. It typically takes a value of 1. Otherwise, the upper asymptote is asymptote_left + (asymptote_right-asymptote_left)/(denominator_offset^(1/asymmetry)). :type denominator_offset: float .. py:property:: mu0 Potential shift of the GLF from the zero point. If mu0 is positive, the function is shifted to the right and if it is negative, it is shifted to the left. .. py:property:: asymptote_left Originally called A. This parameter is the left horizontal asymptote of the function. Any rational number can be used as the left asymptote. .. py:property:: asymptote_right Originally called K. Specifies the right horizontal asymptote of the function when denominator_offset=1. If asymptote_left=0 and denominator_offset=1 then this parameter is also called the carrying capacity. This parameter may take any rational number. .. py:property:: growth_rate Originally called B. The growth rate of the function. The value must be a float and can be any rational number. Be careful with negative values, because the function is mirrored on a vertical straight line for these. This line passes through the point where the potential equals `offset`. .. py:property:: asymmetry Originally called nu. This parameter introduces skew and affects symmetry. It also affects near which asymptote maximum growth occurs. The value of asymmetry must be a rational number greater than zero. - `asymmetry > 1`: the curve rises more gradually before the midpoint and more sharply after. - `asymmetry < 1`: the curve rises quickly early on and levels off more slowly. .. py:property:: shape_factor Originally called Q. is related to the value Y(0) and adjusts the curve’s value at the y-intercept. Thereby it changes the shape of the function without changing the asymptotes. The shape factor can be any rational number. .. py:property:: denominator_offset :type: float Originally called C. A constant added to the denominator inside the power. Controls the initial level of the denominator. This parameter must be a rational number. It typically takes a value of 1. Otherwise, the upper asymptote is asymptote_left + (asymptote_right-asymptote_left)/(denominator_offset^(1/asymmetry)). .. py:attribute:: fully_conductive_percentage .. py:property:: fully_conductive :type: float Potential value of the point at which the sensor rise reaches its maximum. .. py:method:: sensor_function(mu_sens, offset) Returns the sensor rise function values at the given electrochemical potentials. :param mu_sens: The sensor potential, stored in a numpy array with the axis mapping to the scan axis. :type mu_sens: np.ndarray :param offset: Potential value to which the fully conductive point is shifted. :type offset: float :returns: The sensor response (for the corresponding peak), calculated from the given potential. It is stored in a numpy array with the axis mapping to the scan axis. :rtype: np.ndarray .. py:class:: SensorGeneric(sensor_peak_function = None, alpha_dot = np.array([-1, -1]), alpha_gate = np.array([0, 0]), offset_mu_sens = 0) Bases: :py:obj:`simcats.sensor.SensorInterface` .. autoapi-inheritance-diagram:: simcats.sensor.SensorGeneric :parts: 1 Generic implementation of the SensorInterface. Initializes an object of the class for the simulation of the sensor response for a CSD. :param sensor_peak_function: An implementation of the SensorPeakInterface. It is also possible to supply a list of such peaks, if a sensor with multiple peaks should be simulated. Default is None. :type sensor_peak_function: Union[SensorPeakInterface, List[SensorPeakInterface], None] :param alpha_dot: Lever-arm to the dots. The values should be negative. Influences the strengths of the edges in the CSD. Default is np.array([-1, -1]). :type alpha_dot: np.ndarray :param alpha_gate: Lever-arm to the double dot (plunger) gates. The values should be positive. Default is np.array([0, 0]). :type alpha_gate: np.ndarray :param offset_mu_sens: Electrochemical potential of the sensor dot for zero electrons in the dots and no applied voltage at the gates. Default is 0. :type offset_mu_sens: float .. py:property:: sensor_peak_function :type: Union[simcats.sensor.SensorPeakInterface, List[simcats.sensor.SensorPeakInterface], None] Returns the current sensor peak function configuration of the sensor. This configuration can then be adjusted and is directly used as new configuration, as the object is returned as call by reference. :returns: A list of SensorPeakInterface implementations. :rtype: list[SensorPeakInterface] .. py:property:: alpha_dot :type: numpy.ndarray Returns the current alpha dot (dot lever-arm) configuration of the sensor. This configuration can then be adjusted and is directly used as new configuration, as the object is returned as call by reference. :returns: Lever-arm to the dots. Influences the strengths of the edges in the CSD. :rtype: np.ndarray .. py:property:: alpha_gate :type: numpy.ndarray Returns the current alpha gate (gate lever-arm) configuration of the sensor. This configuration can then be adjusted and is directly used as new configuration, as the object is returned as call by reference. :returns: Lever-arm to the double dot (plunger) gates. :rtype: np.ndarray .. py:property:: offset_mu_sens :type: float Returns the current offset_mu_sens configuration of the sensor. This configuration can then be adjusted and set as new configuration. :returns: Electrochemical potential of the sensor dot for zero electrons in the dots and no applied voltage at the gates. :rtype: float .. py:method:: sensor_response(mu_sens) This function returns the sensor values which result from the given electrochemical potential. If no sensor peak is defined, the potential is returned (acting like a "linear sensor"). :param mu_sens: The sensor potential, stored in a 2-dimensional numpy array with the axis mapping to the CSD axis. :type mu_sens: np.ndarray :returns: The sensor response, calculated from the given potential. It is stored in a numpy array with the axis mapping to the CSD axis. :rtype: np.ndarray .. py:method:: sensor_potential(occupations, volt_limits_g1, volt_limits_g2) Simulates the electrochemical potential at the sensing dot. This is done in dependency on the electron occupation in the double dot and the voltages applied at the double dot (plunger) gates. :param occupations: Occupation in left and right dot per applied voltage combination. The occupation numbers are stored in a 3-dimensional numpy array. The first two dimensions map to the axis of the CSD, while the third dimension indicates the dot of the corresponding occupation value. :type occupations: np.ndarray :param volt_limits_g1: Contains the beginning and ending of the swept range for the first (plunger) gate. :type volt_limits_g1: np.ndarray :param volt_limits_g2: Contains the beginning and ending of the swept range for the second (plunger) gate. :type volt_limits_g2: np.ndarray :returns: The electrochemical potential at the sensing dot :rtype: np.ndarray .. py:class:: SensorScanSensorGeneric(barrier_functions, sensor_peak_function, alpha_sensor_gate, alpha_gate = np.array([[0, 0], [0, 0], [0, 0]]), alpha_dot = np.array([[0, 0], [0, 0], [0, 0]]), offset_mu_sens = np.array([0, 0, 0]), final_rise = None, sensor_peak_deformations = {}) Bases: :py:obj:`simcats.sensor.SensorScanSensorInterface` .. autoapi-inheritance-diagram:: simcats.sensor.SensorScanSensorGeneric :parts: 1 Generic implementation of the SensorScanSensorInterface. Initializes an object of the class for the simulation of the sensor response for a sensor scan. :param barrier_functions: Barrier functions model the responses of the barriers. :type barrier_functions: Union[BarrierFunctionInterface, Tuple[BarrierFunctionInterface, BarrierFunctionInterface]] :param sensor_peak_function: An implementation of the SensorPeakInterface. It is also possible to supply a list of such peaks, if a sensor with multiple peaks should be simulated. :type sensor_peak_function: Union[SensorPeakInterface, List[SensorPeakInterface], None] :param alpha_dot: Lever-arm of the dots on the sensor potential. With these, the influence of the occupation of the two dots on the three potentials (sensor dot, barrier1, and barrier2) is specified. The lever-arms are specified as follows np.array([lever-arms sensor dot, lever-arms barrier1, lever-arms barrier2]). The individual three lever-arms are each specified as a numpy array. The first value describes the influence of the electron occupation of the first dot on the corresponding potential and the second the influence of the electron occupation of the second dot. The values should be negative. The default value is np.array([[0, 0], [0, 0], [0, 0]]). The lever-arms can also be passed as a numpy array with two elements. The lever-arms are then used for the influence on all three potentials. If None is passed instead of a numpy array the default value of np.array([[0, 0], [0, 0], [0, 0]]) is used. :type alpha_dot: np.ndarray :param alpha_gate: Lever-arms of the double dot (plunger) gates to the three potentials (sensor dot, barrier1, and barrier2). The values should be positive. The lever-arms are specified as follows np.array([lever-arms sensor dot, lever-arms barrier1, lever-arms barrier2]). The individual three lever-arms are each specified as a numpy array with two elements. The first value describes the influence of the voltage of the (plunger) gate of the first dot on the potential, with the second value defined analogously for the (plunger) gate of the second dot. Default is np.array([[0, 0], [0, 0], [0, 0]]). The lever-arms can also be passed as a numpy array with two elements. The lever-arms are then used for the influence on all three potentials. If None is passed instead of a numpy array the default value of np.array([[0, 0], [0, 0], [0, 0]]) is used. :type alpha_gate: np.ndarray :param alpha_sensor_gate: Lever-arms of the sensor dot gates to the three potentials (sensor dot, barrier1, and barrier2). The values should be positive. The lever-arms are specified as follows np.array([lever-arms sensor dot, lever-arms barrier1, lever-arms barrier2]). The individual three lever-arms are each specified as a numpy array with two elements. The first value describes the influence of the voltage of the first gate of the sensor dot to the potential and analogously for the second. :type alpha_sensor_gate: np.ndarray :param offset_mu_sens: Offset of the electrochemical potential of the three potentials (sensor dot, barrier1, and barrier2). This offset can have various causes. :type offset_mu_sens: np.ndarray :param final_rise: An implementation of the SensorRiseInterface interface. This interface represents the rise of the sensor function to the maximum sensor response when both barriers are open. This rise is also shifted so that it fits appropriately with the open barriers. The default value is None. If None is used, no rise is added to the sensor function. :type final_rise: Optional[SensorRiseInterface] :param sensor_peak_deformations Dict[int: Dictionary that specifies the deformations of the wavefronts. The key of the dictionary is an integer that specifies the wavefront to which the deformation belongs. This value refers to the wavefront number as listed in sensor_peak_function. The value of the dictionary is the actual deformation object used for a wavefront. :param SensorPeakDeformationInterface]: Dictionary that specifies the deformations of the wavefronts. The key of the dictionary is an integer that specifies the wavefront to which the deformation belongs. This value refers to the wavefront number as listed in sensor_peak_function. The value of the dictionary is the actual deformation object used for a wavefront. .. py:property:: sensor_peak_function :type: Union[simcats.sensor.SensorPeakInterface, List[simcats.sensor.SensorPeakInterface], None] Returns the current sensor peak function configuration of the sensor. This configuration can then be adjusted and is directly used as a new configuration, as the object is returned as call by reference. :returns: A list of SensorPeakInterface implementations. :rtype: list[SensorPeakInterface] .. py:attribute:: sensor_peak_deformations .. py:property:: final_rise :type: Optional[simcats.sensor.SensorRiseInterface] Returns the current sensor rise configuration of the sensor. This configuration can then be adjusted and is directly used as a new configuration, as the object is returned as call by reference. :returns: An implementation of the SensorRiseInterface interface. This interface represents the rise of the sensor function to the maximum sensor response when both barriers are open. Can also return None, if no final rise is used. :rtype: Optional[SensorRiseInterface] .. py:property:: alpha_dot :type: numpy.ndarray Returns the current alpha dot (dot lever-arms) configuration of the sensor. With these, the influence of the occupation of the two dots on the three potentials (sensor dot, barrier1, and barrier2) is specified. The lever-arms are specified as follows np.array([lever-arms sensor dot, lever-arms barrier1, lever-arms barrier2]). The individual three lever-arms are each specified as a numpy array with two elements. The first value describes the influence of the electron occupation of the first dot on the corresponding potential and the second the influence of the electron occupation of the second dot. The values should be negative. :returns: The three pairs of alpha dot lever-arms as a numpy array. The numpy array has the shape (3,2). :rtype: np.ndarray .. py:property:: alpha_gate :type: numpy.ndarray Returns the alpha gate (gate lever-arms) configuration of the sensor. Lever-arms of the double dot (plunger) gates to the three potentials (sensor dot, barrier1, and barrier2). The values should be positive. The lever-arms are specified as follows np.array([lever-arms sensor dot, lever-arms barrier1, lever-arms barrier2]). The individual three lever-arms are each specified as a numpy array with two elements. The first value describes the influence of the voltage of the (plunger) gate of the first dot on the potential, with the second value defined analogously for the (plunger) gate of the second dot. :returns: Returns the three pairs of alpha gate lever-arms as a numpy array. The numpy array has the shape (3,2). .. py:property:: alpha_sensor_gate :type: numpy.ndarray Returns the alpha sensor gate (sensor gate lever-arms) configuration of the sensor. With theses the influence of the sensor dot gates to the three potentials (sensor dot, barrier1, and barrier2) is specified. The values should be positive. The lever-arms are specified as follows np.array([lever-arms sensor dot, lever-arms barrier1,lever-arms barrier2]). The individual three lever-arms are each specified as a numpy array with two elements. The first value describes the influence of the voltage of the first gate of the sensor dot to the potential and analogously for the second. :returns: Returns the three pairs of alpha sensor gate lever-arms as a numpy array. The numpy array has the shape (3,2). .. py:property:: offset_mu_sens :type: numpy.ndarray Returns the current offset_mu_sens configuration of the sensor. This configuration can then be adjusted and set as new configuration. :returns: Electrochemical potential offset of the sensor dot and both barriers for zero electrons in the dots and no applied voltage at the gates. The first element contains the sensor dot offset, the second the offset of the potential of barrier 1 and last the offset of barrier 2 :rtype: np.ndarray .. py:property:: barrier_functions :type: Tuple[simcats.sensor.barrier_function._barrier_function_interface.BarrierFunctionInterface, simcats.sensor.barrier_function._barrier_function_interface.BarrierFunctionInterface] This function returns the barrier functions. :returns: Current barrier functions. :rtype: Tuple[BarrierFunctionInterface, BarrierFunctionInterface] .. py:method:: sensor_response(mu_sens) This function returns the sensor response for a given electrochemical potential. :param mu_sens: The given sensor potential. :type mu_sens: np.ndarray :returns: The response, calculated from the given potential. It is stored in a numpy array with the axis mapping to the CSD axis. For a two-dimensional scan the response is a two-dimensional numpy array and for a one-dimensional scan it is a one-dimensional numpy array. :rtype: np.ndarray .. py:method:: sensor_potential(occupations, volt_limits_g1 = None, volt_limits_g2 = None, volt_limits_sensor_g1 = None, volt_limits_sensor_g2 = None) Calculates the electrochemical potential at the sensor dot and both barriers. This is done in dependency on the electron occupation in the double dot, the voltages applied at the double dot (plunger) gates, and voltages applied at the gates of sensor. Either the double dot gates or the sensor gates can be swept. :param occupations: Occupation in left and right dot per applied voltage combination. The occupation numbers are stored in a 3-dimensional numpy array. The first two dimensions map to the axis of the CSD, while the third dimension indicates the dot of the corresponding occupation value. :type occupations: np.ndarray :param volt_limits_g1: Voltages applied to the first (plunger) gate of the double dot. When a fixed voltage is applied this is a float and when this gate should be swept it is a numpy array with the minimum and maximum of the sweep. :type volt_limits_g1: Union[np.ndarray, float, None] :param volt_limits_g2: Voltages applied to the second (plunger) gate of the double dot. When a fixed voltage is applied this is a float and when this gate should be swept it is a numpy array with the minimum and maximum of the sweep. :type volt_limits_g2: Union[np.ndarray, float, None] :param volt_limits_sensor_g1: Voltages applied to the first sensor gate. When a fixed voltage is applied this is a float and when this gate should be swept it is a numpy array with the minimum and maximum of the sweep. :type volt_limits_sensor_g1: Union[np.ndarray, float, None] :param volt_limits_sensor_g2: voltages applied to the second sensor gate. When a fixed voltage is applied this is a float and when this gate should be swept it is a numpy array with the minimum and maximum of the sweep. :type volt_limits_sensor_g2: Union[np.ndarray, float, None] :returns: The electrochemical potential of the sensor dot, and both barrier. It is returned as a three-dimensional array with the shape (3, occupations.shape[0], occupations.shape[1]). The first dimension corresponds to the three potentials involved. It is structured as follows: [sensor dot potential, barrier 1 potential, barrier 2 potential] The remaining two dimensions correspond to the swept voltages. :rtype: np.ndarray .. py:method:: get_sensor_scan_labels(volt_limits_g1, volt_limits_g2, volt_limits_sensor_g1, volt_limits_sensor_g2, potential) This method returns the labels of the sensor scans. There are two labels for sensor scans: the conductive area mask and the Coulomb peak mask. Both masks are numpy arrays that consist of integers. The conductive area mask marks the non-conductive area, sensor oscillation regime, and fully conductive area. The non-conductive area is marked with 0. This is the area in which no electron can tunnel or flow through the sensor dot. The sensor oscillation regime is the area in which the barriers are open enough for oscillations to occur, as electrons tunnel periodically. This area is marked with 1. In the third area, the conductive area, both barriers are fully open and transport occurs as a continuous current rather than through a well-defined sensor dot. The fully conductive area is marked with 2. The Coulomb peak mask marks the peaks of the Coulomb peak as integers. The wave fronts are marked with values higher or equal to one. All maxima belonging to the same Coulomb peak are marked with the same integer. Depending on the potential value, the various Coulomb peaks are marked with ascending values. :param volt_limits_g1: Voltages applied to the first double dot (plunger) gate. When a fixed voltage is applied this is a float and when this gate should be swept it is a numpy array with the minimum and maximum of the sweep. None can also be passed if no voltage is applied. Currently supports only scalar input (`float`) or `None`. Array input is reserved for future sweep functionality. :type volt_limits_g1: Union[np.ndarray, float, None] :param volt_limits_g2: Voltages applied to the second double dot(plunger) gate. When a fixed voltage is applied this is a float and when this gate should be swept it is a numpy array with the minimum and maximum of the sweep. None can also be passed if no voltage is applied. Currently supports only scalar input (`float`) or `None`. Array input is reserved for future sweep functionality. :type volt_limits_g2: Union[np.ndarray, float, None] :param volt_limits_sensor_g1: Voltages applied to the first sensor gate. When a fixed voltage is applied this is a float and when this gate should be swept it is a numpy array with the minimum and maximum of the sweep. None can also be passed if no voltage is applied. :type volt_limits_sensor_g1: Union[np.ndarray, float, None] :param volt_limits_sensor_g2: Voltages applied to the second sensor gate. When a fixed voltage is applied this is a float and when this gate should be swept it is a numpy array with the minimum and maximum of the sweep. None can also be passed if no voltage is applied. :type volt_limits_sensor_g2: Union[np.ndarray, float, None] :param potential: Numpy array that contains the potential of the area for which labels should be generated. This potential must correspond to the voltages specified for volt_limits_g1, volt_limits_g2, volt_limits_sensor_g1 and volt_limits_sensor_g2. :type potential: np.ndarray :returns: Tuple with the two numpy arrays of the two labels of sensor scan. The returned tuple looks like: (conductive area mask, coulomb peak mask). Both arrays have the same shape as the provided potential. :rtype: (np.ndarray, np.ndarray)