Question: Write a code that contains a matrix with the dimensions of 3 by 5 which is named MYMAT_A and whose elements are random number

Write a code that contains a matrix with the dimensions of 3 by 5 which is named MYMAT_A and whose elements

Write a code that contains a matrix with the dimensions of 3 by 5 which is named MYMAT_A and whose elements are random number varying between zero and one. The code detects and converts the negative elements of MYMAT_A to positive elements. Finally, it prints out a new modified matrix named NEWMATA.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

Here is the solution Python import numpy as np Create a 3x5 matrix of random numbers between 0 and 1 MYMATA nprandomrand3 5 Print the original matrix printOriginal matrix printMYMATA Detect and conver... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Computer Network Questions!