Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

please help me with this MATLAB problem 4) (OPTIONAL, 6 points) The robot arm from practice1 takes two angle positions to move to a certain

please help me with this MATLAB problem image text in transcribed
4) (OPTIONAL, 6 points) The robot arm from practice1 takes two angle positions to move to a certain point in x,y space. Recall the formulas Hand x 10cos(th1)10cos(th1+th2) and losin(th1) + 10sin(th1+th2) Le Elbow Motor where th1 and th2 are the angles of the base and elbow joint respectively Base Motor a) Using matlab, first make a FUNCTION file robotXY.m which contains the function [x, y]- robotXY( th1, th2) that receives the two angles as input arguments and returns the corresponding x,y position of the robot arm as output arguments b) Test your new function with the following statements at the command line x y robotXY( pi/2, pi/2 should return x-10, y +10 x y robotXY( pi/6, 2*pi/3) should return x -0, y +10 and correct any errors you might have c) Now make a new SCRIPT file robotPlotter.m that creates and draws the trajectory of the robot arm when th1 goes from pi/3 to -pi/3 and th2 goes from pi/2 to-pi/2. First construct the th1 and th2 vectors so they have the SAME NUMBER OF POINTS, then invoke x y robotXY(th1, th2) to generate the corresponding x,y vectors, then plot(x,y) to create the plot. ADD title and axis labels! Save the plot as robotPlot.jpg When you are finished, make a zip of your AS folder and upload it to the server. You should see your code and plots in the upload results page, if not, then redo or get help

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

More Books

Students also viewed these Databases questions

Question

=+3. Define four key issues do the APAs ethics guidelines address.

Answered: 1 week ago