Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Can someone help with this Computer science problem. Please use mathlab, thank you in advance. I. Problem Solving and Programming using MATLAB Functions and Scripts

image text in transcribedCan someone help with this Computer science problem. Please use mathlab, thank you in advance. image text in transcribed

image text in transcribed

I. Problem Solving and Programming using MATLAB Functions and Scripts (5 questions): write 1. points) Custom MATLAB function problem Convert the given script into a MATLAB function called Car2Pol Name with 2 inputs (x and y and 2 outputs (rand a that converts x and y Cartesian Crectangular) coordinates into the polar coordinate values: r radius of a circle with center at the origin (0,0) and a angle in degrees from the positive horizontal x axis to the current location in a counterclockwise direction. Clear Previous clear: cle (x,y Center 0 0 of the circle at the 11 Center r1)P ecarponent of the center Center (21 EY-component of the center 13 ax acost(x-h)/r) 180/pi: degree angle using x ay asin (ty k)/2) 180/pi: degree angle using 3 angie degrees if y 0 a IEO abs(ay) elae 360 day. 2E dispett are and disp th the puts tare. Rnd 2 (a) degrees. Command Window If the inputs are: x 3 and y 3.6056 and a 156.3099 degrees then the outputs aze: Question 1: LA,B] Rec2Pol-Name (17 -2],[7 4]); What are the values of A and B? 2 (30 points) Using the custom MATLAB function in a script and Animation problem write a MATLAB script called RAAnim ame to plot a graph of radius (y-axis) versus angle (x-axis utilizing the custom function made in problem #1 (Car2Pol Name) Animate a moving point and its trace line starting from initial to final x and y values. Ensure that the custom function can handle vector inputs, and for inputs the outputs should also be vectors (make sure to use the dot operator for exponentiation (A) multiplication and division D and use a For Loop for the If Conditional Statement to solve for the output angle a). Use the following ve inputs

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

Intelligent Information And Database Systems 6th Asian Conference Aciids 2014 Bangkok Thailand April 7 9 2014 Proceedings Part I 9 2014 Proceedings Part 1 Lnai 8397

Authors: Ngoc-Thanh Nguyen ,Boonwat Attachoo ,Bogdan Trawinski ,Kulwadee Somboonviwat

2014th Edition

3319054759, 978-3319054759

More Books

Students also viewed these Databases questions

Question

2. Does the topic meet the criteria specified in the assignment?

Answered: 1 week ago

Question

=+2 Why did OBI create Centers of Excellence?

Answered: 1 week ago