Hello,
I am doing the C1_W4 programming assignment and I am stuck on exercise 3.
I have the following:
### START CODE HERE ###
P = np.array([
[0, .75, .30, .75, .10],
[.10, 0, .30, .05, .30],
[.30, .12, 0, .10, .55],
[.55, .05, .30, 0, .05],
[.05, .08, .10, .10, 0]
])
X0 = np.array([[0], [0], [0], [1], [0]])
# Multiply matrix P and X_0 (matrix multiplication).
X1 = np.matmul(P,X0)
### END CODE HERE ###
print(sum(P))
When I run the test:
# Test your solution.
w4_unittest.test_matrix(P, X0, X1)
Wrong vector X1. Check if matrix multiplication was performed correctly.
6 Tests passed
1 Tests failed
I am not sure what I am doing wrong with the matrix multiplication for X1?
Any insight as to my mistake is greatly appreciated.