All Courses
All Courses
Courses by Software
Courses by Semester
Courses by Domain
Tool-focused Courses
Machine learning
POPULAR COURSES
Success Stories
AIM: To simulate the forward kinematics of 2R Robotic Arm using MATLAB OBJECTIVE: Write a program to solve forward kinematics of 2R Robotic Arm THEORY: A robotic arm is a type of mechanical arm, usually programmable. The arm may be whole of the mechanism or maybe a part of a more complex…
Shubhranshu Mishra
updated on 03 Jul 2020
AIM: To simulate the forward kinematics of 2R Robotic Arm using MATLAB
OBJECTIVE: Write a program to solve forward kinematics of 2R Robotic Arm
THEORY:
A robotic arm is a type of mechanical arm, usually programmable. The arm may be whole of the mechanism or maybe a part of a more complex robot. The links of such a manipulator are connected by joints allowing either rotational motion or translational displacement. The links of the manipulator can be considered to form a kinematic chain. The terminus of the kinematic chain of the manipulator is called the end effector. An end effector is a device at the end of a robotic arm, designed to interact with the environment.
Robot kinematics refers to the analytical study of the motion of a robot manipulator. Formulating the suitable kinematics models for a robot mechanism is very crucial for analyzing the behavior of industrial manipulators.
A manipulator is composed of a series of links that are affixed to each other revolute or prismatic joints from the base frame through the end effector. Calculating the position and orientation of the end effector in terms of the joint variables is called forward kinematics. In order to have forward kinematics for a robot mechanism in a systematic manner, one should use a suitable kinematic model. Forward kinematics problem is straightforward and there is no complexity deriving the equations. Hence, there is always a forward kinematics solution of a manipulator.
PROCEDURE:
CODE:
% Forward Kinematics of a Robotic arm
clear
close all
clc
%Inputs
l1 = 1; %length of link 1
l2 = 0.5; %length of link 2
theta1 = linspace(0,90,20); %angle between x-axis and link 1
theta2 = linspace(0,90,20); %angle between x-axis and link 2
ct = 1;
for i = 1:length(theta1)
THETA1 = theta1(i);
for j = 1:length(theta2)
THETA2 = theta2(j);
%coordinates for starting point of link 1
x0 = 0;
y0 = 0;
%coordinates for end point of link 1 and also the starting point of
%link 2
x1 = l1*cosd(THETA1);
y1 = l1*sind(THETA1);
%coordinates for ending point of link 2
x2 = x1 + l2*cosd(THETA2);
y2 = y1 + l2*sind(THETA2);
%Plotting
plot([x0 x1],[y0 y1],[x1 x2],[y1 y2],"LineWidth",3)
axis([-0.1 1.8 0 1.8])
legend('Link1','Link2')
xlabel('x-axis')
ylabel('y-axis')
pause(0.01)
%for creating the animation
M(ct)= getframe(gcf);
ct = ct+1; %increment of frame
end
end
movie(M) %creates a movie
videofile = VideoWriter("robotic_arm_kinematics.avi",'Uncompressed AVI'); %assigns the file name and file format
open(videofile) %opens the videofile
writeVideo(videofile,M) %writes the video with plot frames
close(videofile) %closes the videofile
CONCLUSION:
Thus to simulate and animate the forward kinematics of the 2R robotic arm using MATLAB has been done and with this, we can see the workspace of the manipulator.
Leave a comment
Thanks for choosing to leave a comment. Please keep in mind that all the comments are moderated as per our comment policy, and your email will not be published for privacy reasons. Please leave a personal & meaningful conversation.
Other comments...
Frequency Analysis of a rotating shaft (Finite Element Analysis using SolidWorks)
Aim- The aim of this project is to perform a frequency analysis on a rotating shaft, from there we need to determine the critical frequencies and the mode shapes. 5 Mode Shapes were simulated and analyzed. Introduction:- Frequency is the number of occurrences of a repeating event per unit of time. The formula…
06 Jul 2020 03:57 PM IST
Project - Rankine cycle Simulator (MATLAB)
AIM: To create a basic 'RANKINE CYCLE SIMULATOR'. THEORY: The Rankine cycle is the fundamental operating cycle of all power plants where an operating fluid is continuously evaporated and condensed. The selection of operating fluid depends mainly on the available temperature range. The above figure shows us the basic rankine…
03 Jul 2020 10:43 AM IST
Curve fitting (MATLAB)
AIM: To write a program to fit a linear and cubic polynomial for the specific heat data set then calculate the goodness of fit using different parameters and different ways to improve the fit in MATLAB THEORY: Curve fitting is the process of constructing a curve or mathematical function that best fits the data points,…
03 Jul 2020 10:24 AM IST
Solving second order ODEs (MATLAB)
Aim: To solves the ODE which represents the equation of motion of a simple pendulum with damping. Objective: To write a program that solves the following ODE which represents the equation of motion of a simple pendulum with damping and create an animated video of output obtains by solving this ODE. Theory:…
03 Jul 2020 10:20 AM IST
Related Courses
Skill-Lync offers industry relevant advanced engineering courses for engineering students by partnering with industry experts.
© 2025 Skill-Lync Inc. All Rights Reserved.