1,011 B
1,011 B
Matrix
Matrix(l: list[list[complexe]])
- l: representation of the matrix in a list
Attributes
-
__m: list[list[complexe]]the values contained in the matrix.
-
__size: tuple[int, int]the size of the matrix
Methode
-
__init__(l: list[list[complex]]=[]) -> Noneinitiates the matrix
-
__mul__(__value: "Matrix") -> Matrixdefines the natural multiplication as the Koeneger product for matrices
-
__apply(x: list[complex]) -> list[complex]takes a list to represent a vector in a colonne, and return the proctuct of the matrix by this vector
-
__str__() -> strreturns a string representation of the matrix
Staticmethods
-
I() -> Matrixreturns the matrix
\begin{pmatrix}
1 & 0\\
0 & 1
\end{pmatrix}
-
H() -> Matrixreturns the matrix
\begin{pmatrix}
\frac1\sqrt 2 & \frac1\sqrt 2\\
\frax1\sqrt 2 & -\frac1\sqrt 2
\end{pmatrix}