Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Create a 1 0 1 0 matrix ( 2 D numpy array ) A whose entries are given by A m n = 2 m

Create a 1010 matrix (2D numpy array) A whose entries are given by Amn=2m+3n-mn. Indices are
zero-indixed in this definition, i.e. both m and n take integer values from 0 to 9, inclusive.
In your code below, the following variables will be graded:
Name
A
2D numpy array
Description
Matrix to be created
user_code.py
import numpy as np
A=np*zeros((10,10))
np.shape(A)
m=np*array([0,1,2,3,4,5,6,7,8,9])
np. shape (m)
n=np*array([0,1,2,3,4,5,6,7,8,9])
np.shape(n)
8- for m in range(A. shape[0]):
for n in range(A.shape[1]):
10,A=2**m+3**n-m**n
print(A)
image text in transcribed

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Management Systems Designing And Building Business Applications

Authors: Gerald V. Post

1st Edition

0072898933, 978-0072898934

More Books

Students also viewed these Databases questions