"""simple docstring"""


import doctest
from collections import deque

import numpy as np


class        a				:


    def __init__(					self	:  Union[str, Any]					):
      _UpperCAmelCase						 =      [2, 1, 2, -1]
      _UpperCAmelCase						 =      [1, 2, 3, 4]


    def      lowerCAmelCase_  (					self	:  List[Any]					):
      _UpperCAmelCase						 =      len(self.first_signal					)
      _UpperCAmelCase						 =      len(self.second_signal					)

      _UpperCAmelCase						 =      max(__lowerCAmelCase   ,				__lowerCAmelCase					)

      # create a zero matrix of max_length x max_length
      _UpperCAmelCase						 =      [[0] * max_length for i in range(__lowerCAmelCase					)]

      # fills the smaller signal with zeros to make both signals of same length
      if length_first_signal < length_second_signal:
        self.first_signal += [0] * (max_length - length_first_signal)
      elif length_first_signal > length_second_signal:
        self.second_signal += [0] * (max_length - length_second_signal)
      for i in range(__lowerCAmelCase					):
        _UpperCAmelCase						 =      deque(self.second_signal					)
        rotated_signal.rotate(__lowerCAmelCase					)
        for j, item in enumerate(__lowerCAmelCase					):
          matrix[i][j] += item

        # multiply the matrix with the first signal
      _UpperCAmelCase						 =      np.matmul(np.transpose(__lowerCAmelCase					)   ,				np.transpose(self.first_signal					)					)

      # rounding-off to two decimal places
      return [round(__lowerCAmelCase   ,				2					) for i in final_signal]


if __name__ == "__main__":
    doctest.testmod()

"""simple docstring"""


from abc import ABC, abstractmethod
from argparse import ArgumentParser


class        a				(		lowerCAmelCase_   ):


    @staticmethod
    @abstractmethod
    def      lowerCAmelCase_  (					__lowerCAmelCase	:  ArgumentParser					):
      raise NotImplementedError()


    @abstractmethod
    def      lowerCAmelCase_  (					self	:  int					):
      raise NotImplementedError()
