Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

I have to make a python program that does the following: but I can't figure it out. a) You will create a program that repeatedly

I have to make a python program that does the following:

image text in transcribed

but I can't figure it out.

a) You will create a program that repeatedly multiplies a matrix by a point and plots the data to the screen. In this case, we will have a 2D point, (x,y). The point can be represented as a vector:v- e can also define a 2n2 matri,M- la Computing the product of M wit Computing the product of M with v gives us a new point v': Mv- v'. We can then use v' as the new point, multiply by matrix M again, and get another point, i.e. Mv'-v". This can go on indefinitely, creating a long sequence of points. Create a program that uses numpy to create a matrix and a point. Specifically, you should begin with the point (1.0), and the matrixc 0.08343568 1.005831 Then, repeatedly multiply the 1.00583 -0.0871561 0.087156 1.00583 matrix by the point to get a new point. You should repeat this between 150 and 250 times. Note: the purpose of this part of the assignment is to get practice with numpy, so you shoud use numpy for your operations, even if you find it easier to perform this computation a different way b) Then, make your program plot the data points, using matplotlib. Be sure to label the axes, and include a title. Your title should give a brief description of the shape that the points "trace" out. a) You will create a program that repeatedly multiplies a matrix by a point and plots the data to the screen. In this case, we will have a 2D point, (x,y). The point can be represented as a vector:v- e can also define a 2n2 matri,M- la Computing the product of M wit Computing the product of M with v gives us a new point v': Mv- v'. We can then use v' as the new point, multiply by matrix M again, and get another point, i.e. Mv'-v". This can go on indefinitely, creating a long sequence of points. Create a program that uses numpy to create a matrix and a point. Specifically, you should begin with the point (1.0), and the matrixc 0.08343568 1.005831 Then, repeatedly multiply the 1.00583 -0.0871561 0.087156 1.00583 matrix by the point to get a new point. You should repeat this between 150 and 250 times. Note: the purpose of this part of the assignment is to get practice with numpy, so you shoud use numpy for your operations, even if you find it easier to perform this computation a different way b) Then, make your program plot the data points, using matplotlib. Be sure to label the axes, and include a title. Your title should give a brief description of the shape that the points "trace" out

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

Databases In Networked Information Systems 6th International Workshop Dnis 2010 Aizu Wakamatsu Japan March 2010 Proceedings Lncs 5999

Authors: Shinji Kikuchi ,Shelly Sachdeva ,Subhash Bhalla

2010th Edition

3642120377, 978-3642120374

More Books

Students also viewed these Databases questions