Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Help with #s 2 and 3, not sure if #1 helps but I included it in the picture! def GetBunnycloudData (): f-open (bunny cloud.dat, r
Help with #s 2 and 3, not sure if #1 helps but I included it in the picture!
def GetBunnycloudData (): f-open ("bunny cloud.dat", "r" ) DATA -f.readlines () N len (DATA) for s in DATA: sss.split () a float (ss [0]) b - float (ss [1]) z.append (a + b * 1j) return z Warm-up complete. Lab 2 starts now. 1. Create a plot of the graph of the function y +2+1 over the interval [-2, 1]. On top of this graph, plot a blue quadrilateral with vertices at the origin, the y-intercept, the a-intercept and on the local maximum. Eye-ball the a-intercept and maximum; please don't solve any calculus problem. 2. Define functions Real (z) and Imag (z) that take in a list of complex floats and return the list of real and imaginary parts, respectively. Illustrate with an example. 3. The function GetBunnyCloudData() reads the file bunny-cloud.dat and returns a very long list of complex floats that form a point cloud rabbit when plotted on the plane. (a) Comment Get BunnycloudData () so as to explain what each line is doing (b) Use your Real (z) and Imag (z) functions to plot the bunny with yellow dots (c) Build (plot) an attractive yellow house for the bunnyStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started