Piecewise Linear Function

Construct me with 2-3 arguments. Two arguments are sequences or Numpy 1-D array of X, Y values, dependent on TIME, the transient simulation time in seconds. No network variable dependency will be included. This is for PWL transient sources.

Three arguments are (1) an expression whose value will determine the output and the two arguments for the previous constructor pattern. They are: (2) a sequence or Numpy 1-D array of monotonically increasing X values, and (3) a sequence or Numpy 1-D array of Y values. Like this::

   pwl = PWL(10, X, Y)

where:

   X = np.array([0, 1.0, 1.5, 2.5])
   Y = np.array([0, 0.5, 4.5, 5.0])

Passing this wrapper in an f call will result in this:

   PWL(V(10), 0, 0, 1.0, 0.5, 1.5, 4.5, 2.5, 5.0)
Method check_shapes Raises an exception if the argument(s) is/are not a sequence or 1-D array. If multiple args, the lengths must be the same.
Method getXY Checks my arguments for X and Y sequences or 1-D arrays, ensuring that everything is OK and then returning X and Y.
Method dependency Converts my name (first constructor argument) to a legit network dependency source.
Method __call__ Undocumented

Inherited from Wrapper:

Method __init__ Undocumented
Method __iter__ You can iterate me over my arguments.
Method __str__ Undocumented
Method argsToString Undocumented
Method kwToString Undocumented
def check_shapes(self, *args):

Raises an exception if the argument(s) is/are not a sequence or 1-D array. If multiple args, the lengths must be the same.

def getXY(self):

Checks my arguments for X and Y sequences or 1-D arrays, ensuring that everything is OK and then returning X and Y.

def dependency(self):

Converts my name (first constructor argument) to a legit network dependency source.

def __call__(self):
API Documentation for pingspice, generated by pydoctor at 2021-09-18 08:41:11.