create_sawtooth_current#

create_sawtooth_current(
n_pools: int,
t_points: int,
timestep__ms: Quantity__ms,
amplitudes__nA: Quantity__nA | list[Quantity__nA],
frequencies__Hz: Quantity__Hz | list[Quantity__Hz],
offsets__nA: Quantity__nA | list[Quantity__nA] = 0.0 * pq.nA,
widths__ratio: float | list[float] = 0.5,
phases__rad: Quantity__rad | list[Quantity__rad] = 0.0 * pq.rad,
) s]][source]#

Create a matrix of sawtooth currents for multiple pools.

Parameters:
  • n_pools (int) – Number of current pools to generate

  • t_points (int) – Number of time points

  • timestep__ms (Quantity__ms) – Time step in milliseconds as a Quantity

  • amplitudes__nA (Quantity__nA | list[Quantity__nA]) –

    Amplitude(s) of the sawtooth current(s) in nanoamperes.

    Must be:
    • Single Quantity: used for all pools

    • List of Quantities: must match n_pools

  • frequencies__Hz (Quantity__Hz | list[Quantity__Hz]) –

    Frequency(s) of the sawtooth current(s) in Hertz.

    Must be:
    • Single Quantity: used for all pools

    • List of Quantities: must match n_pools

  • offsets__nA (Quantity__nA | list[Quantity__nA]) –

    DC offset(s) to add to the sawtooth current(s) in nanoamperes.

    Must be:
    • Single Quantity: used for all pools

    • List of Quantities: must match n_pools

  • widths__ratio (float | list[float]) –

    Width(s) of the rising edge as proportion of period (0 to 1).

    Must be:
    • Single float: used for all pools

    • List of floats: must match n_pools

  • phases__rad (Quantity__rad | list[Quantity__rad]) –

    Phase(s) of the sawtooth current(s) in radians.

    Must be:
    • Single Quantity: used for all pools

    • List of Quantities: must match n_pools

Raises:

ValueError – If the parameters are lists and the length of the parameters does not match n_pools

Returns:

Analog signal of shape (t_points, n_pools) * pq.nA containing sawtooth currents

Return type:

INPUT_CURRENT__AnalogSignal