软件:matlab2014a

工具箱:Matlab Robotic Toolbox v9.8

这里感谢枫箫提供的机器人工具箱:http://blog.sina.com.cn/u/2707887295

本次连载主要以机器人工具箱附带的使用例子为主,提供注释和翻译。希望可以帮助大家更好使用机器人工具箱。

安装好Matlab

Robotic Toolbox

v9.8后,打开MATLAB,查看附带的例子输入rtbdemo,回车,就可以看到简介菜单。

这里逐次介绍每个的使用简介

rtbdemo

------------------------------------------------------------

Many of these demos print tutorial text and MATLAB commmands in the

console window.

Read the text and press to move on to the next command

At the end of the tutorial/demo you can choose the next one from

the graphical menu.

--- runscript

D:\matlab\toolbox\robot\rvctools\robot\demos\rotation.m

% In the field of robotics there are many possible ways of

representing

% orientations of which the most common are:

% - orthonormal【正交】rotation matrices (3x3),正交旋转矩阵

% - three angles (1x3), and

% - quaternions.【四元数】表示法可以参考http://blog.sina.com.cn/u/2707887295

% A rotation of pi/2 about the x-axis can be represented as an

orthonormal rotation

% matrix【绕x轴旋转pi/2的正交旋转矩阵】

>> R = rotx(pi/2)

R =

1.0000  0

0

0  0.0000  -1.0000

0  1.0000  0.0000

% which we can see is a 3x3 matrix.

% Such a matrix has the property that it's columns【列】 (and rows【行】)

are sets of orthogonal

% unit vectors【单位向量】.  The determinant of such a

matrix is always 1

>> det(R)

ans =

1

% Let's create a more complex rotation【创作一个更复杂的旋转】

>> R = rotx(30, 'deg') * roty(50, 'deg') * rotz(10,

'deg')

R =

0.6330  -0.1116  0.7660

0.5276  0.7864  -0.3214

-0.5665  0.6076  0.5567

% where this time we have specified the rotation angle in

degrees.【度数】

% Any rotation can be expressed in terms of a single rotation about

some axis

% in space【任何旋转都可以表达为绕空间某一特定轴的单独旋转】

>> [theta,vec] = tr2angvec(R)

theta

1.0610

vec =

0.5322  0.7634  0.3662

% where theta is the angle (in radians【弧度】) and vec is unit vector

representing the

% direction of the rotation

axis【旋转轴方向】.【这里theta是角度(以弧度表示),vec是代表旋转轴方向的单位向量】

% Commonly rotations are represented by Euler angles【欧拉角】

>> eul = tr2eul(R)

eul =

-0.3972  0.9804  0.8204

% which are three angles such that R = rotz(a)*roty(b)*rotz(c), ie.

the rotations

% required about the Z, then then the Y, then the Z axis.

% Rotations are also commonly represented by roll-pitch-yaw

angles

>> rpy = tr2rpy(R)

rpy =

0.5236  0.8727  0.1745

% which are three angles such that R = rotx(r)*roty(p)*rotz(y), ie.

the rotations

% required about the X, then then the Y, then the Z axis.

% We can investigate the effects of rotations about different

axes

% using this GUI based demonstration.  The menu

buttons allow the rotation

% axes to be varied【我们可以查看不同轴的旋转效果,通过使用演示的GUI。菜单按钮可以使旋转轴改变】

% close the window when you are done.

>> tripleangle('rpy', 'wait')

% The final useful form is the quaternion which comprises 【包含】4

numbers.  We can create

% a quaternion from an orthonormal matrix

>> q = Quaternion(R)

q =

0.86256 < 0.26926, 0.38622, 0.18526 >

% where we can see that it comprises a scalar【标量】 part and a

vector【向量】 part.  To convert back【向后转换】

>> q.R

ans =

0.6330  -0.1116  0.7660

0.5276  0.7864  -0.3214

-0.5665  0.6076  0.5567

% which is the same of the value of R we determined

above.【这和我们上面所推算的R是一样的】

% Quaternions are a class and the orientations they represent can

be compounded【复合的】, just

% as we do with rotation matrices by multiplication【乘法运算】.

% First we create two quaternions

>> q1 = Quaternion( rotx(pi/2) )

q1 =

0.70711 < 0.70711, 0, 0 >

>> q2 = Quaternion( roty(pi/2) )

q2 =

0.70711 < 0, 0.70711, 0 >

% then the rotation of q1 followed【跟随的】 by q2 is simply

>> q1 * q2

ans =

0.5 < 0.5, 0.5, 0.5 >

% We can also take the inverse【逆的,反的】 of a Quaternion

>> q1 * inv(q1)

ans =

1 < 0, 0, 0 >

% which results in a null【零位的】 rotation (zero vector part)

------ done --------

matlab toolbox 介绍,Matlab Robotic Toolbox使用简介(1)相关推荐

  1. matlab svmtrain 介绍,matlab自帶的svmtrain 函數

    學生還是試不出來, 特別是,如果照範例打 svmStruct = svmtrain(data(train,:),groups(train),'showplot',true); 就會出現 Usage: ...

  2. Matlab在线IDE:MATLAB Online介绍与计算定积分案例

    目录 1.MATLAB Online介绍 功能与特点 命令行窗口和编辑器窗口 适用场景 计费方式 使用方法 2.注册登录 3.计算定积分 1.MATLAB Online介绍 MATLAB Online ...

  3. Matlab Robotic Toolbox V9.10工具箱(六):puma560 动力学建模与仿真

    puma560,是经典的机器人模型,很多教材上都用它作为例子. 其D-H矩阵为: j theta d a alpha offset 1 q1 0 0 1.571 0 2 q2 0 0.4318 0 0 ...

  4. Matlab Robotic Toolbox V9.10工具箱(二):正/逆运动学

    matlab机器人工具箱 robotic toolbox 做运动学分析非常方便,SerialLink 类中有现成的函数:SerialLink.fkine(theta),可以直接对已经建立的机器人模型做 ...

  5. s matlab toolbox,Matlab Robotic Toolbox工具箱学习笔记(一 )

    Matlab Robotic Toolbox工具箱学习笔记(一) 软件:matlab2013a 工具箱:Matlab Robotic Toolbox v9.8 Matlab Robotic Toolb ...

  6. MATLAB Robotic Toolbox 机器人工具箱示例

    程序是基于Matlab2016a,工具箱版本为Robotic Toolbox 10.2 参考博客: MATLAB机器人工具箱使用 Matlab Robotic Toolbox V9.10工具箱(三): ...

  7. 机械臂机器人——使用Matlab Robotic ToolBox建立四轴机械臂模型并实现运动控制仿真

    文章目录 四轴机械臂实物 Robotic ToolBox机械臂建模 1.建立机械臂的D-H表 建立机械臂坐标系 根据坐标系建立D-H表 2.代码建模 机械臂运动学仿真 1.正运动学仿真 2.逆运动学仿 ...

  8. Matlab+Robotic toolbox (各版本免费获取,及安装步骤)

    方法搜索自新浪微博-- [原创]强大的MATLAB机器人工具箱Matlab_Robotic_Toolbox_v9.10及教程 http://www.petercorke.com/Robotics_To ...

  9. Macbook Matlab2017 安装机器人学工具箱(Robotic Toolbox for Matlab)

    Macbook Matlab2017 安装机器人学工具箱(Robotic Toolbox for Matlab) 1.下载机器人学工具箱(release9.1版本) 2.将rvctools文件夹拷贝到 ...

最新文章

  1. 在CentOS 6.3 64bit上如何从源码生成rpm包?
  2. 不能创建Outlook邮件的解决办法
  3. VTK:PolyData之MergePoints
  4. Express 入门之Router - worldtree_keeper的专栏 - CSDN博客
  5. 生产环境中Oracle常用函数总结
  6. Silverlight 异步单元测试
  7. C语言 memcpy函数(增加dst 从第一字节拷贝判断)的内部简单实现方式
  8. day19 java数组的常用算法和排序
  9. STM32 HAL库使用IIC
  10. 使用单链表数据结构存储结构化的学生信息
  11. 文本特征提取方法深度研究
  12. 如何查看某公司主体下挂了哪些公众号?
  13. 什么是数据科学家与数据科学
  14. IP-guard桌面终端安全解决方案
  15. 功能需要富文本编译器图片不转base64,琢磨了一下,上代码
  16. python class tynu()_Task02-BaseLine.ipynb
  17. kaiketwoday
  18. 《每秒处理10万订单乐视集团支付架构》学有所得
  19. 薄盒 | 方文山原创数字潮玩《庞克猫史汀》系列正在展出中
  20. MD5 SHA1 加密

热门文章

  1. 阿里云ECS服务器使用入门教程(部署Web系统)
  2. 四川大学计算机学院陈宇老师,十年母校情,拳拳赤子心——四川大学计算机学院(软件学院) 2005级校友捐赠签约仪式顺利举行...
  3. Windows-给Administrator设置指纹登陆
  4. OpenBmc开发8:devtool简介与使用
  5. tws蓝牙耳机p10双耳连接方法
  6. WebApi路由机制详解
  7. android 第三方登录和分享(5)
  8. 1_初步了解和试运行
  9. 2011年3月《震痛•震恫•震动》
  10. linux doc文档下载,LINUX基本命令.doc-资源下载人人文库网