- Hands-On Artificial Intelligence for Beginners
- Patrick D. Smith
- 71字
- 2021-06-10 19:33:44
Matrices
Matrices are two-dimensional lists of numbers that contain rows and columns. Typically, rows in a matrix are denoted by i, while columns are denoted by j.
Matrices are represented as:

We can easily create matrices in Python as NumPy arrays, much like we can with vectors:
matrix = np.array([[5,6], [6,9]])
The only different is that we are adding an additional vector to the array to create the matrix.