Hello,
When running the code below, I get a completely incorrect matrix shape after reshaping. Can someone please assist?
def augmented_to_ref(A, b):
### START CODE HERE ###
# moderator edit: code removed
### END CODE HERE ###
return A_ref
A_ref = augmented_to_ref(A, b)
print(A_ref)
[[ 2. -1. 1. 1. ]
[ 1. 2. -1. -1. ]
[-1. 2. 2. 2. ]
[-0.52941176 1. 0.82352941 0.88235294]]
Expected Output
[[ 1 2 -1 -1 3]
[ 0 1 4 3 22]
[ 0 0 1 3 7]
[ 0 0 0 1 1]]
Apparently the reshape did not help?