├── .gitignore ├── README.md ├── common ├── PGraph.m ├── Polygon.m ├── about.m ├── angdiff.m ├── bresenham.m ├── circle.m ├── colnorm.m ├── diff2.m ├── distributeblocks.m ├── doesblockexist.m ├── e2h.m ├── edgelist.m ├── gauss2d.m ├── h2e.m ├── homline.m ├── homtrans.m ├── ishomog.m ├── isrot.m ├── isvec.m ├── multidfprintf.m ├── numcols.m ├── numrows.m ├── peak.m ├── peak2.m ├── plot2.m ├── plot_arrow.m ├── plot_box.m ├── plot_circle.m ├── plot_ellipse.m ├── plot_homline.m ├── plot_point.m ├── plot_poly.m ├── plot_sphere.m ├── plotp.m ├── polydiff.m ├── randinit.m ├── runscript.m ├── simulinkext.m ├── symexpr2slblock.m ├── tb_optparse.m ├── xaxis.m ├── xyzlabel.m └── yaxis.m ├── robot ├── @CodeGenerator │ ├── .CodeGenerator.m.swp │ ├── .gencoriolis.m.swp │ ├── .svn │ │ ├── all-wcprops │ │ ├── dir-prop-base │ │ ├── entries │ │ ├── prop-base │ │ │ └── CodeGenerator.m.svn-base │ │ ├── text-base │ │ │ ├── CodeGenerator.m.svn-base │ │ │ ├── gencoriolis.m.svn-base │ │ │ ├── genfdyn.m.svn-base │ │ │ ├── genfkine.m.svn-base │ │ │ ├── genfriction.m.svn-base │ │ │ ├── gengravload.m.svn-base │ │ │ ├── geninertia.m.svn-base │ │ │ ├── geninvdyn.m.svn-base │ │ │ ├── genjacobian.m.svn-base │ │ │ ├── genmfuncoriolis.m.svn-base │ │ │ ├── genmfunfdyn.m.svn-base │ │ │ ├── genmfunfkine.m.svn-base │ │ │ ├── genmfunfriction.m.svn-base │ │ │ ├── genmfungravload.m.svn-base │ │ │ ├── genmfuninertia.m.svn-base │ │ │ ├── genmfuninvdyn.m.svn-base │ │ │ ├── genmfunjacobian.m.svn-base │ │ │ ├── genslblockcoriolis.m.svn-base │ │ │ ├── genslblockfdyn.m.svn-base │ │ │ ├── genslblockfkine.m.svn-base │ │ │ ├── genslblockfriction.m.svn-base │ │ │ ├── genslblockgravload.m.svn-base │ │ │ ├── genslblockinertia.m.svn-base │ │ │ ├── genslblockinvdyn.m.svn-base │ │ │ ├── genslblockjacobian.m.svn-base │ │ │ └── logmsg.m.svn-base │ │ └── tmp │ │ │ ├── CodeGenerator.m.tmp │ │ │ ├── gencoriolis.m.tmp │ │ │ ├── genfdyn.m.tmp │ │ │ ├── genfkine.m.tmp │ │ │ └── genfriction.m.tmp │ ├── CodeGenerator.m │ ├── gencoriolis.m │ ├── genfdyn.m │ ├── genfkine.m │ ├── genfriction.m │ ├── gengravload.m │ ├── geninertia.m │ ├── geninvdyn.m │ ├── genjacobian.m │ ├── genmfuncoriolis.m │ ├── genmfunfdyn.m │ ├── genmfunfkine.m │ ├── genmfunfriction.m │ ├── genmfungravload.m │ ├── genmfuninertia.m │ ├── genmfuninvdyn.m │ ├── genmfunjacobian.m │ ├── genslblockcoriolis.m │ ├── genslblockfdyn.m │ ├── genslblockfkine.m │ ├── genslblockfriction.m │ ├── genslblockgravload.m │ ├── genslblockinertia.m │ ├── genslblockinvdyn.m │ ├── genslblockjacobian.m │ ├── logmsg.m │ └── private │ │ ├── .svn │ │ ├── all-wcprops │ │ ├── entries │ │ └── text-base │ │ │ ├── constructheaderstring.m.svn-base │ │ │ ├── createmconstructor.m.svn-base │ │ │ ├── createnewblocklibrary.m.svn-base │ │ │ ├── ffindreplace.m.svn-base │ │ │ ├── finsertfront.m.svn-base │ │ │ ├── generatecopyrightnote.m.svn-base │ │ │ ├── getpibugfixstring.m.svn-base │ │ │ └── replaceheader.m.svn-base │ │ ├── constructheaderstring.m │ │ ├── createmconstructor.m │ │ ├── createnewblocklibrary.m │ │ ├── ffindreplace.m │ │ ├── finsertfront.m │ │ ├── generatecopyrightnote.m │ │ ├── getpibugfixstring.m │ │ └── replaceheader.m ├── @SerialLink │ ├── .DS_Store │ ├── .svn │ │ ├── all-wcprops │ │ ├── entries │ │ ├── text-base │ │ │ ├── SerialLink.m.svn-base │ │ │ ├── accel.m.svn-base │ │ │ ├── animate.m.svn-base │ │ │ ├── cinertia.m.svn-base │ │ │ ├── coriolis.m.svn-base │ │ │ ├── fdyn.m.svn-base │ │ │ ├── fkine.m.svn-base │ │ │ ├── friction.m.svn-base │ │ │ ├── gencoords.m.svn-base │ │ │ ├── genforces.m.svn-base │ │ │ ├── gravload.m.svn-base │ │ │ ├── ikine.m.svn-base │ │ │ ├── ikine3.m.svn-base │ │ │ ├── ikine6s.m.svn-base │ │ │ ├── inertia.m.svn-base │ │ │ ├── issym.m.svn-base │ │ │ ├── itorque.m.svn-base │ │ │ ├── jacob0.m.svn-base │ │ │ ├── jacob_dot.m.svn-base │ │ │ ├── jacobn.m.svn-base │ │ │ ├── maniplty.m.svn-base │ │ │ ├── nofriction.m.svn-base │ │ │ ├── perturb.m.svn-base │ │ │ ├── plot.m.svn-base │ │ │ ├── rne.m.svn-base │ │ │ ├── rne_dh.m.svn-base │ │ │ ├── rne_mdh.m.svn-base │ │ │ └── teach.m.svn-base │ │ └── tmp │ │ │ └── rne_dh.m.tmp │ ├── SerialLink.m │ ├── accel.m │ ├── animate.m │ ├── cinertia.m │ ├── coriolis.m │ ├── createBlockCGJacobianDH.m │ ├── createBlockDirKinematicDH.m │ ├── createBlockJacobianDH.m │ ├── createCGJacobianDH.m │ ├── createDirKinematicDH.m │ ├── createGenAccelerations.m │ ├── createGenCoordinates.m │ ├── createGenForces.m │ ├── createGenVelocities.m │ ├── createJacobianDH.m │ ├── fdyn.m │ ├── fkine.m │ ├── friction.m │ ├── frne.mexmaci64 │ ├── frne.mexw32 │ ├── gencoords.m │ ├── genforces.m │ ├── gravload.m │ ├── ikine.m │ ├── ikine3.m │ ├── ikine6s.m │ ├── inertia.m │ ├── issym.m │ ├── itorque.m │ ├── jacob0.m │ ├── jacob_dot.m │ ├── jacobn.m │ ├── maniplty.m │ ├── nofriction.m │ ├── perturb.m │ ├── plot.m │ ├── private │ │ ├── .svn │ │ │ ├── all-wcprops │ │ │ ├── entries │ │ │ └── text-base │ │ │ │ └── findjobj.m.svn-base │ │ └── findjobj.m │ ├── rne.m │ ├── rne.mexmaci64 │ ├── rne.mexw32 │ ├── rne_dh.m │ ├── rne_mdh.m │ ├── slink.m │ └── teach.m ├── Bug2.m ├── CHANGES ├── CITATION ├── CONTRIB ├── Contents.m ├── DH.jar ├── DHFactor.java ├── DHFactor.m ├── DXform.m ├── Dstar.m ├── EKF.m ├── LGPL-LICENCE.txt ├── Link.m ├── Map.m ├── Navigation.m ├── Octave │ ├── .svn │ │ ├── all-wcprops │ │ ├── entries │ │ └── text-base │ │ │ └── README.txt.svn-base │ ├── @Link │ │ ├── .svn │ │ │ ├── all-wcprops │ │ │ ├── entries │ │ │ └── text-base │ │ │ │ ├── Link.m.svn-base │ │ │ │ ├── RP.m.svn-base │ │ │ │ ├── char.m.svn-base │ │ │ │ ├── display.m.svn-base │ │ │ │ ├── friction.m.svn-base │ │ │ │ ├── nofriction.m.svn-base │ │ │ │ ├── show.m.svn-base │ │ │ │ ├── sigma.m.svn-base │ │ │ │ ├── subsasgn.m.svn-base │ │ │ │ └── subsref.m.svn-base │ │ ├── Link.m │ │ ├── RP.m │ │ ├── char.m │ │ ├── display.m │ │ ├── friction.m │ │ ├── nofriction.m │ │ ├── show.m │ │ ├── sigma.m │ │ ├── subsasgn.m │ │ └── subsref.m │ ├── @Quaternion │ │ ├── .svn │ │ │ ├── all-wcprops │ │ │ ├── entries │ │ │ └── text-base │ │ │ │ ├── Quaternion.m.svn-base │ │ │ │ ├── char.m.svn-base │ │ │ │ ├── display.m.svn-base │ │ │ │ ├── dot.m.svn-base │ │ │ │ ├── double.m.svn-base │ │ │ │ ├── interp.m.svn-base │ │ │ │ ├── inv.m.svn-base │ │ │ │ ├── minus.m.svn-base │ │ │ │ ├── mpower.m.svn-base │ │ │ │ ├── mrdivide.m.svn-base │ │ │ │ ├── mtimes.m.svn-base │ │ │ │ ├── norm.m.svn-base │ │ │ │ ├── plot.m.svn-base │ │ │ │ ├── plus.m.svn-base │ │ │ │ ├── q2tr.m.svn-base │ │ │ │ ├── qinterp.m.svn-base │ │ │ │ ├── scale.m.svn-base │ │ │ │ ├── subsref.m.svn-base │ │ │ │ └── unit.m.svn-base │ │ ├── Quaternion.m │ │ ├── char.m │ │ ├── display.m │ │ ├── dot.m │ │ ├── double.m │ │ ├── interp.m │ │ ├── inv.m │ │ ├── minus.m │ │ ├── mpower.m │ │ ├── mrdivide.m │ │ ├── mtimes.m │ │ ├── norm.m │ │ ├── plot.m │ │ ├── plus.m │ │ ├── q2tr.m │ │ ├── qinterp.m │ │ ├── scale.m │ │ ├── subsref.m │ │ └── unit.m │ ├── @SerialLink │ │ ├── .svn │ │ │ ├── all-wcprops │ │ │ ├── entries │ │ │ └── text-base │ │ │ │ ├── SerialLink.m.svn-base │ │ │ │ ├── accel.m.svn-base │ │ │ │ ├── char.m.svn-base │ │ │ │ ├── cinertia.m.svn-base │ │ │ │ ├── coriolis.m.svn-base │ │ │ │ ├── display.m.svn-base │ │ │ │ ├── dyn.m.svn-base │ │ │ │ ├── fdyn.m.svn-base │ │ │ │ ├── fkine.m.svn-base │ │ │ │ ├── friction.m.svn-base │ │ │ │ ├── gravload.m.svn-base │ │ │ │ ├── ikine.m.svn-base │ │ │ │ ├── ikine6s.m.svn-base │ │ │ │ ├── inertia.m.svn-base │ │ │ │ ├── islimit.m.svn-base │ │ │ │ ├── isspherical.m.svn-base │ │ │ │ ├── itorque.m.svn-base │ │ │ │ ├── jacob0.m.svn-base │ │ │ │ ├── jacob_dot.m.svn-base │ │ │ │ ├── jacobn.m.svn-base │ │ │ │ ├── jtraj.m.svn-base │ │ │ │ ├── maniplty.m.svn-base │ │ │ │ ├── mtimes.m.svn-base │ │ │ │ ├── nofriction.m.svn-base │ │ │ │ ├── perturb.m.svn-base │ │ │ │ ├── plot.m.svn-base │ │ │ │ ├── rne.m.svn-base │ │ │ │ ├── rne_dh.m.svn-base │ │ │ │ ├── rne_mdh.m.svn-base │ │ │ │ ├── showlink.m.svn-base │ │ │ │ ├── subsasgn.m.svn-base │ │ │ │ ├── subsref.m.svn-base │ │ │ │ └── teach.m.svn-base │ │ ├── SerialLink.m │ │ ├── accel.m │ │ ├── char.m │ │ ├── cinertia.m │ │ ├── coriolis.m │ │ ├── display.m │ │ ├── dyn.m │ │ ├── fdyn.m │ │ ├── fkine.m │ │ ├── friction.m │ │ ├── gravload.m │ │ ├── ikine.m │ │ ├── ikine6s.m │ │ ├── inertia.m │ │ ├── islimit.m │ │ ├── isspherical.m │ │ ├── itorque.m │ │ ├── jacob0.m │ │ ├── jacob_dot.m │ │ ├── jacobn.m │ │ ├── jtraj.m │ │ ├── maniplty.m │ │ ├── mtimes.m │ │ ├── nofriction.m │ │ ├── perturb.m │ │ ├── plot.m │ │ ├── rne.m │ │ ├── rne_dh.m │ │ ├── rne_mdh.m │ │ ├── showlink.m │ │ ├── subsasgn.m │ │ ├── subsref.m │ │ └── teach.m │ └── README.txt ├── PRM.m ├── ParticleFilter.m ├── Prismatic.m ├── Quaternion.m ├── README ├── RELEASE ├── RRT.m ├── RandomPath.m ├── RangeBearingSensor.m ├── Revolute.m ├── Sensor.m ├── Vehicle.m ├── angvec2r.m ├── angvec2tr.m ├── ctraj.m ├── delta2tr.m ├── demos │ ├── .DS_Store │ ├── .svn │ │ ├── all-wcprops │ │ ├── entries │ │ ├── text-base │ │ │ ├── animate.m.svn-base │ │ │ ├── braitnav.m.svn-base │ │ │ ├── bugnav.m.svn-base │ │ │ ├── codegen.m.svn-base │ │ │ ├── demos.xml.svn-base │ │ │ ├── drivepose.m.svn-base │ │ │ ├── dstarnav.m.svn-base │ │ │ ├── fdyn.m.svn-base │ │ │ ├── fkine.m.svn-base │ │ │ ├── graphics.m.svn-base │ │ │ ├── idyn.m.svn-base │ │ │ ├── ikine.m.svn-base │ │ │ ├── jacob.m.svn-base │ │ │ ├── particlefilt.m.svn-base │ │ │ ├── prmnav.m.svn-base │ │ │ ├── quadrotor.m.svn-base │ │ │ ├── robot.m.svn-base │ │ │ ├── rotation.m.svn-base │ │ │ ├── rtb_demo_animate.m.svn-base │ │ │ ├── rtb_demo_fdyn.m.svn-base │ │ │ ├── rtb_demo_fkine.m.svn-base │ │ │ ├── rtb_demo_idyn.m.svn-base │ │ │ ├── rtb_demo_ikine.m.svn-base │ │ │ ├── rtb_demo_jacob.m.svn-base │ │ │ ├── rtb_demo_tr.m.svn-base │ │ │ ├── rtb_demo_traj.m.svn-base │ │ │ ├── slam.m.svn-base │ │ │ ├── symbolic.m.svn-base │ │ │ ├── traj.m.svn-base │ │ │ ├── trans.m.svn-base │ │ │ └── ztorque.m.svn-base │ │ └── tmp │ │ │ └── demos.xml.tmp │ ├── .ztorque.m.swp │ ├── README │ ├── TODO │ ├── braitnav.m │ ├── bugnav.m │ ├── codegen.m │ ├── demos.xml │ ├── drivepose.m │ ├── dstarnav.m │ ├── fdyn.m │ ├── fkine.m │ ├── graphics.m │ ├── idyn.m │ ├── ikine.m │ ├── jacob.m │ ├── particlefilt.m │ ├── prmnav.m │ ├── quadrotor.m │ ├── robot.m │ ├── rotation.m │ ├── slam.m │ ├── symbolic.m │ ├── traj.m │ ├── trans.m │ └── ztorque.m ├── distancexform.m ├── eul2jac.m ├── eul2r.m ├── eul2tr.m ├── examples │ ├── .svn │ │ ├── all-wcprops │ │ ├── entries │ │ ├── prop-base │ │ │ └── map1.mat.svn-base │ │ └── text-base │ │ │ ├── braitenberg.m.svn-base │ │ │ ├── eg_grav.m.svn-base │ │ │ ├── eg_inertia.m.svn-base │ │ │ ├── eg_inertia22.m.svn-base │ │ │ ├── gait.m.svn-base │ │ │ ├── map1.mat.svn-base │ │ │ ├── moveline.m.svn-base │ │ │ ├── movepoint.m.svn-base │ │ │ ├── movepose.m.svn-base │ │ │ ├── sensorfield.m.svn-base │ │ │ └── walking.m.svn-base │ ├── braitenberg.m │ ├── eg_grav.m │ ├── eg_inertia.m │ ├── eg_inertia22.m │ ├── gait.m │ ├── map1.mat │ ├── moveline.m │ ├── movepoint.m │ ├── movepose.m │ ├── sensorfield.m │ └── walking.m ├── info.xml ├── info │ ├── acknowledgements.html │ ├── contents.html │ ├── contents_alpha.html │ ├── contents_toc.html │ ├── helpfuncbycat.xml │ ├── helptoc.xml │ ├── html │ │ ├── Bug2.html │ │ ├── CodeGenerator.html │ │ ├── DHFactor.html │ │ ├── DXform.html │ │ ├── Dstar.html │ │ ├── EKF.html │ │ ├── Link.html │ │ ├── Map.html │ │ ├── Navigation.html │ │ ├── PGraph.html │ │ ├── PRM.html │ │ ├── ParticleFilter.html │ │ ├── Polygon.html │ │ ├── Prismatic.html │ │ ├── Quaternion.html │ │ ├── RRT.html │ │ ├── RandomPath.html │ │ ├── RangeBearingSensor.html │ │ ├── Revolute.html │ │ ├── Sensor.html │ │ ├── SerialLink.html │ │ ├── Vehicle.html │ │ ├── about.html │ │ ├── angdiff.html │ │ ├── angvec2r.html │ │ ├── angvec2tr.html │ │ ├── bresenham.html │ │ ├── circle.html │ │ ├── colnorm.html │ │ ├── ctraj.html │ │ ├── delta2tr.html │ │ ├── diff2.html │ │ ├── distancexform.html │ │ ├── distributeblocks.html │ │ ├── doesblockexist.html │ │ ├── e2h.html │ │ ├── edgelist.html │ │ ├── eul2jac.html │ │ ├── eul2r.html │ │ ├── eul2tr.html │ │ ├── gauss2d.html │ │ ├── h2e.html │ │ ├── homline.html │ │ ├── homtrans.html │ │ ├── ishomog.html │ │ ├── isrot.html │ │ ├── isvec.html │ │ ├── jtraj.html │ │ ├── lspb.html │ │ ├── makemap.html │ │ ├── mdl_Fanuc10L.html │ │ ├── mdl_MotomanHP6.html │ │ ├── mdl_S4ABB2p8.html │ │ ├── mdl_ball.html │ │ ├── mdl_coil.html │ │ ├── mdl_p8.html │ │ ├── mdl_phantomx.html │ │ ├── mdl_puma560.html │ │ ├── mdl_puma560_3.html │ │ ├── mdl_puma560_3_sym.html │ │ ├── mdl_puma560akb.html │ │ ├── mdl_quadcopter.html │ │ ├── mdl_stanford.html │ │ ├── mdl_twolink.html │ │ ├── mstraj.html │ │ ├── mtraj.html │ │ ├── multidfprintf.html │ │ ├── numcols.html │ │ ├── numrows.html │ │ ├── oa2r.html │ │ ├── oa2tr.html │ │ ├── peak.html │ │ ├── peak2.html │ │ ├── plot2.html │ │ ├── plot_arrow.html │ │ ├── plot_box.html │ │ ├── plot_circle.html │ │ ├── plot_ellipse.html │ │ ├── plot_homline.html │ │ ├── plot_point.html │ │ ├── plot_poly.html │ │ ├── plot_sphere.html │ │ ├── plot_vehicle.html │ │ ├── plotbotopt.html │ │ ├── plotp.html │ │ ├── polydiff.html │ │ ├── qplot.html │ │ ├── r2t.html │ │ ├── randinit.html │ │ ├── rotx.html │ │ ├── roty.html │ │ ├── rotz.html │ │ ├── rpy2jac.html │ │ ├── rpy2r.html │ │ ├── rpy2tr.html │ │ ├── rt2tr.html │ │ ├── rtbdemo.html │ │ ├── runscript.html │ │ ├── se2.html │ │ ├── simulinkext.html │ │ ├── skew.html │ │ ├── startup_rtb.html │ │ ├── symexpr2slblock.html │ │ ├── t2r.html │ │ ├── tb_optparse.html │ │ ├── tpoly.html │ │ ├── tr2angvec.html │ │ ├── tr2delta.html │ │ ├── tr2eul.html │ │ ├── tr2jac.html │ │ ├── tr2rpy.html │ │ ├── tr2rt.html │ │ ├── tranimate.html │ │ ├── transl.html │ │ ├── trinterp.html │ │ ├── tripleangle.html │ │ ├── trnorm.html │ │ ├── trotx.html │ │ ├── troty.html │ │ ├── trotz.html │ │ ├── trplot.html │ │ ├── trplot2.html │ │ ├── trprint.html │ │ ├── unit.html │ │ ├── vex.html │ │ ├── wtrans.html │ │ ├── xaxis.html │ │ ├── xyzlabel.html │ │ └── yaxis.html │ ├── icons │ │ ├── .svn │ │ │ ├── all-wcprops │ │ │ ├── entries │ │ │ ├── prop-base │ │ │ │ ├── bullet_orange.gif.svn-base │ │ │ │ └── more_arrows.gif.svn-base │ │ │ └── text-base │ │ │ │ ├── bullet_orange.gif.svn-base │ │ │ │ └── more_arrows.gif.svn-base │ │ ├── bullet_orange.gif │ │ └── more_arrows.gif │ ├── introduction.html │ ├── license.html │ ├── release.html │ ├── robot_product_page.html │ └── rtb-montage-notext.png ├── jtraj.m ├── lspb.m ├── makemap.m ├── mdl_Fanuc10L.m ├── mdl_MotomanHP6.m ├── mdl_S4ABB2p8.m ├── mdl_ball.m ├── mdl_coil.m ├── mdl_p8.m ├── mdl_phantomx.m ├── mdl_puma560.m ├── mdl_puma560_3.m ├── mdl_puma560_3_sym.m ├── mdl_puma560akb.m ├── mdl_quadcopter.m ├── mdl_stanford.m ├── mdl_twolink.m ├── mex │ ├── .svn │ │ ├── all-wcprops │ │ ├── entries │ │ └── text-base │ │ │ ├── Makefile.svn-base │ │ │ ├── README.svn-base │ │ │ ├── TODO.svn-base │ │ │ ├── check.m.svn-base │ │ │ ├── check1.m.svn-base │ │ │ ├── check2.m.svn-base │ │ │ ├── frne.c.svn-base │ │ │ ├── frne.h.svn-base │ │ │ ├── make.m.svn-base │ │ │ ├── ne.c.svn-base │ │ │ ├── prismatic.m.svn-base │ │ │ ├── stanford.m.svn-base │ │ │ ├── stanfordm.m.svn-base │ │ │ ├── vmath.c.svn-base │ │ │ └── vmath.h.svn-base │ ├── Makefile │ ├── README │ ├── TODO │ ├── check.m │ ├── check1.m │ ├── check2.m │ ├── frne.c │ ├── frne.h │ ├── frne.mexmaci64 │ ├── frne.mexw32 │ ├── make.m │ ├── ne.c │ ├── prismatic.m │ ├── stanford.m │ ├── stanfordm.m │ ├── vmath.c │ └── vmath.h ├── mstraj.m ├── mtraj.m ├── oa2r.m ├── oa2tr.m ├── plot_vehicle.m ├── plotbotopt.m ├── qplot.m ├── r2t.m ├── robot.pdf ├── rotx.m ├── roty.m ├── rotz.m ├── rpy2jac.m ├── rpy2r.m ├── rpy2tr.m ├── rt2tr.m ├── rtbdemo.m ├── se2.m ├── skew.m ├── startup_rtb.m ├── t2r.m ├── tpoly.m ├── tr2angvec.m ├── tr2delta.m ├── tr2eul.m ├── tr2jac.m ├── tr2rpy.m ├── tr2rt.m ├── tranimate.m ├── transl.m ├── trinterp.m ├── tripleangle.fig ├── tripleangle.m ├── trnorm.m ├── trotx.m ├── troty.m ├── trotz.m ├── trplot.m ├── trplot2.m ├── trprint.m ├── unit.m ├── vex.m └── wtrans.m ├── simulink ├── control.mdl ├── ploop_test.mdl ├── polar_sfunc.m ├── quadrotor_dynamics.m ├── quadrotor_plot.m ├── roblocks.mdl ├── sensorfield.m ├── sl_braitenberg.mdl ├── sl_ctorque.mdl ├── sl_ctorque2.mdl ├── sl_driveline.mdl ├── sl_drivepoint.mdl ├── sl_drivepose.mdl ├── sl_fforward.mdl ├── sl_flex.mdl ├── sl_jspace.mdl ├── sl_lanechange.mdl ├── sl_pursuit.mdl ├── sl_quadcopter.mdl ├── sl_quadcopter_vs.mdl ├── sl_quadrotor.mdl ├── sl_quadrotor_vs.mdl ├── sl_rrmc.mdl ├── sl_rrmc2.mdl ├── sl_ztorque.mdl ├── slaccel.m ├── slplotbot.m ├── vloop.mdl ├── vloop_test.mdl └── vloop_test2.mdl └── startup_rvc.m /.gitignore: -------------------------------------------------------------------------------- 1 | *~ 2 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # About 2 | Copy of Peter Corke's MATLAB Robotics Toolbox 3 | -------------------------------------------------------------------------------- /common/about.m: -------------------------------------------------------------------------------- 1 | %ABOUT Compact display of variable type 2 | % 3 | % ABOUT(X) displays a compact line that describes the class and dimensions of 4 | % X. 5 | % 6 | % ABOUT X as above but this is the command rather than functional form 7 | % 8 | % See also WHOS. 9 | function about(var) 10 | 11 | if isstr(var) 12 | % invoked without parentheses 13 | w = evalin('caller', sprintf('whos(''%s'')', var)); 14 | varname = var; 15 | else 16 | w = whos('var'); 17 | varname = inputname(1); 18 | end 19 | 20 | if isempty(w) 21 | error(['cant find variable ' var]) 22 | end 23 | ss = sprintf('%d', w.size(1)); 24 | for i=2:length(w.size) 25 | ss = strcat(ss, sprintf('x%d', w.size(i))); 26 | end 27 | 28 | % build a string to show if complex or not 29 | if w.complex 30 | cmplx = '+complex'; 31 | else 32 | cmplx = ''; 33 | end 34 | 35 | % build a string to show size in convenient format 36 | suffix = {'bytes', 'kB', 'MB', 'GB', 'TB'}; 37 | sz = w.bytes; 38 | for i=1:numel(suffix) 39 | if sz/1000 < 1 40 | break; 41 | end 42 | sz = sz/1000; 43 | end 44 | 45 | if i==1 46 | size = sprintf('%d %s', sz, suffix{i}); 47 | else 48 | size = sprintf('%.1f %s', sz, suffix{i}); 49 | end 50 | 51 | % now display the info 52 | fprintf('%s [%s%s] : %s (%s)\n', ... 53 | varname, w.class, cmplx, ss, size); 54 | 55 | -------------------------------------------------------------------------------- /common/angdiff.m: -------------------------------------------------------------------------------- 1 | %ANGDIFF Difference of two angles 2 | % 3 | % D = ANGDIFF(TH1, TH2) returns the difference between angles TH1 and TH2 on 4 | % the circle. The result is in the interval [-pi pi). If TH1 is a column 5 | % vector, and TH2 a scalar then return a column vector where TH2 is modulo 6 | % subtracted from the corresponding elements of TH1. 7 | % 8 | % D = ANGDIFF(TH) returns the equivalent angle to TH in the interval [-pi pi). 9 | % 10 | % Return the equivalent angle in the interval [-pi pi). 11 | 12 | function d = angdiff(th1, th2) 13 | 14 | if nargin < 2 15 | % THIS IS A BAD IDEA, WHERE IS IT USED? 16 | % if length(th1) > 1 17 | % d = th1(1) - th1(2); 18 | % else 19 | % d = th1; 20 | % end 21 | d = th1; 22 | else 23 | d = th1 - th2; 24 | end 25 | 26 | 27 | d = mod(d+pi, 2*pi) - pi; 28 | 29 | % Simplistic version of the code, easy to see what it does, but slow... 30 | % 31 | % for very negative angles keep adding 2pi 32 | % while true 33 | % k = find(d < -pi); 34 | % if isempty(k) 35 | % break; 36 | % end 37 | % d(k) = d(k) + 2*pi; 38 | % end 39 | % 40 | % % for very positive angles keep subtracting 2pi 41 | % while true 42 | % k = find(d > pi); 43 | % if isempty(k) 44 | % break; 45 | % end 46 | % d(k) = d(k) - 2*pi; 47 | % end 48 | -------------------------------------------------------------------------------- /common/circle.m: -------------------------------------------------------------------------------- 1 | %CIRCLE Compute points on a circle 2 | % 3 | % CIRCLE(C, R, OPT) plot a circle centred at C with radius R. 4 | % 5 | % X = CIRCLE(C, R, OPT) return an Nx2 matrix whose rows define the 6 | % coordinates [x,y] of points around the circumferance of a circle 7 | % centred at C and of radius R. 8 | % 9 | % C is normally 2x1 but if 3x1 then the circle is embedded in 3D, and X is Nx3, 10 | % but the circle is always in the xy-plane with a z-coordinate of C(3). 11 | % 12 | % Options:: 13 | % 'n',N Specify the number of points (default 50) 14 | function out = circle(centre, rad, varargin) 15 | 16 | opt.n = 50; 17 | 18 | [opt,arglist] = tb_optparse(opt, varargin); 19 | 20 | % compute points on circumference 21 | th = [0:opt.n-1]'/ opt.n*2*pi; 22 | x = rad*cos(th) + centre(1); 23 | y = rad*sin(th) + centre(2); 24 | 25 | % add extra row if z-coordinate is specified, but circle is always in xy plane 26 | if length(centre) > 2 27 | z = ones(size(x))*centre(3); 28 | p = [x y z]'; 29 | else 30 | p = [x y]'; 31 | end 32 | 33 | if nargout > 0 34 | % return now 35 | out = p; 36 | return; 37 | else 38 | % else plot the circle 39 | p = [p p(:,1)]; % make it close 40 | if numrows(p) > 2 41 | plot3(p(1,:), p(2,:), p(3,:), arglist{:}); 42 | else 43 | plot(p(1,:), p(2,:), arglist{:}); 44 | end 45 | end 46 | -------------------------------------------------------------------------------- /common/colnorm.m: -------------------------------------------------------------------------------- 1 | %COLNORM Column-wise norm of a matrix 2 | % 3 | % CN = COLNORM(A) is an Mx1 vector of the normals of each column of the 4 | % matrix A which is NxM. 5 | function n = colnorm(a) 6 | 7 | n = sqrt(sum(a.^2)); 8 | -------------------------------------------------------------------------------- /common/diff2.m: -------------------------------------------------------------------------------- 1 | %DIFF2 Two point difference 2 | % 3 | % D = DIFF2(V) is the 2-point difference for each point in the vector v 4 | % and the first element is zero. The vector D has the same length as V. 5 | % 6 | % See also DIFF. 7 | function d = diff2(v) 8 | [r,c] =size(v); 9 | 10 | d = [zeros(1,c); diff(v)]; 11 | -------------------------------------------------------------------------------- /common/e2h.m: -------------------------------------------------------------------------------- 1 | %E2H Euclidean to homogeneous 2 | % 3 | % H = E2H(E) is the homogeneous version (K+1xN) of the Euclidean 4 | % points E (KxN) where each column represents one point in R^K. 5 | % 6 | % See also H2E. 7 | 8 | function h = e2h(e) 9 | h = [e; ones(1,numcols(e))]; 10 | -------------------------------------------------------------------------------- /common/gauss2d.m: -------------------------------------------------------------------------------- 1 | %GAUSS2D Gaussian kernel 2 | % 3 | % OUT = GAUSS2D(IM, SIGMA, C) is a unit volume Gaussian kernel rendered into 4 | % matrix OUT (WxH) the same size as IM (WxH). The Gaussian has a standard 5 | % deviation of SIGMA. The Gaussian is centered at C=[U,V]. 6 | function m = gaus2d(im, sigma, c) 7 | 8 | 9 | if length(sigma) == 1 10 | sx = sigma(1); 11 | sy = sigma(1); 12 | else 13 | sx = sigma(1); 14 | sy = sigma(2); 15 | end 16 | 17 | [x,y] = imeshgrid(im); 18 | 19 | m = 1/(2*pi*sx*sy) * exp( -(((x-c(1))/sx).^2 + ((y-c(2))/sy).^2)/2); 20 | -------------------------------------------------------------------------------- /common/h2e.m: -------------------------------------------------------------------------------- 1 | %H2E Homogeneous to Euclidean 2 | % 3 | % E = H2E(H) is the Euclidean version (K-1xN) of the homogeneous 4 | % points H (KxN) where each column represents one point in P^K. 5 | % 6 | % See also E2H. 7 | 8 | function e = h2e(h) 9 | 10 | if isvector(h) 11 | h = h(:); 12 | end 13 | e = h(1:end-1,:) ./ repmat(h(end,:), numrows(h)-1, 1); 14 | 15 | -------------------------------------------------------------------------------- /common/homline.m: -------------------------------------------------------------------------------- 1 | %HOMLINE Homogeneous line from two points 2 | % 3 | % L = HOMLINE(X1, Y1, X2, Y2) is a vector (3x1) which describes a line in 4 | % homogeneous form that contains the two Euclidean points (X1,Y1) and (X2,Y2). 5 | % 6 | % Homogeneous points X (3x1) on the line must satisfy L'*X = 0. 7 | % 8 | % See also PLOT_HOMLINE. 9 | 10 | % TODO, probably should be part of a HomLine class. 11 | 12 | function l = homline(x1, y1, x2, y2) 13 | 14 | l = cross([x1 y1 1], [x2 y2 1]); 15 | 16 | % normalize so that the result of x*l' is the pixel distance 17 | % from the line 18 | l = l / norm(l(1:2)); 19 | -------------------------------------------------------------------------------- /common/isrot.m: -------------------------------------------------------------------------------- 1 | %ISROT Test if argument is a rotation matrix 2 | % 3 | % ISROT(R) is true (1) if the argument is of dimension 3x3 or 3x3xN, else false (0). 4 | % 5 | % ISROT(R, 'valid') as above, but also checks the validity of the rotation 6 | % matrix. 7 | % 8 | % Notes:: 9 | % - A valid rotation matrix has determinant of 1. 10 | % 11 | % See also ISHOMOG, ISVEC. 12 | 13 | 14 | % Copyright (C) 1993-2011, by Peter I. Corke 15 | % 16 | % This file is part of The Robotics Toolbox for Matlab (RTB). 17 | % 18 | % RTB is free software: you can redistribute it and/or modify 19 | % it under the terms of the GNU Lesser General Public License as published by 20 | % the Free Software Foundation, either version 3 of the License, or 21 | % (at your option) any later version. 22 | % 23 | % RTB is distributed in the hope that it will be useful, 24 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 25 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 26 | % GNU Lesser General Public License for more details. 27 | % 28 | % You should have received a copy of the GNU Leser General Public License 29 | % along with RTB. If not, see . 30 | 31 | function h = isrot(r, dtest) 32 | 33 | d = size(r); 34 | if ndims(r) >= 2 35 | h = all(d(1:2) == [3 3]); 36 | 37 | if h && nargin > 1 38 | h = abs(det(r) - 1) < eps; 39 | end 40 | 41 | else 42 | h = false; 43 | end 44 | -------------------------------------------------------------------------------- /common/isvec.m: -------------------------------------------------------------------------------- 1 | %ISVEC Test if argument is a vector 2 | % 3 | % ISVEC(V) is true (1) if the argument V is a 3-vector, else false (0). 4 | % 5 | % ISVEC(V, L) is true (1) if the argument V is a vector of length L, 6 | % either a row- or column-vector. Otherwise false (0). 7 | % 8 | % Notes:: 9 | % - differs from MATLAB builtin function ISVECTOR, the latter returns true 10 | % for the case of a scalar, ISVEC does not. 11 | % 12 | % See also ISHOMOG, ISROT. 13 | 14 | 15 | % Copyright (C) 1993-2011, by Peter I. Corke 16 | % 17 | % This file is part of The Robotics Toolbox for Matlab (RTB). 18 | % 19 | % RTB is free software: you can redistribute it and/or modify 20 | % it under the terms of the GNU Lesser General Public License as published by 21 | % the Free Software Foundation, either version 3 of the License, or 22 | % (at your option) any later version. 23 | % 24 | % RTB is distributed in the hope that it will be useful, 25 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 26 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 27 | % GNU Lesser General Public License for more details. 28 | % 29 | % You should have received a copy of the GNU Leser General Public License 30 | % along with RTB. If not, see . 31 | 32 | function h = isvec(v, l) 33 | if nargin == 1 34 | l = 3; 35 | end 36 | d = size(v); 37 | h = logical( length(d) == 2 && min(d) == 1 && numel(v) == l ); 38 | 39 | -------------------------------------------------------------------------------- /common/numcols.m: -------------------------------------------------------------------------------- 1 | %NUMCOLS Return number of columns in matrix 2 | % 3 | % NC = NUMCOLS(M) is the number of columns in the matrix M. 4 | % 5 | % See also NUMROWS. 6 | 7 | % Copyright (C) 1993-2008, by Peter I. Corke 8 | % 9 | % This file is part of The Robotics Toolbox for Matlab (RTB). 10 | % 11 | % RTB is free software: you can redistribute it and/or modify 12 | % it under the terms of the GNU Lesser General Public License as published by 13 | % the Free Software Foundation, either version 3 of the License, or 14 | % (at your option) any later version. 15 | % 16 | % RTB is distributed in the hope that it will be useful, 17 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 18 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 19 | % GNU Lesser General Public License for more details. 20 | % 21 | % You should have received a copy of the GNU Leser General Public License 22 | % along with RTB. If not, see . 23 | 24 | function c = numcols(m) 25 | c = size(m,2); 26 | -------------------------------------------------------------------------------- /common/numrows.m: -------------------------------------------------------------------------------- 1 | %NUMROWS Return number of rows in matrix 2 | % 3 | % NR = NUMROWS(M) is the number of rows in the matrix M. 4 | % 5 | % See also NUMCOLS. 6 | 7 | 8 | % Copyright (C) 1993-2008, by Peter I. Corke 9 | % 10 | % This file is part of The Robotics Toolbox for Matlab (RTB). 11 | % 12 | % RTB is free software: you can redistribute it and/or modify 13 | % it under the terms of the GNU Lesser General Public License as published by 14 | % the Free Software Foundation, either version 3 of the License, or 15 | % (at your option) any later version. 16 | % 17 | % RTB is distributed in the hope that it will be useful, 18 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 19 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 20 | % GNU Lesser General Public License for more details. 21 | % 22 | % You should have received a copy of the GNU Leser General Public License 23 | % along with RTB. If not, see . 24 | 25 | function r = numrows(m) 26 | 27 | [r,x] = size(m); 28 | -------------------------------------------------------------------------------- /common/plot2.m: -------------------------------------------------------------------------------- 1 | %PLOT2 Plot trajectories 2 | % 3 | % PLOT2(P) plots a line with coordinates taken from successive rows of P. P 4 | % can be Nx2 or Nx3. 5 | % 6 | % If P has three dimensions, ie. Nx2xM or Nx3xM then the M trajectories are 7 | % overlaid in the one plot. 8 | % 9 | % PLOT2(P, LS) as above but the line style arguments LS are passed to plot. 10 | % 11 | % See also PLOT. 12 | function h = plot2(p1, varargin) 13 | 14 | if ndims(p1) == 2 15 | if numcols(p1) == 3, 16 | hh = plot3(p1(:,1), p1(:,2), p1(:,3), varargin{:}); 17 | else 18 | hh = plot(p1(:,1), p1(:,2), varargin{:}); 19 | end 20 | if nargout == 1, 21 | h = hh; 22 | end 23 | else 24 | clf 25 | hold on 26 | for i=1:size(p1,2) 27 | plot2( squeeze(p1(:,i,:))' ); 28 | end 29 | end 30 | -------------------------------------------------------------------------------- /common/plot_arrow.m: -------------------------------------------------------------------------------- 1 | %PLOT_ARROW Plot arrow 2 | % 3 | % PLOT_ARROW(P, OPTIONS) draws an arrow from P1 to P2 where P=[P1; P2]. 4 | % 5 | % See also ARROW3. 6 | function plot_arrow(p, varargin) 7 | mstart = p(1:end-1,:); 8 | mend = p(2:end,:); 9 | %mstart = p; 10 | %mend = [p(2:end,:); p(1,:)]; 11 | 12 | arrow3(mstart, mend, varargin{:}); 13 | -------------------------------------------------------------------------------- /common/plotp.m: -------------------------------------------------------------------------------- 1 | %PLOTP Plot trajectories 2 | % 3 | % PLOTP(P) plots a set of points P, which by Toolbox convention are stored 4 | % one per column. P can be Nx2 or Nx3. By default a linestyle of 'bx' 5 | % is used. 6 | % 7 | % PLOTP(P, LS) as above but the line style arguments LS are passed to plot. 8 | % 9 | % See also PLOT, PLOT2. 10 | function h = plotp(p1, varargin) 11 | 12 | if length(varargin) == 0 13 | varargin = {'bx'}; 14 | end 15 | 16 | if numrows(p1) == 3, 17 | hh = plot3(p1(1,:), p1(2,:), p1(3,:), varargin{:}); 18 | xyzlabel 19 | else 20 | hh = plot(p1(1,:), p1(2,:), varargin{:}); 21 | xlabel('x'); 22 | ylabel('y'); 23 | end 24 | if nargout == 1, 25 | h = hh; 26 | end 27 | -------------------------------------------------------------------------------- /common/polydiff.m: -------------------------------------------------------------------------------- 1 | % POLYDIFF pd = polydiff(p) 2 | % 3 | % Return the coefficients of the derivative of polynomial p 4 | % 5 | function pd = polydiff(p) 6 | n = length(p)-1; 7 | 8 | pd = [n:-1:1] .* p(1:n); 9 | -------------------------------------------------------------------------------- /common/randinit.m: -------------------------------------------------------------------------------- 1 | %RANDINIT Reset random number generator 2 | % 3 | % RANDINIT reset the defaul random number stream. 4 | % 5 | % See also RandStream. 6 | 7 | function randinit(seed) 8 | 9 | stream = RandStream.getGlobalStream; 10 | stream.reset() 11 | 12 | -------------------------------------------------------------------------------- /common/xaxis.m: -------------------------------------------------------------------------------- 1 | %XAXIS Set X-axis scaling 2 | % 3 | % XAXIS(MAX) set x-axis scaling from 0 to MAX. 4 | % 5 | % XAXIS(MIN, MAX) set x-axis scaling from MIN to MAX. 6 | % 7 | % XAXIS([MIN MAX]) as above. 8 | % 9 | % XAXIS restore automatic scaling for x-axis. 10 | 11 | function xaxis(varargin) 12 | 13 | opt.all = false; 14 | [opt,args] = tb_optparse(opt, varargin); 15 | 16 | if length(args) == 0 17 | [x,y] = ginput(2); 18 | mn = x(1); 19 | mx = x(2); 20 | elseif length(args) == 1 21 | if length(args{1}) == 1 22 | mn = 0; 23 | mx = args{1}; 24 | elseif length(args{1}) == 2 25 | mn = args{1}(1); 26 | mx = args{1}(2); 27 | end 28 | elseif length(args) == 2 29 | mn = args{1}; 30 | mx = args{2}; 31 | end 32 | 33 | if opt.all 34 | for a=get(gcf,'Children')', 35 | if strcmp(get(a, 'Type'), 'axes') == 1, 36 | set(a, 'XLimMode', 'manual', 'XLim', [mn mx]) 37 | set(a, 'YLimMode', 'auto') 38 | end 39 | end 40 | else 41 | set(gca, 'XLimMode', 'manual', 'XLim', [mn mx]) 42 | set(gca, 'YLimMode', 'auto') 43 | end -------------------------------------------------------------------------------- /common/xyzlabel.m: -------------------------------------------------------------------------------- 1 | %XYZLABEL Label X, Y and Z axes 2 | % 3 | % XYZLABEL label the x-, y- and z-axes with 'X', 'Y', and 'Z' 4 | % respectiveley 5 | function xyzlabel 6 | xlabel('x'); 7 | ylabel('y'); 8 | zlabel('z'); 9 | -------------------------------------------------------------------------------- /common/yaxis.m: -------------------------------------------------------------------------------- 1 | %YAYIS set Y-axis scaling 2 | % 3 | % YAYIS(max) 4 | % YAYIS(min, max) 5 | % 6 | % YAXIS restore automatic scaling for this axis 7 | 8 | function yaxis(a1, a2) 9 | if nargin == 0, 10 | set(gca, 'YLimMode', 'auto') 11 | return 12 | elseif nargin == 1, 13 | if length(a1) == 1, 14 | mn = 0; 15 | mx = a1; 16 | elseif length(a1) == 2, 17 | mn = a1(1); 18 | mx = a1(2); 19 | end 20 | elseif nargin == 2, 21 | mn = a1; 22 | mx = a2; 23 | end 24 | 25 | set(gca, 'YLimMode', 'manual', 'YLim', [mn mx]) 26 | -------------------------------------------------------------------------------- /robot/@CodeGenerator/.CodeGenerator.m.swp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/@CodeGenerator/.CodeGenerator.m.swp -------------------------------------------------------------------------------- /robot/@CodeGenerator/.gencoriolis.m.swp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/@CodeGenerator/.gencoriolis.m.swp -------------------------------------------------------------------------------- /robot/@CodeGenerator/.svn/dir-prop-base: -------------------------------------------------------------------------------- 1 | K 13 2 | svn:mergeinfo 3 | V 44 4 | /matlab/branches/book/@codeGenerator:212-700 5 | END 6 | -------------------------------------------------------------------------------- /robot/@CodeGenerator/.svn/prop-base/CodeGenerator.m.svn-base: -------------------------------------------------------------------------------- 1 | K 13 2 | svn:mergeinfo 3 | V 60 4 | /matlab/branches/book/@codeGenerator/codeGenerator.m:212-700 5 | END 6 | -------------------------------------------------------------------------------- /robot/@CodeGenerator/.svn/tmp/CodeGenerator.m.tmp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/@CodeGenerator/.svn/tmp/CodeGenerator.m.tmp -------------------------------------------------------------------------------- /robot/@CodeGenerator/.svn/tmp/gencoriolis.m.tmp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/@CodeGenerator/.svn/tmp/gencoriolis.m.tmp -------------------------------------------------------------------------------- /robot/@CodeGenerator/.svn/tmp/genfdyn.m.tmp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/@CodeGenerator/.svn/tmp/genfdyn.m.tmp -------------------------------------------------------------------------------- /robot/@CodeGenerator/.svn/tmp/genfkine.m.tmp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/@CodeGenerator/.svn/tmp/genfkine.m.tmp -------------------------------------------------------------------------------- /robot/@CodeGenerator/.svn/tmp/genfriction.m.tmp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/@CodeGenerator/.svn/tmp/genfriction.m.tmp -------------------------------------------------------------------------------- /robot/@CodeGenerator/private/.svn/all-wcprops: -------------------------------------------------------------------------------- 1 | K 25 2 | svn:wc:ra_dav:version-url 3 | V 60 4 | /svn/!svn/ver/1074/matlab/robot/trunk/@CodeGenerator/private 5 | END 6 | replaceheader.m 7 | K 25 8 | svn:wc:ra_dav:version-url 9 | V 76 10 | /svn/!svn/ver/1074/matlab/robot/trunk/@CodeGenerator/private/replaceheader.m 11 | END 12 | getpibugfixstring.m 13 | K 25 14 | svn:wc:ra_dav:version-url 15 | V 80 16 | /svn/!svn/ver/1074/matlab/robot/trunk/@CodeGenerator/private/getpibugfixstring.m 17 | END 18 | constructheaderstring.m 19 | K 25 20 | svn:wc:ra_dav:version-url 21 | V 84 22 | /svn/!svn/ver/1074/matlab/robot/trunk/@CodeGenerator/private/constructheaderstring.m 23 | END 24 | createmconstructor.m 25 | K 25 26 | svn:wc:ra_dav:version-url 27 | V 81 28 | /svn/!svn/ver/1074/matlab/robot/trunk/@CodeGenerator/private/createmconstructor.m 29 | END 30 | generatecopyrightnote.m 31 | K 25 32 | svn:wc:ra_dav:version-url 33 | V 84 34 | /svn/!svn/ver/1074/matlab/robot/trunk/@CodeGenerator/private/generatecopyrightnote.m 35 | END 36 | createnewblocklibrary.m 37 | K 25 38 | svn:wc:ra_dav:version-url 39 | V 84 40 | /svn/!svn/ver/1057/matlab/robot/trunk/@CodeGenerator/private/createnewblocklibrary.m 41 | END 42 | ffindreplace.m 43 | K 25 44 | svn:wc:ra_dav:version-url 45 | V 75 46 | /svn/!svn/ver/1074/matlab/robot/trunk/@CodeGenerator/private/ffindreplace.m 47 | END 48 | finsertfront.m 49 | K 25 50 | svn:wc:ra_dav:version-url 51 | V 75 52 | /svn/!svn/ver/1074/matlab/robot/trunk/@CodeGenerator/private/finsertfront.m 53 | END 54 | -------------------------------------------------------------------------------- /robot/@SerialLink/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/@SerialLink/.DS_Store -------------------------------------------------------------------------------- /robot/@SerialLink/.svn/text-base/cinertia.m.svn-base: -------------------------------------------------------------------------------- 1 | %SerialLink.cinertia Cartesian inertia matrix 2 | % 3 | % M = R.cinertia(Q) is the NxN Cartesian (operational space) inertia matrix which relates 4 | % Cartesian force/torque to Cartesian acceleration at the joint configuration Q, and N 5 | % is the number of robot joints. 6 | % 7 | % See also SerialLink.inertia, SerialLink.rne. 8 | 9 | % MOD HISTORY 10 | % 4/99 add object support 11 | % $Log: not supported by cvs2svn $ 12 | % $Revision: 1.2 $ 13 | 14 | 15 | 16 | % Copyright (C) 1993-2011, by Peter I. Corke 17 | % 18 | % This file is part of The Robotics Toolbox for Matlab (RTB). 19 | % 20 | % RTB is free software: you can redistribute it and/or modify 21 | % it under the terms of the GNU Lesser General Public License as published by 22 | % the Free Software Foundation, either version 3 of the License, or 23 | % (at your option) any later version. 24 | % 25 | % RTB is distributed in the hope that it will be useful, 26 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 27 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 28 | % GNU Lesser General Public License for more details. 29 | % 30 | % You should have received a copy of the GNU Leser General Public License 31 | % along with RTB. If not, see . 32 | % 33 | % http://www.petercorke.com 34 | 35 | function Mx = cinertia(robot, q) 36 | J = jacob0(robot, q); 37 | Ji = inv(J); %#ok<*MINV> 38 | M = inertia(robot, q); 39 | Mx = Ji' * M * Ji; 40 | -------------------------------------------------------------------------------- /robot/@SerialLink/.svn/text-base/friction.m.svn-base: -------------------------------------------------------------------------------- 1 | %SerialLink.friction Friction force 2 | % 3 | % TAU = R.friction(QD) is the vector of joint friction forces/torques for the 4 | % robot moving with joint velocities QD. 5 | % 6 | % The friction model includes: 7 | % - viscous friction which is linear with velocity; 8 | % - Coulomb friction which is proportional to sign(QD). 9 | % 10 | % See also Link.friction. 11 | 12 | 13 | 14 | % Copyright (C) 1993-2011, by Peter I. Corke 15 | % 16 | % This file is part of The Robotics Toolbox for Matlab (RTB). 17 | % 18 | % RTB is free software: you can redistribute it and/or modify 19 | % it under the terms of the GNU Lesser General Public License as published by 20 | % the Free Software Foundation, either version 3 of the License, or 21 | % (at your option) any later version. 22 | % 23 | % RTB is distributed in the hope that it will be useful, 24 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 25 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 26 | % GNU Lesser General Public License for more details. 27 | % 28 | % You should have received a copy of the GNU Leser General Public License 29 | % along with RTB. If not, see . 30 | % 31 | % http://www.petercorke.com 32 | 33 | function tau = friction(robot, qd) 34 | 35 | L = robot.links; 36 | 37 | tau = zeros(1,robot.n); 38 | if robot.issym 39 | tau = sym(tau); 40 | end 41 | 42 | 43 | for j=1:robot.n 44 | tau(j) = L(j).friction(qd(j)); 45 | end 46 | 47 | -------------------------------------------------------------------------------- /robot/@SerialLink/.svn/text-base/gencoords.m.svn-base: -------------------------------------------------------------------------------- 1 | %GENCOORDS Vector of symbolic generalized coordinates 2 | % 3 | % Q = R.GENCOORDS is a vector (1xN) of symbols [q1 q2 ... qN]. 4 | % 5 | % [Q,QD] = R.GENCOORDS as above but QD is a vector (1xN) of 6 | % symbols [qd1 qd2 ... qdN]. 7 | % 8 | % [Q,QD,QDD] = R.GENCOORDS as above but QDD is a vector (1xN) of 9 | % symbols [qdd1 qdd2 ... qddN]. 10 | % 11 | % 12 | function [q,qd,qdd] = gencoords(r) 13 | 14 | if nargout > 0 15 | for j=1:r.n 16 | q(j) = sym( sprintf('q%d', j), 'real' ); 17 | end 18 | end 19 | 20 | if nargout > 1 21 | for j=1:r.n 22 | qd(j) = sym( sprintf('qd%d', j), 'real' ); 23 | end 24 | end 25 | 26 | if nargout > 2 27 | for j=1:r.n 28 | qdd(j) = sym( sprintf('qdd%d', j), 'real' ); 29 | end 30 | end 31 | -------------------------------------------------------------------------------- /robot/@SerialLink/.svn/text-base/genforces.m.svn-base: -------------------------------------------------------------------------------- 1 | function tau = genforces(r) 2 | 3 | for j=1:r.n 4 | tau(j) = sym( sprintf('tau%d', j), 'real' ); 5 | end 6 | -------------------------------------------------------------------------------- /robot/@SerialLink/.svn/text-base/issym.m.svn-base: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/@SerialLink/.svn/text-base/issym.m.svn-base -------------------------------------------------------------------------------- /robot/@SerialLink/cinertia.m: -------------------------------------------------------------------------------- 1 | %SerialLink.cinertia Cartesian inertia matrix 2 | % 3 | % M = R.cinertia(Q) is the NxN Cartesian (operational space) inertia matrix which relates 4 | % Cartesian force/torque to Cartesian acceleration at the joint configuration Q, and N 5 | % is the number of robot joints. 6 | % 7 | % See also SerialLink.inertia, SerialLink.rne. 8 | 9 | % MOD HISTORY 10 | % 4/99 add object support 11 | % $Log: not supported by cvs2svn $ 12 | % $Revision: 1.2 $ 13 | 14 | 15 | 16 | % Copyright (C) 1993-2011, by Peter I. Corke 17 | % 18 | % This file is part of The Robotics Toolbox for Matlab (RTB). 19 | % 20 | % RTB is free software: you can redistribute it and/or modify 21 | % it under the terms of the GNU Lesser General Public License as published by 22 | % the Free Software Foundation, either version 3 of the License, or 23 | % (at your option) any later version. 24 | % 25 | % RTB is distributed in the hope that it will be useful, 26 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 27 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 28 | % GNU Lesser General Public License for more details. 29 | % 30 | % You should have received a copy of the GNU Leser General Public License 31 | % along with RTB. If not, see . 32 | % 33 | % http://www.petercorke.com 34 | 35 | function Mx = cinertia(robot, q) 36 | J = jacob0(robot, q); 37 | Ji = inv(J); %#ok<*MINV> 38 | M = inertia(robot, q); 39 | Mx = Ji' * M * Ji; 40 | -------------------------------------------------------------------------------- /robot/@SerialLink/createBlockCGJacobianDH.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/@SerialLink/createBlockCGJacobianDH.m -------------------------------------------------------------------------------- /robot/@SerialLink/createBlockDirKinematicDH.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/@SerialLink/createBlockDirKinematicDH.m -------------------------------------------------------------------------------- /robot/@SerialLink/createBlockJacobianDH.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/@SerialLink/createBlockJacobianDH.m -------------------------------------------------------------------------------- /robot/@SerialLink/createCGJacobianDH.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/@SerialLink/createCGJacobianDH.m -------------------------------------------------------------------------------- /robot/@SerialLink/createDirKinematicDH.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/@SerialLink/createDirKinematicDH.m -------------------------------------------------------------------------------- /robot/@SerialLink/createGenAccelerations.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/@SerialLink/createGenAccelerations.m -------------------------------------------------------------------------------- /robot/@SerialLink/createGenCoordinates.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/@SerialLink/createGenCoordinates.m -------------------------------------------------------------------------------- /robot/@SerialLink/createGenForces.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/@SerialLink/createGenForces.m -------------------------------------------------------------------------------- /robot/@SerialLink/createGenVelocities.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/@SerialLink/createGenVelocities.m -------------------------------------------------------------------------------- /robot/@SerialLink/createJacobianDH.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/@SerialLink/createJacobianDH.m -------------------------------------------------------------------------------- /robot/@SerialLink/friction.m: -------------------------------------------------------------------------------- 1 | %SerialLink.friction Friction force 2 | % 3 | % TAU = R.friction(QD) is the vector of joint friction forces/torques for the 4 | % robot moving with joint velocities QD. 5 | % 6 | % The friction model includes: 7 | % - viscous friction which is linear with velocity; 8 | % - Coulomb friction which is proportional to sign(QD). 9 | % 10 | % See also Link.friction. 11 | 12 | 13 | 14 | % Copyright (C) 1993-2011, by Peter I. Corke 15 | % 16 | % This file is part of The Robotics Toolbox for Matlab (RTB). 17 | % 18 | % RTB is free software: you can redistribute it and/or modify 19 | % it under the terms of the GNU Lesser General Public License as published by 20 | % the Free Software Foundation, either version 3 of the License, or 21 | % (at your option) any later version. 22 | % 23 | % RTB is distributed in the hope that it will be useful, 24 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 25 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 26 | % GNU Lesser General Public License for more details. 27 | % 28 | % You should have received a copy of the GNU Leser General Public License 29 | % along with RTB. If not, see . 30 | % 31 | % http://www.petercorke.com 32 | 33 | function tau = friction(robot, qd) 34 | 35 | L = robot.links; 36 | 37 | tau = zeros(1,robot.n); 38 | if robot.issym 39 | tau = sym(tau); 40 | end 41 | 42 | 43 | for j=1:robot.n 44 | tau(j) = L(j).friction(qd(j)); 45 | end 46 | 47 | -------------------------------------------------------------------------------- /robot/@SerialLink/frne.mexmaci64: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/@SerialLink/frne.mexmaci64 -------------------------------------------------------------------------------- /robot/@SerialLink/frne.mexw32: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/@SerialLink/frne.mexw32 -------------------------------------------------------------------------------- /robot/@SerialLink/gencoords.m: -------------------------------------------------------------------------------- 1 | %GENCOORDS Vector of symbolic generalized coordinates 2 | % 3 | % Q = R.GENCOORDS is a vector (1xN) of symbols [q1 q2 ... qN]. 4 | % 5 | % [Q,QD] = R.GENCOORDS as above but QD is a vector (1xN) of 6 | % symbols [qd1 qd2 ... qdN]. 7 | % 8 | % [Q,QD,QDD] = R.GENCOORDS as above but QDD is a vector (1xN) of 9 | % symbols [qdd1 qdd2 ... qddN]. 10 | % 11 | % 12 | function [q,qd,qdd] = gencoords(r) 13 | 14 | if nargout > 0 15 | for j=1:r.n 16 | q(j) = sym( sprintf('q%d', j), 'real' ); 17 | end 18 | end 19 | 20 | if nargout > 1 21 | for j=1:r.n 22 | qd(j) = sym( sprintf('qd%d', j), 'real' ); 23 | end 24 | end 25 | 26 | if nargout > 2 27 | for j=1:r.n 28 | qdd(j) = sym( sprintf('qdd%d', j), 'real' ); 29 | end 30 | end 31 | -------------------------------------------------------------------------------- /robot/@SerialLink/genforces.m: -------------------------------------------------------------------------------- 1 | function tau = genforces(r) 2 | 3 | for j=1:r.n 4 | tau(j) = sym( sprintf('tau%d', j), 'real' ); 5 | end 6 | -------------------------------------------------------------------------------- /robot/@SerialLink/issym.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/@SerialLink/issym.m -------------------------------------------------------------------------------- /robot/@SerialLink/private/.svn/all-wcprops: -------------------------------------------------------------------------------- 1 | K 25 2 | svn:wc:ra_dav:version-url 3 | V 56 4 | /svn/!svn/ver/722/matlab/robot/trunk/@SerialLink/private 5 | END 6 | findjobj.m 7 | K 25 8 | svn:wc:ra_dav:version-url 9 | V 67 10 | /svn/!svn/ver/722/matlab/robot/trunk/@SerialLink/private/findjobj.m 11 | END 12 | -------------------------------------------------------------------------------- /robot/@SerialLink/private/.svn/entries: -------------------------------------------------------------------------------- 1 | 10 2 | 3 | dir 4 | 1080 5 | https://matlab-toolboxes-robotics-vision.googlecode.com/svn/matlab/robot/trunk/@SerialLink/private 6 | https://matlab-toolboxes-robotics-vision.googlecode.com/svn 7 | 8 | 9 | 10 | 2012-02-11T11:59:11.238769Z 11 | 702 12 | pic 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 95aecb5c-93d2-d4e9-359e-440943d9824e 28 | 29 | findjobj.m 30 | file 31 | 32 | 33 | 34 | 35 | 2012-05-07T03:55:31.000000Z 36 | f45e1ce78828aaed294df3ca183b046f 37 | 2012-02-11T11:59:11.238769Z 38 | 702 39 | pic 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 126640 62 | 63 | -------------------------------------------------------------------------------- /robot/@SerialLink/rne.mexmaci64: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/@SerialLink/rne.mexmaci64 -------------------------------------------------------------------------------- /robot/@SerialLink/rne.mexw32: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/@SerialLink/rne.mexw32 -------------------------------------------------------------------------------- /robot/@SerialLink/slink.m: -------------------------------------------------------------------------------- 1 | function sl = slink(l) 2 | 3 | sl = Link(l); % clone the link 4 | 5 | if sl.alpha == pi/2 6 | sl.alpha = sym('pi/2'); 7 | end 8 | if sl.alpha == -pi/2 9 | sl.alpha = sym('-pi/2'); 10 | end 11 | if sl.alpha == pi 12 | sl.alpha = sym('pi'); 13 | end 14 | if sl.alpha == -pi 15 | sl.alpha = sym('-pi'); 16 | end 17 | 18 | if l.isprismatic 19 | if sl.alpha == pi/2 20 | sl.alpha = sym('pi/2'); 21 | end 22 | if sl.alpha == -pi/2 23 | sl.alpha = sym('-pi/2'); 24 | end 25 | if sl.alpha == pi 26 | sl.alpha = sym('pi'); 27 | end 28 | if sl.alpha == -pi 29 | sl.alpha = sym('-pi'); 30 | end 31 | end 32 | -------------------------------------------------------------------------------- /robot/CITATION: -------------------------------------------------------------------------------- 1 | Citing the Toolbox: 2 | ------------------ 3 | 4 | If you use the Toolbox and want to cite it in a paper please use: 5 | 6 | @book{Corke11a, 7 | Author = {Peter I. Corke}, 8 | Date-Added = {2011-01-12 08:19:32 +1000}, 9 | Date-Modified = {2011-07-26 12:27:18 +0200}, 10 | Note = {ISBN 978-3-642-20143-1}, 11 | Publisher = {Springer}, 12 | Title = {Robotics, Vision \& Control: Fundamental Algorithms in Matlab}, 13 | Year = {2011}} 14 | 15 | -------------------------------------------------------------------------------- /robot/CONTRIB: -------------------------------------------------------------------------------- 1 | The following files are contributed by others: 2 | 3 | % Robert Biro with Gary Von McMurray 4 | SerialLink.ikine560.m 5 | 6 | %Wynand Swart 7 | mdl_Fanuc10L.m: 8 | mdl_MotomanHP6.m 9 | mdl_S4ABB2p8.m 10 | 11 | %Paul Pounds 12 | quadrotor_dynamics.m 13 | quadrotor_plot.m 14 | 15 | %Paul Newman 16 | EKF.m 17 | 18 | %Joern Malzahn 19 | @CodeGenerator 20 | common/distributeblocks 21 | common/doesblockexist 22 | common/multidfprintf 23 | common/symexpr2slblock 24 | common/simulinkext 25 | -------------------------------------------------------------------------------- /robot/DH.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/DH.jar -------------------------------------------------------------------------------- /robot/Octave/.svn/all-wcprops: -------------------------------------------------------------------------------- 1 | K 25 2 | svn:wc:ra_dav:version-url 3 | V 43 4 | /svn/!svn/ver/726/matlab/robot/trunk/Octave 5 | END 6 | README.txt 7 | K 25 8 | svn:wc:ra_dav:version-url 9 | V 54 10 | /svn/!svn/ver/726/matlab/robot/trunk/Octave/README.txt 11 | END 12 | -------------------------------------------------------------------------------- /robot/Octave/.svn/entries: -------------------------------------------------------------------------------- 1 | 10 2 | 3 | dir 4 | 1080 5 | https://matlab-toolboxes-robotics-vision.googlecode.com/svn/matlab/robot/trunk/Octave 6 | https://matlab-toolboxes-robotics-vision.googlecode.com/svn 7 | 8 | 9 | 10 | 2012-02-12T11:18:36.428341Z 11 | 726 12 | pic 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 95aecb5c-93d2-d4e9-359e-440943d9824e 28 | 29 | @Quaternion 30 | dir 31 | 32 | README.txt 33 | file 34 | 35 | 36 | 37 | 38 | 2012-05-07T03:55:34.000000Z 39 | 8d1eddaf0d1d21bb243e54ca08427170 40 | 2012-02-12T11:18:36.428341Z 41 | 726 42 | pic 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 2414 65 | 66 | @SerialLink 67 | dir 68 | 69 | @Link 70 | dir 71 | 72 | -------------------------------------------------------------------------------- /robot/Octave/@Link/.svn/all-wcprops: -------------------------------------------------------------------------------- 1 | K 25 2 | svn:wc:ra_dav:version-url 3 | V 49 4 | /svn/!svn/ver/726/matlab/robot/trunk/Octave/@Link 5 | END 6 | subsasgn.m 7 | K 25 8 | svn:wc:ra_dav:version-url 9 | V 60 10 | /svn/!svn/ver/726/matlab/robot/trunk/Octave/@Link/subsasgn.m 11 | END 12 | display.m 13 | K 25 14 | svn:wc:ra_dav:version-url 15 | V 59 16 | /svn/!svn/ver/726/matlab/robot/trunk/Octave/@Link/display.m 17 | END 18 | subsref.m 19 | K 25 20 | svn:wc:ra_dav:version-url 21 | V 59 22 | /svn/!svn/ver/726/matlab/robot/trunk/Octave/@Link/subsref.m 23 | END 24 | nofriction.m 25 | K 25 26 | svn:wc:ra_dav:version-url 27 | V 62 28 | /svn/!svn/ver/726/matlab/robot/trunk/Octave/@Link/nofriction.m 29 | END 30 | friction.m 31 | K 25 32 | svn:wc:ra_dav:version-url 33 | V 60 34 | /svn/!svn/ver/726/matlab/robot/trunk/Octave/@Link/friction.m 35 | END 36 | char.m 37 | K 25 38 | svn:wc:ra_dav:version-url 39 | V 56 40 | /svn/!svn/ver/726/matlab/robot/trunk/Octave/@Link/char.m 41 | END 42 | Link.m 43 | K 25 44 | svn:wc:ra_dav:version-url 45 | V 56 46 | /svn/!svn/ver/726/matlab/robot/trunk/Octave/@Link/Link.m 47 | END 48 | show.m 49 | K 25 50 | svn:wc:ra_dav:version-url 51 | V 56 52 | /svn/!svn/ver/726/matlab/robot/trunk/Octave/@Link/show.m 53 | END 54 | sigma.m 55 | K 25 56 | svn:wc:ra_dav:version-url 57 | V 57 58 | /svn/!svn/ver/726/matlab/robot/trunk/Octave/@Link/sigma.m 59 | END 60 | RP.m 61 | K 25 62 | svn:wc:ra_dav:version-url 63 | V 54 64 | /svn/!svn/ver/726/matlab/robot/trunk/Octave/@Link/RP.m 65 | END 66 | -------------------------------------------------------------------------------- /robot/Octave/@Link/.svn/text-base/RP.m.svn-base: -------------------------------------------------------------------------------- 1 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 2 | % 3 | % Copyright (C) 1993-2011, by Peter I. Corke 4 | % 5 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 6 | % 7 | % RTB is free software: you can redistribute it and/or modify 8 | % it under the terms of the GNU Lesser General Public License as published by 9 | % the Free Software Foundation, either version 3 of the License, or 10 | % (at your option) any later version. 11 | % 12 | % RTB is distributed in the hope that it will be useful, 13 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | % GNU Lesser General Public License for more details. 16 | % 17 | % You should have received a copy of the GNU Leser General Public License 18 | % along with RTB. If not, see . 19 | % 20 | % http://www.petercorke.com 21 | endfunction 22 | -------------------------------------------------------------------------------- /robot/Octave/@Link/.svn/text-base/display.m.svn-base: -------------------------------------------------------------------------------- 1 | %DISPLAY display the value of a LINK object 2 | 3 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 4 | % 5 | % Copyright (C) 1993-2011, by Peter I. Corke 6 | % 7 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 8 | % 9 | % RTB is free software: you can redistribute it and/or modify 10 | % it under the terms of the GNU Lesser General Public License as published by 11 | % the Free Software Foundation, either version 3 of the License, or 12 | % (at your option) any later version. 13 | % 14 | % RTB is distributed in the hope that it will be useful, 15 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 16 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 17 | % GNU Lesser General Public License for more details. 18 | % 19 | % You should have received a copy of the GNU Leser General Public License 20 | % along with RTB. If not, see . 21 | % 22 | % http://www.petercorke.com 23 | 24 | % Copright (C) Peter Corke 1999 25 | function display(l) 26 | 27 | disp([inputname(1), ' = ']) 28 | disp( char(l) ); 29 | end 30 | -------------------------------------------------------------------------------- /robot/Octave/@Link/.svn/text-base/show.m.svn-base: -------------------------------------------------------------------------------- 1 | %SHOW show all parameters of LINK object 2 | % 3 | % SHOW(link) 4 | 5 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 6 | % 7 | % Copyright (C) 1993-2011, by Peter I. Corke 8 | % 9 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 10 | % 11 | % RTB is free software: you can redistribute it and/or modify 12 | % it under the terms of the GNU Lesser General Public License as published by 13 | % the Free Software Foundation, either version 3 of the License, or 14 | % (at your option) any later version. 15 | % 16 | % RTB is distributed in the hope that it will be useful, 17 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 18 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 19 | % GNU Lesser General Public License for more details. 20 | % 21 | % You should have received a copy of the GNU Leser General Public License 22 | % along with RTB. If not, see . 23 | % 24 | % http://www.petercorke.com 25 | 26 | function show(l) 27 | 28 | llab = 6; 29 | for n =fieldnames(l)' 30 | v = getfield(l, char(n)); 31 | name = char(n); 32 | spaces = char(' '*ones(1,llab-length(name))); 33 | val = num2str(v); 34 | label = [name spaces ' = ']; 35 | if numrows(val) > 1, 36 | pad = {label; char(' '*ones(numrows(val)-1,1))}; 37 | else 38 | pad = label; 39 | end 40 | disp([char(pad) val]); 41 | end 42 | -------------------------------------------------------------------------------- /robot/Octave/@Link/.svn/text-base/sigma.m.svn-base: -------------------------------------------------------------------------------- 1 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 2 | % 3 | % Copyright (C) 1993-2011, by Peter I. Corke 4 | % 5 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 6 | % 7 | % RTB is free software: you can redistribute it and/or modify 8 | % it under the terms of the GNU Lesser General Public License as published by 9 | % the Free Software Foundation, either version 3 of the License, or 10 | % (at your option) any later version. 11 | % 12 | % RTB is distributed in the hope that it will be useful, 13 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | % GNU Lesser General Public License for more details. 16 | % 17 | % You should have received a copy of the GNU Leser General Public License 18 | % along with RTB. If not, see . 19 | % 20 | % http://www.petercorke.com 21 | end 22 | -------------------------------------------------------------------------------- /robot/Octave/@Link/RP.m: -------------------------------------------------------------------------------- 1 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 2 | % 3 | % Copyright (C) 1993-2011, by Peter I. Corke 4 | % 5 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 6 | % 7 | % RTB is free software: you can redistribute it and/or modify 8 | % it under the terms of the GNU Lesser General Public License as published by 9 | % the Free Software Foundation, either version 3 of the License, or 10 | % (at your option) any later version. 11 | % 12 | % RTB is distributed in the hope that it will be useful, 13 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | % GNU Lesser General Public License for more details. 16 | % 17 | % You should have received a copy of the GNU Leser General Public License 18 | % along with RTB. If not, see . 19 | % 20 | % http://www.petercorke.com 21 | endfunction 22 | -------------------------------------------------------------------------------- /robot/Octave/@Link/display.m: -------------------------------------------------------------------------------- 1 | %DISPLAY display the value of a LINK object 2 | 3 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 4 | % 5 | % Copyright (C) 1993-2011, by Peter I. Corke 6 | % 7 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 8 | % 9 | % RTB is free software: you can redistribute it and/or modify 10 | % it under the terms of the GNU Lesser General Public License as published by 11 | % the Free Software Foundation, either version 3 of the License, or 12 | % (at your option) any later version. 13 | % 14 | % RTB is distributed in the hope that it will be useful, 15 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 16 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 17 | % GNU Lesser General Public License for more details. 18 | % 19 | % You should have received a copy of the GNU Leser General Public License 20 | % along with RTB. If not, see . 21 | % 22 | % http://www.petercorke.com 23 | 24 | % Copright (C) Peter Corke 1999 25 | function display(l) 26 | 27 | disp([inputname(1), ' = ']) 28 | disp( char(l) ); 29 | end 30 | -------------------------------------------------------------------------------- /robot/Octave/@Link/nofriction.m: -------------------------------------------------------------------------------- 1 | %NOFRICTION return link object with zero friction 2 | % 3 | % LINK = NOFRICTION(LINK) 4 | % 5 | % 6 | 7 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 8 | % 9 | % Copyright (C) 1993-2011, by Peter I. Corke 10 | % 11 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 12 | % 13 | % RTB is free software: you can redistribute it and/or modify 14 | % it under the terms of the GNU Lesser General Public License as published by 15 | % the Free Software Foundation, either version 3 of the License, or 16 | % (at your option) any later version. 17 | % 18 | % RTB is distributed in the hope that it will be useful, 19 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 20 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 21 | % GNU Lesser General Public License for more details. 22 | % 23 | % You should have received a copy of the GNU Leser General Public License 24 | % along with RTB. If not, see . 25 | % 26 | % http://www.petercorke.com 27 | function l2 = nofriction(l, only) 28 | %Link.nofriction Remove friction 29 | % 30 | % LN = L.nofriction() is a link object with the same parameters as L except 31 | % nonlinear (Coulomb) friction parameter is zero. 32 | % 33 | % LN = L.nofriction('all') is a link object with the same parameters as L 34 | % except all friction parameters are zero. 35 | 36 | l2 = Link(l); 37 | if (nargin == 2) && strcmpi(only(1:3), 'all') 38 | l2.B = 0; 39 | end 40 | l2.Tc = [0 0]; 41 | end 42 | -------------------------------------------------------------------------------- /robot/Octave/@Link/show.m: -------------------------------------------------------------------------------- 1 | %SHOW show all parameters of LINK object 2 | % 3 | % SHOW(link) 4 | 5 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 6 | % 7 | % Copyright (C) 1993-2011, by Peter I. Corke 8 | % 9 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 10 | % 11 | % RTB is free software: you can redistribute it and/or modify 12 | % it under the terms of the GNU Lesser General Public License as published by 13 | % the Free Software Foundation, either version 3 of the License, or 14 | % (at your option) any later version. 15 | % 16 | % RTB is distributed in the hope that it will be useful, 17 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 18 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 19 | % GNU Lesser General Public License for more details. 20 | % 21 | % You should have received a copy of the GNU Leser General Public License 22 | % along with RTB. If not, see . 23 | % 24 | % http://www.petercorke.com 25 | 26 | function show(l) 27 | 28 | llab = 6; 29 | for n =fieldnames(l)' 30 | v = getfield(l, char(n)); 31 | name = char(n); 32 | spaces = char(' '*ones(1,llab-length(name))); 33 | val = num2str(v); 34 | label = [name spaces ' = ']; 35 | if numrows(val) > 1, 36 | pad = {label; char(' '*ones(numrows(val)-1,1))}; 37 | else 38 | pad = label; 39 | end 40 | disp([char(pad) val]); 41 | end 42 | -------------------------------------------------------------------------------- /robot/Octave/@Link/sigma.m: -------------------------------------------------------------------------------- 1 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 2 | % 3 | % Copyright (C) 1993-2011, by Peter I. Corke 4 | % 5 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 6 | % 7 | % RTB is free software: you can redistribute it and/or modify 8 | % it under the terms of the GNU Lesser General Public License as published by 9 | % the Free Software Foundation, either version 3 of the License, or 10 | % (at your option) any later version. 11 | % 12 | % RTB is distributed in the hope that it will be useful, 13 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | % GNU Lesser General Public License for more details. 16 | % 17 | % You should have received a copy of the GNU Leser General Public License 18 | % along with RTB. If not, see . 19 | % 20 | % http://www.petercorke.com 21 | end 22 | -------------------------------------------------------------------------------- /robot/Octave/@Quaternion/.svn/text-base/char.m.svn-base: -------------------------------------------------------------------------------- 1 | %CHAR create string representation of quaternion object 2 | 3 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 4 | % 5 | % Copyright (C) 1993-2011, by Peter I. Corke 6 | % 7 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 8 | % 9 | % RTB is free software: you can redistribute it and/or modify 10 | % it under the terms of the GNU Lesser General Public License as published by 11 | % the Free Software Foundation, either version 3 of the License, or 12 | % (at your option) any later version. 13 | % 14 | % RTB is distributed in the hope that it will be useful, 15 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 16 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 17 | % GNU Lesser General Public License for more details. 18 | % 19 | % You should have received a copy of the GNU Leser General Public License 20 | % along with RTB. If not, see . 21 | % 22 | % http://www.petercorke.com 23 | 24 | % Copright (C) Peter Corke 1999 25 | function s = char(q) 26 | 27 | s = [num2str(q.s), ' <' num2str(q.v(1)) ', ' num2str(q.v(2)) ', ' num2str(q.v(3)) '>']; 28 | -------------------------------------------------------------------------------- /robot/Octave/@Quaternion/.svn/text-base/display.m.svn-base: -------------------------------------------------------------------------------- 1 | %DISPLAY display the value of a quaternion object 2 | 3 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 4 | % 5 | % Copyright (C) 1993-2011, by Peter I. Corke 6 | % 7 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 8 | % 9 | % RTB is free software: you can redistribute it and/or modify 10 | % it under the terms of the GNU Lesser General Public License as published by 11 | % the Free Software Foundation, either version 3 of the License, or 12 | % (at your option) any later version. 13 | % 14 | % RTB is distributed in the hope that it will be useful, 15 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 16 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 17 | % GNU Lesser General Public License for more details. 18 | % 19 | % You should have received a copy of the GNU Leser General Public License 20 | % along with RTB. If not, see . 21 | % 22 | % http://www.petercorke.com 23 | 24 | % Copright (C) Peter Corke 1999 25 | function display(q) 26 | 27 | disp(' '); 28 | disp([inputname(1), ' = ']) 29 | disp(' '); 30 | disp([' ' char(q)]) 31 | disp(' '); 32 | -------------------------------------------------------------------------------- /robot/Octave/@Quaternion/.svn/text-base/dot.m.svn-base: -------------------------------------------------------------------------------- 1 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 2 | % 3 | % Copyright (C) 1993-2011, by Peter I. Corke 4 | % 5 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 6 | % 7 | % RTB is free software: you can redistribute it and/or modify 8 | % it under the terms of the GNU Lesser General Public License as published by 9 | % the Free Software Foundation, either version 3 of the License, or 10 | % (at your option) any later version. 11 | % 12 | % RTB is distributed in the hope that it will be useful, 13 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | % GNU Lesser General Public License for more details. 16 | % 17 | % You should have received a copy of the GNU Leser General Public License 18 | % along with RTB. If not, see . 19 | % 20 | % http://www.petercorke.com 21 | function qd = dot(q, omega) 22 | E = q.s*eye(3,3) - skew(q.v); 23 | omega = omega(:); 24 | qd = Quaternion(-0.5*q.v*omega, 0.5*E*omega); 25 | end 26 | -------------------------------------------------------------------------------- /robot/Octave/@Quaternion/.svn/text-base/double.m.svn-base: -------------------------------------------------------------------------------- 1 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 2 | % 3 | % Copyright (C) 1993-2011, by Peter I. Corke 4 | % 5 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 6 | % 7 | % RTB is free software: you can redistribute it and/or modify 8 | % it under the terms of the GNU Lesser General Public License as published by 9 | % the Free Software Foundation, either version 3 of the License, or 10 | % (at your option) any later version. 11 | % 12 | % RTB is distributed in the hope that it will be useful, 13 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | % GNU Lesser General Public License for more details. 16 | % 17 | % You should have received a copy of the GNU Leser General Public License 18 | % along with RTB. If not, see . 19 | % 20 | % http://www.petercorke.com 21 | function v = double(q) 22 | %Quaternion.double Convert a quaternion object to a 4-element vector 23 | % 24 | % V = Q.double() is a 4-vector comprising the quaternion 25 | % elements [s vx vy vz]. 26 | 27 | v = [q.s q.v]; 28 | endfunction 29 | 30 | -------------------------------------------------------------------------------- /robot/Octave/@Quaternion/.svn/text-base/inv.m.svn-base: -------------------------------------------------------------------------------- 1 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 2 | % 3 | % Copyright (C) 1993-2011, by Peter I. Corke 4 | % 5 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 6 | % 7 | % RTB is free software: you can redistribute it and/or modify 8 | % it under the terms of the GNU Lesser General Public License as published by 9 | % the Free Software Foundation, either version 3 of the License, or 10 | % (at your option) any later version. 11 | % 12 | % RTB is distributed in the hope that it will be useful, 13 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | % GNU Lesser General Public License for more details. 16 | % 17 | % You should have received a copy of the GNU Leser General Public License 18 | % along with RTB. If not, see . 19 | % 20 | % http://www.petercorke.com 21 | function qi = inv(q) 22 | %Quaternion.inv Invert a unit-quaternion 23 | % 24 | % QI = Q.inv() is a quaternion object representing the inverse of Q. 25 | 26 | qi = Quaternion([q.s -q.v]); 27 | endfunction 28 | -------------------------------------------------------------------------------- /robot/Octave/@Quaternion/.svn/text-base/minus.m.svn-base: -------------------------------------------------------------------------------- 1 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 2 | % 3 | % Copyright (C) 1993-2011, by Peter I. Corke 4 | % 5 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 6 | % 7 | % RTB is free software: you can redistribute it and/or modify 8 | % it under the terms of the GNU Lesser General Public License as published by 9 | % the Free Software Foundation, either version 3 of the License, or 10 | % (at your option) any later version. 11 | % 12 | % RTB is distributed in the hope that it will be useful, 13 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | % GNU Lesser General Public License for more details. 16 | % 17 | % You should have received a copy of the GNU Leser General Public License 18 | % along with RTB. If not, see . 19 | % 20 | % http://www.petercorke.com 21 | function qp = minus(q1, q2) 22 | %Quaternion.minus Subtract two quaternion objects 23 | % 24 | % Q1-Q2 is the element-wise difference of quaternion elements. 25 | 26 | if isa(q1, 'Quaternion') & isa(q2, 'Quaternion') 27 | 28 | qp = Quaternion(double(q1) - double(q2)); 29 | end 30 | end 31 | -------------------------------------------------------------------------------- /robot/Octave/@Quaternion/.svn/text-base/mrdivide.m.svn-base: -------------------------------------------------------------------------------- 1 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 2 | % 3 | % Copyright (C) 1993-2011, by Peter I. Corke 4 | % 5 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 6 | % 7 | % RTB is free software: you can redistribute it and/or modify 8 | % it under the terms of the GNU Lesser General Public License as published by 9 | % the Free Software Foundation, either version 3 of the License, or 10 | % (at your option) any later version. 11 | % 12 | % RTB is distributed in the hope that it will be useful, 13 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | % GNU Lesser General Public License for more details. 16 | % 17 | % You should have received a copy of the GNU Leser General Public License 18 | % along with RTB. If not, see . 19 | % 20 | % http://www.petercorke.com 21 | function qq = mrdivide(q1, q2) 22 | %Quaternion.mrdivide Compute quaternion quotient. 23 | % 24 | % Q1/Q2 is a quaternion formed by Hamilton product of Q1 and inv(Q2) 25 | % Q/S is the element-wise division of quaternion elements by by the scalar S 26 | 27 | if isa(q2, 'Quaternion') 28 | % qq = q1 / q2 29 | % = q1 * qinv(q2) 30 | 31 | qq = q1 * inv(q2); 32 | elseif isa(q2, 'double') 33 | qq = Quaternion( double(q1) / q2 ); 34 | end 35 | end 36 | -------------------------------------------------------------------------------- /robot/Octave/@Quaternion/.svn/text-base/norm.m.svn-base: -------------------------------------------------------------------------------- 1 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 2 | % 3 | % Copyright (C) 1993-2011, by Peter I. Corke 4 | % 5 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 6 | % 7 | % RTB is free software: you can redistribute it and/or modify 8 | % it under the terms of the GNU Lesser General Public License as published by 9 | % the Free Software Foundation, either version 3 of the License, or 10 | % (at your option) any later version. 11 | % 12 | % RTB is distributed in the hope that it will be useful, 13 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | % GNU Lesser General Public License for more details. 16 | % 17 | % You should have received a copy of the GNU Leser General Public License 18 | % along with RTB. If not, see . 19 | % 20 | % http://www.petercorke.com 21 | function n = norm(q) 22 | %Quaternion.norm Compute the norm of a quaternion 23 | % 24 | % QN = Q.norm(Q) is the scalar norm or magnitude of the quaternion Q. 25 | 26 | n = norm(double(q)); 27 | end 28 | -------------------------------------------------------------------------------- /robot/Octave/@Quaternion/.svn/text-base/plus.m.svn-base: -------------------------------------------------------------------------------- 1 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 2 | % 3 | % Copyright (C) 1993-2011, by Peter I. Corke 4 | % 5 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 6 | % 7 | % RTB is free software: you can redistribute it and/or modify 8 | % it under the terms of the GNU Lesser General Public License as published by 9 | % the Free Software Foundation, either version 3 of the License, or 10 | % (at your option) any later version. 11 | % 12 | % RTB is distributed in the hope that it will be useful, 13 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | % GNU Lesser General Public License for more details. 16 | % 17 | % You should have received a copy of the GNU Leser General Public License 18 | % along with RTB. If not, see . 19 | % 20 | % http://www.petercorke.com 21 | function qp = plus(q1, q2) 22 | %PLUS Add two quaternion objects 23 | % 24 | % Q1+Q2 is the element-wise sum of quaternion elements. 25 | 26 | if isa(q1, 'Quaternion') & isa(q2, 'Quaternion') 27 | 28 | qp = Quaternion(double(q1) + double(q2)); 29 | end 30 | end 31 | -------------------------------------------------------------------------------- /robot/Octave/@Quaternion/.svn/text-base/q2tr.m.svn-base: -------------------------------------------------------------------------------- 1 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 2 | % 3 | % Copyright (C) 1993-2011, by Peter I. Corke 4 | % 5 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 6 | % 7 | % RTB is free software: you can redistribute it and/or modify 8 | % it under the terms of the GNU Lesser General Public License as published by 9 | % the Free Software Foundation, either version 3 of the License, or 10 | % (at your option) any later version. 11 | % 12 | % RTB is distributed in the hope that it will be useful, 13 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | % GNU Lesser General Public License for more details. 16 | % 17 | % You should have received a copy of the GNU Leser General Public License 18 | % along with RTB. If not, see . 19 | % 20 | % http://www.petercorke.com 21 | function t = q2tr(q) 22 | 23 | q = double(q); 24 | s = q(1); 25 | x = q(2); 26 | y = q(3); 27 | z = q(4); 28 | 29 | r = [ 1-2*(y^2+z^2) 2*(x*y-s*z) 2*(x*z+s*y) 30 | 2*(x*y+s*z) 1-2*(x^2+z^2) 2*(y*z-s*x) 31 | 2*(x*z-s*y) 2*(y*z+s*x) 1-2*(x^2+y^2) ]; 32 | t = eye(4,4); 33 | t(1:3,1:3) = r; 34 | t(4,4) = 1; 35 | endfunction 36 | -------------------------------------------------------------------------------- /robot/Octave/@Quaternion/.svn/text-base/unit.m.svn-base: -------------------------------------------------------------------------------- 1 | 2 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 3 | % 4 | % Copyright (C) 1993-2011, by Peter I. Corke 5 | % 6 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 7 | % 8 | % RTB is free software: you can redistribute it and/or modify 9 | % it under the terms of the GNU Lesser General Public License as published by 10 | % the Free Software Foundation, either version 3 of the License, or 11 | % (at your option) any later version. 12 | % 13 | % RTB is distributed in the hope that it will be useful, 14 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | % GNU Lesser General Public License for more details. 17 | % 18 | % You should have received a copy of the GNU Leser General Public License 19 | % along with RTB. If not, see . 20 | % 21 | % http://www.petercorke.com 22 | function qu = unit(q) 23 | %Quaternion.unit Unitize a quaternion 24 | % 25 | % QU = Q.unit() is a quaternion which is a unitized version of Q 26 | 27 | qu = q / norm(q); 28 | end 29 | -------------------------------------------------------------------------------- /robot/Octave/@Quaternion/char.m: -------------------------------------------------------------------------------- 1 | %CHAR create string representation of quaternion object 2 | 3 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 4 | % 5 | % Copyright (C) 1993-2011, by Peter I. Corke 6 | % 7 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 8 | % 9 | % RTB is free software: you can redistribute it and/or modify 10 | % it under the terms of the GNU Lesser General Public License as published by 11 | % the Free Software Foundation, either version 3 of the License, or 12 | % (at your option) any later version. 13 | % 14 | % RTB is distributed in the hope that it will be useful, 15 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 16 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 17 | % GNU Lesser General Public License for more details. 18 | % 19 | % You should have received a copy of the GNU Leser General Public License 20 | % along with RTB. If not, see . 21 | % 22 | % http://www.petercorke.com 23 | 24 | % Copright (C) Peter Corke 1999 25 | function s = char(q) 26 | 27 | s = [num2str(q.s), ' <' num2str(q.v(1)) ', ' num2str(q.v(2)) ', ' num2str(q.v(3)) '>']; 28 | -------------------------------------------------------------------------------- /robot/Octave/@Quaternion/display.m: -------------------------------------------------------------------------------- 1 | %DISPLAY display the value of a quaternion object 2 | 3 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 4 | % 5 | % Copyright (C) 1993-2011, by Peter I. Corke 6 | % 7 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 8 | % 9 | % RTB is free software: you can redistribute it and/or modify 10 | % it under the terms of the GNU Lesser General Public License as published by 11 | % the Free Software Foundation, either version 3 of the License, or 12 | % (at your option) any later version. 13 | % 14 | % RTB is distributed in the hope that it will be useful, 15 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 16 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 17 | % GNU Lesser General Public License for more details. 18 | % 19 | % You should have received a copy of the GNU Leser General Public License 20 | % along with RTB. If not, see . 21 | % 22 | % http://www.petercorke.com 23 | 24 | % Copright (C) Peter Corke 1999 25 | function display(q) 26 | 27 | disp(' '); 28 | disp([inputname(1), ' = ']) 29 | disp(' '); 30 | disp([' ' char(q)]) 31 | disp(' '); 32 | -------------------------------------------------------------------------------- /robot/Octave/@Quaternion/dot.m: -------------------------------------------------------------------------------- 1 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 2 | % 3 | % Copyright (C) 1993-2011, by Peter I. Corke 4 | % 5 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 6 | % 7 | % RTB is free software: you can redistribute it and/or modify 8 | % it under the terms of the GNU Lesser General Public License as published by 9 | % the Free Software Foundation, either version 3 of the License, or 10 | % (at your option) any later version. 11 | % 12 | % RTB is distributed in the hope that it will be useful, 13 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | % GNU Lesser General Public License for more details. 16 | % 17 | % You should have received a copy of the GNU Leser General Public License 18 | % along with RTB. If not, see . 19 | % 20 | % http://www.petercorke.com 21 | function qd = dot(q, omega) 22 | E = q.s*eye(3,3) - skew(q.v); 23 | omega = omega(:); 24 | qd = Quaternion(-0.5*q.v*omega, 0.5*E*omega); 25 | end 26 | -------------------------------------------------------------------------------- /robot/Octave/@Quaternion/double.m: -------------------------------------------------------------------------------- 1 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 2 | % 3 | % Copyright (C) 1993-2011, by Peter I. Corke 4 | % 5 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 6 | % 7 | % RTB is free software: you can redistribute it and/or modify 8 | % it under the terms of the GNU Lesser General Public License as published by 9 | % the Free Software Foundation, either version 3 of the License, or 10 | % (at your option) any later version. 11 | % 12 | % RTB is distributed in the hope that it will be useful, 13 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | % GNU Lesser General Public License for more details. 16 | % 17 | % You should have received a copy of the GNU Leser General Public License 18 | % along with RTB. If not, see . 19 | % 20 | % http://www.petercorke.com 21 | function v = double(q) 22 | %Quaternion.double Convert a quaternion object to a 4-element vector 23 | % 24 | % V = Q.double() is a 4-vector comprising the quaternion 25 | % elements [s vx vy vz]. 26 | 27 | v = [q.s q.v]; 28 | endfunction 29 | 30 | -------------------------------------------------------------------------------- /robot/Octave/@Quaternion/inv.m: -------------------------------------------------------------------------------- 1 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 2 | % 3 | % Copyright (C) 1993-2011, by Peter I. Corke 4 | % 5 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 6 | % 7 | % RTB is free software: you can redistribute it and/or modify 8 | % it under the terms of the GNU Lesser General Public License as published by 9 | % the Free Software Foundation, either version 3 of the License, or 10 | % (at your option) any later version. 11 | % 12 | % RTB is distributed in the hope that it will be useful, 13 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | % GNU Lesser General Public License for more details. 16 | % 17 | % You should have received a copy of the GNU Leser General Public License 18 | % along with RTB. If not, see . 19 | % 20 | % http://www.petercorke.com 21 | function qi = inv(q) 22 | %Quaternion.inv Invert a unit-quaternion 23 | % 24 | % QI = Q.inv() is a quaternion object representing the inverse of Q. 25 | 26 | qi = Quaternion([q.s -q.v]); 27 | endfunction 28 | -------------------------------------------------------------------------------- /robot/Octave/@Quaternion/minus.m: -------------------------------------------------------------------------------- 1 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 2 | % 3 | % Copyright (C) 1993-2011, by Peter I. Corke 4 | % 5 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 6 | % 7 | % RTB is free software: you can redistribute it and/or modify 8 | % it under the terms of the GNU Lesser General Public License as published by 9 | % the Free Software Foundation, either version 3 of the License, or 10 | % (at your option) any later version. 11 | % 12 | % RTB is distributed in the hope that it will be useful, 13 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | % GNU Lesser General Public License for more details. 16 | % 17 | % You should have received a copy of the GNU Leser General Public License 18 | % along with RTB. If not, see . 19 | % 20 | % http://www.petercorke.com 21 | function qp = minus(q1, q2) 22 | %Quaternion.minus Subtract two quaternion objects 23 | % 24 | % Q1-Q2 is the element-wise difference of quaternion elements. 25 | 26 | if isa(q1, 'Quaternion') & isa(q2, 'Quaternion') 27 | 28 | qp = Quaternion(double(q1) - double(q2)); 29 | end 30 | end 31 | -------------------------------------------------------------------------------- /robot/Octave/@Quaternion/mpower.m: -------------------------------------------------------------------------------- 1 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 2 | % 3 | % Copyright (C) 1993-2011, by Peter I. Corke 4 | % 5 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 6 | % 7 | % RTB is free software: you can redistribute it and/or modify 8 | % it under the terms of the GNU Lesser General Public License as published by 9 | % the Free Software Foundation, either version 3 of the License, or 10 | % (at your option) any later version. 11 | % 12 | % RTB is distributed in the hope that it will be useful, 13 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | % GNU Lesser General Public License for more details. 16 | % 17 | % You should have received a copy of the GNU Leser General Public License 18 | % along with RTB. If not, see . 19 | % 20 | % http://www.petercorke.com 21 | function qp = mpower(q, p) 22 | %Quaternion.mpower Raise quaternion to integer power 23 | % 24 | % Q^N is quaternion Q raised to the integer power N, and computed by repeated multiplication. 25 | 26 | % check that exponent is an integer 27 | if (p - floor(p)) ~= 0 28 | error('quaternion exponent must be integer'); 29 | end 30 | 31 | qp = q; 32 | 33 | % multiply by itself so many times 34 | for i = 2:abs(p) 35 | qp = qp * q; 36 | end 37 | 38 | % if exponent was negative, invert it 39 | if p<0 40 | qp = inv(qp); 41 | end 42 | end 43 | -------------------------------------------------------------------------------- /robot/Octave/@Quaternion/mrdivide.m: -------------------------------------------------------------------------------- 1 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 2 | % 3 | % Copyright (C) 1993-2011, by Peter I. Corke 4 | % 5 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 6 | % 7 | % RTB is free software: you can redistribute it and/or modify 8 | % it under the terms of the GNU Lesser General Public License as published by 9 | % the Free Software Foundation, either version 3 of the License, or 10 | % (at your option) any later version. 11 | % 12 | % RTB is distributed in the hope that it will be useful, 13 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | % GNU Lesser General Public License for more details. 16 | % 17 | % You should have received a copy of the GNU Leser General Public License 18 | % along with RTB. If not, see . 19 | % 20 | % http://www.petercorke.com 21 | function qq = mrdivide(q1, q2) 22 | %Quaternion.mrdivide Compute quaternion quotient. 23 | % 24 | % Q1/Q2 is a quaternion formed by Hamilton product of Q1 and inv(Q2) 25 | % Q/S is the element-wise division of quaternion elements by by the scalar S 26 | 27 | if isa(q2, 'Quaternion') 28 | % qq = q1 / q2 29 | % = q1 * qinv(q2) 30 | 31 | qq = q1 * inv(q2); 32 | elseif isa(q2, 'double') 33 | qq = Quaternion( double(q1) / q2 ); 34 | end 35 | end 36 | -------------------------------------------------------------------------------- /robot/Octave/@Quaternion/norm.m: -------------------------------------------------------------------------------- 1 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 2 | % 3 | % Copyright (C) 1993-2011, by Peter I. Corke 4 | % 5 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 6 | % 7 | % RTB is free software: you can redistribute it and/or modify 8 | % it under the terms of the GNU Lesser General Public License as published by 9 | % the Free Software Foundation, either version 3 of the License, or 10 | % (at your option) any later version. 11 | % 12 | % RTB is distributed in the hope that it will be useful, 13 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | % GNU Lesser General Public License for more details. 16 | % 17 | % You should have received a copy of the GNU Leser General Public License 18 | % along with RTB. If not, see . 19 | % 20 | % http://www.petercorke.com 21 | function n = norm(q) 22 | %Quaternion.norm Compute the norm of a quaternion 23 | % 24 | % QN = Q.norm(Q) is the scalar norm or magnitude of the quaternion Q. 25 | 26 | n = norm(double(q)); 27 | end 28 | -------------------------------------------------------------------------------- /robot/Octave/@Quaternion/plus.m: -------------------------------------------------------------------------------- 1 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 2 | % 3 | % Copyright (C) 1993-2011, by Peter I. Corke 4 | % 5 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 6 | % 7 | % RTB is free software: you can redistribute it and/or modify 8 | % it under the terms of the GNU Lesser General Public License as published by 9 | % the Free Software Foundation, either version 3 of the License, or 10 | % (at your option) any later version. 11 | % 12 | % RTB is distributed in the hope that it will be useful, 13 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | % GNU Lesser General Public License for more details. 16 | % 17 | % You should have received a copy of the GNU Leser General Public License 18 | % along with RTB. If not, see . 19 | % 20 | % http://www.petercorke.com 21 | function qp = plus(q1, q2) 22 | %PLUS Add two quaternion objects 23 | % 24 | % Q1+Q2 is the element-wise sum of quaternion elements. 25 | 26 | if isa(q1, 'Quaternion') & isa(q2, 'Quaternion') 27 | 28 | qp = Quaternion(double(q1) + double(q2)); 29 | end 30 | end 31 | -------------------------------------------------------------------------------- /robot/Octave/@Quaternion/q2tr.m: -------------------------------------------------------------------------------- 1 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 2 | % 3 | % Copyright (C) 1993-2011, by Peter I. Corke 4 | % 5 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 6 | % 7 | % RTB is free software: you can redistribute it and/or modify 8 | % it under the terms of the GNU Lesser General Public License as published by 9 | % the Free Software Foundation, either version 3 of the License, or 10 | % (at your option) any later version. 11 | % 12 | % RTB is distributed in the hope that it will be useful, 13 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | % GNU Lesser General Public License for more details. 16 | % 17 | % You should have received a copy of the GNU Leser General Public License 18 | % along with RTB. If not, see . 19 | % 20 | % http://www.petercorke.com 21 | function t = q2tr(q) 22 | 23 | q = double(q); 24 | s = q(1); 25 | x = q(2); 26 | y = q(3); 27 | z = q(4); 28 | 29 | r = [ 1-2*(y^2+z^2) 2*(x*y-s*z) 2*(x*z+s*y) 30 | 2*(x*y+s*z) 1-2*(x^2+z^2) 2*(y*z-s*x) 31 | 2*(x*z-s*y) 2*(y*z+s*x) 1-2*(x^2+y^2) ]; 32 | t = eye(4,4); 33 | t(1:3,1:3) = r; 34 | t(4,4) = 1; 35 | endfunction 36 | -------------------------------------------------------------------------------- /robot/Octave/@Quaternion/unit.m: -------------------------------------------------------------------------------- 1 | 2 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 3 | % 4 | % Copyright (C) 1993-2011, by Peter I. Corke 5 | % 6 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 7 | % 8 | % RTB is free software: you can redistribute it and/or modify 9 | % it under the terms of the GNU Lesser General Public License as published by 10 | % the Free Software Foundation, either version 3 of the License, or 11 | % (at your option) any later version. 12 | % 13 | % RTB is distributed in the hope that it will be useful, 14 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | % GNU Lesser General Public License for more details. 17 | % 18 | % You should have received a copy of the GNU Leser General Public License 19 | % along with RTB. If not, see . 20 | % 21 | % http://www.petercorke.com 22 | function qu = unit(q) 23 | %Quaternion.unit Unitize a quaternion 24 | % 25 | % QU = Q.unit() is a quaternion which is a unitized version of Q 26 | 27 | qu = q / norm(q); 28 | end 29 | -------------------------------------------------------------------------------- /robot/Octave/@SerialLink/.svn/text-base/cinertia.m.svn-base: -------------------------------------------------------------------------------- 1 | %SerialLink.cinertia Cartesian inertia matrix 2 | % 3 | % M = R.cinertia(Q) is the NxN Cartesian (operational space) inertia matrix which relates 4 | % Cartesian force/torque to Cartesian acceleration at the joint configuration Q, and N 5 | % is the number of robot joints. 6 | % 7 | % See also SerialLink.inertia, SerialLink.rne. 8 | 9 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 10 | % 11 | % Copyright (C) 1993-2011, by Peter I. Corke 12 | % 13 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 14 | % 15 | % RTB is free software: you can redistribute it and/or modify 16 | % it under the terms of the GNU Lesser General Public License as published by 17 | % the Free Software Foundation, either version 3 of the License, or 18 | % (at your option) any later version. 19 | % 20 | % RTB is distributed in the hope that it will be useful, 21 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 22 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 23 | % GNU Lesser General Public License for more details. 24 | % 25 | % You should have received a copy of the GNU Leser General Public License 26 | % along with RTB. If not, see . 27 | % 28 | % http://www.petercorke.com 29 | 30 | function Mx = cinertia(robot, q) 31 | J = jacob0(robot, q); 32 | Ji = inv(J); 33 | M = inertia(robot, q); 34 | Mx = Ji' * M * Ji; 35 | -------------------------------------------------------------------------------- /robot/Octave/@SerialLink/.svn/text-base/display.m.svn-base: -------------------------------------------------------------------------------- 1 | function display(r) 2 | % called to display a robot object 3 | 4 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 5 | % 6 | % Copyright (C) 1993-2011, by Peter I. Corke 7 | % 8 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 9 | % 10 | % RTB is free software: you can redistribute it and/or modify 11 | % it under the terms of the GNU Lesser General Public License as published by 12 | % the Free Software Foundation, either version 3 of the License, or 13 | % (at your option) any later version. 14 | % 15 | % RTB is distributed in the hope that it will be useful, 16 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 17 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18 | % GNU Lesser General Public License for more details. 19 | % 20 | % You should have received a copy of the GNU Leser General Public License 21 | % along with RTB. If not, see . 22 | % 23 | % http://www.petercorke.com 24 | 25 | disp(' '); 26 | disp([inputname(1), ' = ']) 27 | disp(' '); 28 | disp(char(r)) 29 | disp(' '); 30 | -------------------------------------------------------------------------------- /robot/Octave/@SerialLink/.svn/text-base/dyn.m.svn-base: -------------------------------------------------------------------------------- 1 | 2 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 3 | % 4 | % Copyright (C) 1993-2011, by Peter I. Corke 5 | % 6 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 7 | % 8 | % RTB is free software: you can redistribute it and/or modify 9 | % it under the terms of the GNU Lesser General Public License as published by 10 | % the Free Software Foundation, either version 3 of the License, or 11 | % (at your option) any later version. 12 | % 13 | % RTB is distributed in the hope that it will be useful, 14 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | % GNU Lesser General Public License for more details. 17 | % 18 | % You should have received a copy of the GNU Leser General Public License 19 | % along with RTB. If not, see . 20 | % 21 | % http://www.petercorke.com 22 | function dyn(r) 23 | %SerialLink.dyn Display inertial properties 24 | % 25 | % R.dyn() displays the inertial properties of the SerialLink object in a multi-line 26 | % format. The properties shown are mass, centre of mass, inertia, gear ratio, 27 | % motor inertia and motor friction. 28 | % 29 | % See also Link.dyn. 30 | for j=1:r.n 31 | fprintf('----- link %d\n', j); 32 | l = r.links(j); 33 | l.dyn() 34 | end 35 | end 36 | -------------------------------------------------------------------------------- /robot/Octave/@SerialLink/.svn/text-base/friction.m.svn-base: -------------------------------------------------------------------------------- 1 | %SerialLink.friction Friction force 2 | % 3 | % TAU = R.friction(QD) is the vector of joint friction forces/torques for the 4 | % robot moving with joint velocities QD. 5 | % 6 | % The friction model includes viscous friction (linear with velocity) 7 | % and Coulomb friction (proportional to sign(QD)). 8 | % 9 | % See also Link.friction. 10 | 11 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 12 | % 13 | % Copyright (C) 1993-2011, by Peter I. Corke 14 | % 15 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 16 | % 17 | % RTB is free software: you can redistribute it and/or modify 18 | % it under the terms of the GNU Lesser General Public License as published by 19 | % the Free Software Foundation, either version 3 of the License, or 20 | % (at your option) any later version. 21 | % 22 | % RTB is distributed in the hope that it will be useful, 23 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 24 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 25 | % GNU Lesser General Public License for more details. 26 | % 27 | % You should have received a copy of the GNU Leser General Public License 28 | % along with RTB. If not, see . 29 | % 30 | % http://www.petercorke.com 31 | 32 | function tau = friction(robot, qd) 33 | 34 | L = robot.links; 35 | 36 | for i=1:robot.n, 37 | tau(i) = friction(L(i), qd(i)); 38 | end 39 | 40 | -------------------------------------------------------------------------------- /robot/Octave/@SerialLink/.svn/text-base/islimit.m.svn-base: -------------------------------------------------------------------------------- 1 | 2 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 3 | % 4 | % Copyright (C) 1993-2011, by Peter I. Corke 5 | % 6 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 7 | % 8 | % RTB is free software: you can redistribute it and/or modify 9 | % it under the terms of the GNU Lesser General Public License as published by 10 | % the Free Software Foundation, either version 3 of the License, or 11 | % (at your option) any later version. 12 | % 13 | % RTB is distributed in the hope that it will be useful, 14 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | % GNU Lesser General Public License for more details. 17 | % 18 | % You should have received a copy of the GNU Leser General Public License 19 | % along with RTB. If not, see . 20 | % 21 | % http://www.petercorke.com 22 | function v = islimit(r,q) 23 | %SerialLink.islimit Joint limit test 24 | % 25 | % V = R.ISLIMIT(Q) is a vector of boolean values, one per joint, 26 | % false (0) if Q(i) is within the joint limits, else true (1). 27 | L = r.links; 28 | if length(q) ~= r.n 29 | error('argument for islimit method is wrong length'); 30 | end 31 | v = []; 32 | for i=1:r.n 33 | v = [v; r.links(i).islimit(q(i))]; 34 | end 35 | end 36 | -------------------------------------------------------------------------------- /robot/Octave/@SerialLink/.svn/text-base/isspherical.m.svn-base: -------------------------------------------------------------------------------- 1 | 2 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 3 | % 4 | % Copyright (C) 1993-2011, by Peter I. Corke 5 | % 6 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 7 | % 8 | % RTB is free software: you can redistribute it and/or modify 9 | % it under the terms of the GNU Lesser General Public License as published by 10 | % the Free Software Foundation, either version 3 of the License, or 11 | % (at your option) any later version. 12 | % 13 | % RTB is distributed in the hope that it will be useful, 14 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | % GNU Lesser General Public License for more details. 17 | % 18 | % You should have received a copy of the GNU Leser General Public License 19 | % along with RTB. If not, see . 20 | % 21 | % http://www.petercorke.com 22 | function v = isspherical(r) 23 | %SerialLink.isspherical Test for spherical wrist 24 | % 25 | % R.isspherical() is true if the robot has a spherical wrist, that is, the 26 | % last 3 axes intersect at a point. 27 | % 28 | % See also SerialLink.ikine6s. 29 | L = r.links(end-2:end); 30 | 31 | v = false; 32 | if ~isempty( find( [L(1).a L(2).a L(3).a L(2).d L(3).d] ~= 0 )) 33 | return 34 | end 35 | 36 | if (abs(L(1).alpha) == pi/2) & (abs(L(1).alpha + L(2).alpha) < eps) 37 | v = true; 38 | return; 39 | end 40 | end 41 | 42 | -------------------------------------------------------------------------------- /robot/Octave/@SerialLink/.svn/text-base/showlink.m.svn-base: -------------------------------------------------------------------------------- 1 | %SerialLink.showlink Show parameters of all links 2 | % 3 | % R.showlink() shows details of all link parameters for the robot object, 4 | % including inertial parameters. 5 | % 6 | % See also Link.showlink, Link. 7 | 8 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 9 | % 10 | % Copyright (C) 1993-2011, by Peter I. Corke 11 | % 12 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 13 | % 14 | % RTB is free software: you can redistribute it and/or modify 15 | % it under the terms of the GNU Lesser General Public License as published by 16 | % the Free Software Foundation, either version 3 of the License, or 17 | % (at your option) any later version. 18 | % 19 | % RTB is distributed in the hope that it will be useful, 20 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 21 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 22 | % GNU Lesser General Public License for more details. 23 | % 24 | % You should have received a copy of the GNU Leser General Public License 25 | % along with RTB. If not, see . 26 | % 27 | % http://www.petercorke.com 28 | 29 | function showlink(r) 30 | 31 | for i=1:r.n, 32 | fprintf('Link %d------------------------\n', i); 33 | r.links(i).dyn(); 34 | end 35 | -------------------------------------------------------------------------------- /robot/Octave/@SerialLink/cinertia.m: -------------------------------------------------------------------------------- 1 | %SerialLink.cinertia Cartesian inertia matrix 2 | % 3 | % M = R.cinertia(Q) is the NxN Cartesian (operational space) inertia matrix which relates 4 | % Cartesian force/torque to Cartesian acceleration at the joint configuration Q, and N 5 | % is the number of robot joints. 6 | % 7 | % See also SerialLink.inertia, SerialLink.rne. 8 | 9 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 10 | % 11 | % Copyright (C) 1993-2011, by Peter I. Corke 12 | % 13 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 14 | % 15 | % RTB is free software: you can redistribute it and/or modify 16 | % it under the terms of the GNU Lesser General Public License as published by 17 | % the Free Software Foundation, either version 3 of the License, or 18 | % (at your option) any later version. 19 | % 20 | % RTB is distributed in the hope that it will be useful, 21 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 22 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 23 | % GNU Lesser General Public License for more details. 24 | % 25 | % You should have received a copy of the GNU Leser General Public License 26 | % along with RTB. If not, see . 27 | % 28 | % http://www.petercorke.com 29 | 30 | function Mx = cinertia(robot, q) 31 | J = jacob0(robot, q); 32 | Ji = inv(J); 33 | M = inertia(robot, q); 34 | Mx = Ji' * M * Ji; 35 | -------------------------------------------------------------------------------- /robot/Octave/@SerialLink/display.m: -------------------------------------------------------------------------------- 1 | function display(r) 2 | % called to display a robot object 3 | 4 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 5 | % 6 | % Copyright (C) 1993-2011, by Peter I. Corke 7 | % 8 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 9 | % 10 | % RTB is free software: you can redistribute it and/or modify 11 | % it under the terms of the GNU Lesser General Public License as published by 12 | % the Free Software Foundation, either version 3 of the License, or 13 | % (at your option) any later version. 14 | % 15 | % RTB is distributed in the hope that it will be useful, 16 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 17 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18 | % GNU Lesser General Public License for more details. 19 | % 20 | % You should have received a copy of the GNU Leser General Public License 21 | % along with RTB. If not, see . 22 | % 23 | % http://www.petercorke.com 24 | 25 | disp(' '); 26 | disp([inputname(1), ' = ']) 27 | disp(' '); 28 | disp(char(r)) 29 | disp(' '); 30 | -------------------------------------------------------------------------------- /robot/Octave/@SerialLink/dyn.m: -------------------------------------------------------------------------------- 1 | 2 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 3 | % 4 | % Copyright (C) 1993-2011, by Peter I. Corke 5 | % 6 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 7 | % 8 | % RTB is free software: you can redistribute it and/or modify 9 | % it under the terms of the GNU Lesser General Public License as published by 10 | % the Free Software Foundation, either version 3 of the License, or 11 | % (at your option) any later version. 12 | % 13 | % RTB is distributed in the hope that it will be useful, 14 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | % GNU Lesser General Public License for more details. 17 | % 18 | % You should have received a copy of the GNU Leser General Public License 19 | % along with RTB. If not, see . 20 | % 21 | % http://www.petercorke.com 22 | function dyn(r) 23 | %SerialLink.dyn Display inertial properties 24 | % 25 | % R.dyn() displays the inertial properties of the SerialLink object in a multi-line 26 | % format. The properties shown are mass, centre of mass, inertia, gear ratio, 27 | % motor inertia and motor friction. 28 | % 29 | % See also Link.dyn. 30 | for j=1:r.n 31 | fprintf('----- link %d\n', j); 32 | l = r.links(j); 33 | l.dyn() 34 | end 35 | end 36 | -------------------------------------------------------------------------------- /robot/Octave/@SerialLink/friction.m: -------------------------------------------------------------------------------- 1 | %SerialLink.friction Friction force 2 | % 3 | % TAU = R.friction(QD) is the vector of joint friction forces/torques for the 4 | % robot moving with joint velocities QD. 5 | % 6 | % The friction model includes viscous friction (linear with velocity) 7 | % and Coulomb friction (proportional to sign(QD)). 8 | % 9 | % See also Link.friction. 10 | 11 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 12 | % 13 | % Copyright (C) 1993-2011, by Peter I. Corke 14 | % 15 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 16 | % 17 | % RTB is free software: you can redistribute it and/or modify 18 | % it under the terms of the GNU Lesser General Public License as published by 19 | % the Free Software Foundation, either version 3 of the License, or 20 | % (at your option) any later version. 21 | % 22 | % RTB is distributed in the hope that it will be useful, 23 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 24 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 25 | % GNU Lesser General Public License for more details. 26 | % 27 | % You should have received a copy of the GNU Leser General Public License 28 | % along with RTB. If not, see . 29 | % 30 | % http://www.petercorke.com 31 | 32 | function tau = friction(robot, qd) 33 | 34 | L = robot.links; 35 | 36 | for i=1:robot.n, 37 | tau(i) = friction(L(i), qd(i)); 38 | end 39 | 40 | -------------------------------------------------------------------------------- /robot/Octave/@SerialLink/islimit.m: -------------------------------------------------------------------------------- 1 | 2 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 3 | % 4 | % Copyright (C) 1993-2011, by Peter I. Corke 5 | % 6 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 7 | % 8 | % RTB is free software: you can redistribute it and/or modify 9 | % it under the terms of the GNU Lesser General Public License as published by 10 | % the Free Software Foundation, either version 3 of the License, or 11 | % (at your option) any later version. 12 | % 13 | % RTB is distributed in the hope that it will be useful, 14 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | % GNU Lesser General Public License for more details. 17 | % 18 | % You should have received a copy of the GNU Leser General Public License 19 | % along with RTB. If not, see . 20 | % 21 | % http://www.petercorke.com 22 | function v = islimit(r,q) 23 | %SerialLink.islimit Joint limit test 24 | % 25 | % V = R.ISLIMIT(Q) is a vector of boolean values, one per joint, 26 | % false (0) if Q(i) is within the joint limits, else true (1). 27 | L = r.links; 28 | if length(q) ~= r.n 29 | error('argument for islimit method is wrong length'); 30 | end 31 | v = []; 32 | for i=1:r.n 33 | v = [v; r.links(i).islimit(q(i))]; 34 | end 35 | end 36 | -------------------------------------------------------------------------------- /robot/Octave/@SerialLink/isspherical.m: -------------------------------------------------------------------------------- 1 | 2 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 3 | % 4 | % Copyright (C) 1993-2011, by Peter I. Corke 5 | % 6 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 7 | % 8 | % RTB is free software: you can redistribute it and/or modify 9 | % it under the terms of the GNU Lesser General Public License as published by 10 | % the Free Software Foundation, either version 3 of the License, or 11 | % (at your option) any later version. 12 | % 13 | % RTB is distributed in the hope that it will be useful, 14 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | % GNU Lesser General Public License for more details. 17 | % 18 | % You should have received a copy of the GNU Leser General Public License 19 | % along with RTB. If not, see . 20 | % 21 | % http://www.petercorke.com 22 | function v = isspherical(r) 23 | %SerialLink.isspherical Test for spherical wrist 24 | % 25 | % R.isspherical() is true if the robot has a spherical wrist, that is, the 26 | % last 3 axes intersect at a point. 27 | % 28 | % See also SerialLink.ikine6s. 29 | L = r.links(end-2:end); 30 | 31 | v = false; 32 | if ~isempty( find( [L(1).a L(2).a L(3).a L(2).d L(3).d] ~= 0 )) 33 | return 34 | end 35 | 36 | if (abs(L(1).alpha) == pi/2) & (abs(L(1).alpha + L(2).alpha) < eps) 37 | v = true; 38 | return; 39 | end 40 | end 41 | 42 | -------------------------------------------------------------------------------- /robot/Octave/@SerialLink/showlink.m: -------------------------------------------------------------------------------- 1 | %SerialLink.showlink Show parameters of all links 2 | % 3 | % R.showlink() shows details of all link parameters for the robot object, 4 | % including inertial parameters. 5 | % 6 | % See also Link.showlink, Link. 7 | 8 | % Ryan Steindl based on Robotics Toolbox for MATLAB (v6 and v9) 9 | % 10 | % Copyright (C) 1993-2011, by Peter I. Corke 11 | % 12 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 13 | % 14 | % RTB is free software: you can redistribute it and/or modify 15 | % it under the terms of the GNU Lesser General Public License as published by 16 | % the Free Software Foundation, either version 3 of the License, or 17 | % (at your option) any later version. 18 | % 19 | % RTB is distributed in the hope that it will be useful, 20 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 21 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 22 | % GNU Lesser General Public License for more details. 23 | % 24 | % You should have received a copy of the GNU Leser General Public License 25 | % along with RTB. If not, see . 26 | % 27 | % http://www.petercorke.com 28 | 29 | function showlink(r) 30 | 31 | for i=1:r.n, 32 | fprintf('Link %d------------------------\n', i); 33 | r.links(i).dyn(); 34 | end 35 | -------------------------------------------------------------------------------- /robot/README: -------------------------------------------------------------------------------- 1 | Installation: 2 | ------------ 3 | 4 | simply copy all the .m files into a directory 'robot' 5 | 6 | add the directory robot to your MATLABPATH 7 | 8 | start MATLAB 9 | 10 | >> startup_rvc 11 | 12 | Help: 13 | ---- 14 | 15 | 1: manual 16 | 17 | robot.pdf is the documentation in standard Mathworks style. It is 18 | formatted for double sided printing which makes for a more compact 19 | manual and saves trees. 20 | 21 | 2: desktop help GUI 22 | from the Matlab desktop, choose help, and select the Robotics Toolbox 23 | option. HTML format documentation for all functions is available. 24 | 25 | 3: command line 26 | use the help command from the command prompt, eg. help ikine 27 | 28 | 4: the web 29 | 30 | http://www.petercorke.com/RTB/r9/html 31 | 32 | 33 | Demos: 34 | ----- 35 | 36 | 1: invoke the demo GUI 37 | from the command prompt, >> demos, then select the Robotics Toolbox 38 | 39 | 2: desktop menu bar 40 | from the menu bar choose demos, and select the Robotics Toolbox 41 | 42 | 3: command prompt 43 | >> rtdemos 44 | 45 | 46 | Online resources: 47 | ---------------- 48 | 49 | Home page: http://www.petercorke.com 50 | Discussion group: http://groups.google.com/group/robotics-tool-box?hl=en 51 | Manual pages: http://www.petercorke.com/RTB/r9/html 52 | 53 | Please email bug reports, comments or code contribtions to me at rvc@petercorke.com 54 | 55 | Peter Corke 56 | -------------------------------------------------------------------------------- /robot/RELEASE: -------------------------------------------------------------------------------- 1 | 9.8 2 | -------------------------------------------------------------------------------- /robot/angvec2tr.m: -------------------------------------------------------------------------------- 1 | %ANGVEC2TR Convert angle and vector orientation to a homogeneous transform 2 | % 3 | % T = ANGVEC2TR(THETA, V) is a homogeneous transform matrix equivalent to a 4 | % rotation of THETA about the vector V. 5 | % 6 | % Note:: 7 | % - The translational part is zero. 8 | % 9 | % See also EUL2TR, RPY2TR, ANGVEC2R. 10 | 11 | 12 | % Copyright (C) 1993-2011, by Peter I. Corke 13 | % 14 | % This file is part of The Robotics Toolbox for Matlab (RTB). 15 | % 16 | % RTB is free software: you can redistribute it and/or modify 17 | % it under the terms of the GNU Lesser General Public License as published by 18 | % the Free Software Foundation, either version 3 of the License, or 19 | % (at your option) any later version. 20 | % 21 | % RTB is distributed in the hope that it will be useful, 22 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 23 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 24 | % GNU Lesser General Public License for more details. 25 | % 26 | % You should have received a copy of the GNU Leser General Public License 27 | % along with RTB. If not, see . 28 | 29 | function T = angvec2tr(theta, k) 30 | 31 | if nargin < 2 32 | error('RTB:angvec2tr:badarg', 'bad arguments'); 33 | end 34 | 35 | 36 | T = r2t( angvec2r(theta, k) ); 37 | -------------------------------------------------------------------------------- /robot/delta2tr.m: -------------------------------------------------------------------------------- 1 | %DELTA2TR Convert differential motion to a homogeneous transform 2 | % 3 | % T = DELTA2TR(D) is a homogeneous transform representing differential 4 | % translation and rotation. The vector D=(dx, dy, dz, dRx, dRy, dRz) 5 | % represents an infinitessimal motion, and is an approximation to the spatial 6 | % velocity multiplied by time. 7 | % 8 | % See also TR2DELTA. 9 | 10 | 11 | % Copyright (C) 1993-2011, by Peter I. Corke 12 | % 13 | % This file is part of The Robotics Toolbox for Matlab (RTB). 14 | % 15 | % RTB is free software: you can redistribute it and/or modify 16 | % it under the terms of the GNU Lesser General Public License as published by 17 | % the Free Software Foundation, either version 3 of the License, or 18 | % (at your option) any later version. 19 | % 20 | % RTB is distributed in the hope that it will be useful, 21 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 22 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 23 | % GNU Lesser General Public License for more details. 24 | % 25 | % You should have received a copy of the GNU Leser General Public License 26 | % along with RTB. If not, see . 27 | 28 | function delta = delta2tr(d) 29 | d = d(:); 30 | delta = eye(4,4) + [skew(d(4:6)) d(1:3); 0 0 0 0]; 31 | -------------------------------------------------------------------------------- /robot/demos/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/demos/.DS_Store -------------------------------------------------------------------------------- /robot/demos/.svn/text-base/braitnav.m.svn-base: -------------------------------------------------------------------------------- 1 | % Copyright (C) 1993-2013, by Peter I. Corke 2 | % 3 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 4 | % 5 | % RTB is free software: you can redistribute it and/or modify 6 | % it under the terms of the GNU Lesser General Public License as published by 7 | % the Free Software Foundation, either version 3 of the License, or 8 | % (at your option) any later version. 9 | % 10 | % RTB is distributed in the hope that it will be useful, 11 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | % GNU Lesser General Public License for more details. 14 | % 15 | % You should have received a copy of the GNU Leser General Public License 16 | % along with RTB. If not, see . 17 | % 18 | % http://www.petercorke.com 19 | 20 | 21 | %%begin 22 | % A Braitenberg vehicle is a simple reactive machine, that is, it exhibits useful 23 | % behaviours based on how its sensors are connected to its actuators. 24 | 25 | sl_braitenberg 26 | 27 | % In this example the robot moves to the maximum of some scalar field which is 28 | % measured by two separate sensors on the robot. The sensors are simulated by 29 | %the code 30 | 31 | type sensorfield 32 | 33 | % We will run the simulator and see that it moves toward the maxima 34 | sim('sl_braitenberg'); 35 | -------------------------------------------------------------------------------- /robot/demos/.svn/text-base/quadrotor.m.svn-base: -------------------------------------------------------------------------------- 1 | % Copyright (C) 1993-2013, by Peter I. Corke 2 | % 3 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 4 | % 5 | % RTB is free software: you can redistribute it and/or modify 6 | % it under the terms of the GNU Lesser General Public License as published by 7 | % the Free Software Foundation, either version 3 of the License, or 8 | % (at your option) any later version. 9 | % 10 | % RTB is distributed in the hope that it will be useful, 11 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | % GNU Lesser General Public License for more details. 14 | % 15 | % You should have received a copy of the GNU Leser General Public License 16 | % along with RTB. If not, see . 17 | % 18 | % http://www.petercorke.com 19 | 20 | %%begin 21 | 22 | % A quadrotor is a simple flying vehicle with 4 propellers with their thrust 23 | % axes pointing upwards. This demo shows an animation of a flying quadrotor 24 | % with a nested control system. 25 | 26 | sl_quadrotor 27 | 28 | % Running the simulation shows the vehicle takes off and flying in a cirle. 29 | sim('sl_quadrotor'); 30 | -------------------------------------------------------------------------------- /robot/demos/.svn/text-base/ztorque.m.svn-base: -------------------------------------------------------------------------------- 1 | % Copyright (C) 1993-2013, by Peter I. Corke 2 | % 3 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 4 | % 5 | % RTB is free software: you can redistribute it and/or modify 6 | % it under the terms of the GNU Lesser General Public License as published by 7 | % the Free Software Foundation, either version 3 of the License, or 8 | % (at your option) any later version. 9 | % 10 | % RTB is distributed in the hope that it will be useful, 11 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | % GNU Lesser General Public License for more details. 14 | % 15 | % You should have received a copy of the GNU Leser General Public License 16 | % along with RTB. If not, see . 17 | % 18 | % http://www.petercorke.com 19 | 20 | %%begin 21 | 22 | % We will work with a model of the Puma 560 robot 23 | mdl_puma560 24 | 25 | % to make the numerical simulation work faster we will remove the non-linear 26 | % Coloumb friction that exists in the model 27 | 28 | p560 = p560.nofriction() 29 | 30 | % A simple Simulink model that connects a robot dynamics block 31 | % to a robot plot block 32 | 33 | sl_ztorque 34 | 35 | % The robot has zero applied torque at each joint, so when we run the simulation it 36 | % will collapse under its own weight 37 | 38 | sim('sl_ztorque') 39 | -------------------------------------------------------------------------------- /robot/demos/.ztorque.m.swp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/demos/.ztorque.m.swp -------------------------------------------------------------------------------- /robot/demos/README: -------------------------------------------------------------------------------- 1 | Robotics Toolbox demo scripts 2 | 3 | Some examples of how to use toolbox functions to perform a variety of 4 | useful/interesting tasks. 5 | 6 | Note that the scripts are not added to your MATLAB path. 7 | 8 | You can run these scripts by: 9 | 10 | - use the rtbdemo function to invoke the scripts via runscript 11 | - cd to the demos folder and run them from the command line 12 | - use addpath to add the demos folder to your MATLAB path 13 | -------------------------------------------------------------------------------- /robot/demos/TODO: -------------------------------------------------------------------------------- 1 | manipulability, velocity/acceleration ellipsoids 2 | overactuated robot 3 | resolved rate control (is this in Jacobian demo?) 4 | 5 | IMU 6 | -------------------------------------------------------------------------------- /robot/demos/braitnav.m: -------------------------------------------------------------------------------- 1 | % Copyright (C) 1993-2013, by Peter I. Corke 2 | % 3 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 4 | % 5 | % RTB is free software: you can redistribute it and/or modify 6 | % it under the terms of the GNU Lesser General Public License as published by 7 | % the Free Software Foundation, either version 3 of the License, or 8 | % (at your option) any later version. 9 | % 10 | % RTB is distributed in the hope that it will be useful, 11 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | % GNU Lesser General Public License for more details. 14 | % 15 | % You should have received a copy of the GNU Leser General Public License 16 | % along with RTB. If not, see . 17 | % 18 | % http://www.petercorke.com 19 | 20 | 21 | %%begin 22 | % A Braitenberg vehicle is a simple reactive machine, that is, it exhibits useful 23 | % behaviours based on how its sensors are connected to its actuators. 24 | 25 | sl_braitenberg 26 | 27 | % In this example the robot moves to the maximum of some scalar field which is 28 | % measured by two separate sensors on the robot. The sensors are simulated by 29 | %the code 30 | 31 | type sensorfield 32 | 33 | % We will run the simulator and see that it moves toward the maxima 34 | sim('sl_braitenberg'); 35 | -------------------------------------------------------------------------------- /robot/demos/quadrotor.m: -------------------------------------------------------------------------------- 1 | % Copyright (C) 1993-2013, by Peter I. Corke 2 | % 3 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 4 | % 5 | % RTB is free software: you can redistribute it and/or modify 6 | % it under the terms of the GNU Lesser General Public License as published by 7 | % the Free Software Foundation, either version 3 of the License, or 8 | % (at your option) any later version. 9 | % 10 | % RTB is distributed in the hope that it will be useful, 11 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | % GNU Lesser General Public License for more details. 14 | % 15 | % You should have received a copy of the GNU Leser General Public License 16 | % along with RTB. If not, see . 17 | % 18 | % http://www.petercorke.com 19 | 20 | %%begin 21 | 22 | % A quadrotor is a simple flying vehicle with 4 propellers with their thrust 23 | % axes pointing upwards. This demo shows an animation of a flying quadrotor 24 | % with a nested control system. 25 | 26 | sl_quadrotor 27 | 28 | % Running the simulation shows the vehicle takes off and flying in a cirle. 29 | sim('sl_quadrotor'); 30 | -------------------------------------------------------------------------------- /robot/demos/ztorque.m: -------------------------------------------------------------------------------- 1 | % Copyright (C) 1993-2013, by Peter I. Corke 2 | % 3 | % This file is part of The Robotics Toolbox for MATLAB (RTB). 4 | % 5 | % RTB is free software: you can redistribute it and/or modify 6 | % it under the terms of the GNU Lesser General Public License as published by 7 | % the Free Software Foundation, either version 3 of the License, or 8 | % (at your option) any later version. 9 | % 10 | % RTB is distributed in the hope that it will be useful, 11 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | % GNU Lesser General Public License for more details. 14 | % 15 | % You should have received a copy of the GNU Leser General Public License 16 | % along with RTB. If not, see . 17 | % 18 | % http://www.petercorke.com 19 | 20 | %%begin 21 | 22 | % We will work with a model of the Puma 560 robot 23 | mdl_puma560 24 | 25 | % to make the numerical simulation work faster we will remove the non-linear 26 | % Coloumb friction that exists in the model 27 | 28 | p560 = p560.nofriction() 29 | 30 | % A simple Simulink model that connects a robot dynamics block 31 | % to a robot plot block 32 | 33 | sl_ztorque 34 | 35 | % The robot has zero applied torque at each joint, so when we run the simulation it 36 | % will collapse under its own weight 37 | 38 | sim('sl_ztorque') 39 | -------------------------------------------------------------------------------- /robot/examples/.svn/prop-base/map1.mat.svn-base: -------------------------------------------------------------------------------- 1 | K 13 2 | svn:mime-type 3 | V 24 4 | application/octet-stream 5 | END 6 | -------------------------------------------------------------------------------- /robot/examples/.svn/text-base/eg_grav.m.svn-base: -------------------------------------------------------------------------------- 1 | [Q2,Q3] = meshgrid(-pi:0.1:pi, -pi:0.1:pi); 2 | for i=1:numcols(Q2), 3 | for j=1:numcols(Q3); 4 | g = p560.gravload([0 Q2(i,j) Q3(i,j) 0 0 0]); 5 | g2(i,j) = g(2); 6 | g3(i,j) = g(3); 7 | end 8 | end 9 | surfl(Q2, Q3, g2); surfl(Q2, Q3, g3); 10 | -------------------------------------------------------------------------------- /robot/examples/.svn/text-base/eg_inertia.m.svn-base: -------------------------------------------------------------------------------- 1 | [Q2,Q3] = meshgrid(-pi:0.1:pi, -pi:0.1:pi); 2 | for i=1:numcols(Q2), 3 | for j=1:numcols(Q3); 4 | M = p560.inertia([0 Q2(i,j) Q3(i,j) 0 0 0]); 5 | M11(i,j) = M(1,1); 6 | M12(i,j) = M(1,2); 7 | end 8 | end 9 | surfl(Q2, Q3, M11); surfl(Q2, Q3, M12); 10 | -------------------------------------------------------------------------------- /robot/examples/.svn/text-base/eg_inertia22.m.svn-base: -------------------------------------------------------------------------------- 1 | Q3 = -pi:0.1:pi; 2 | for j=1:numcols(Q3); 3 | M = p560.inertia([0 0 Q3(j) 0 0 0]); 4 | M22(j) = M(2,2); 5 | end 6 | plot(Q3, M22) 7 | xlabel('q_3 (rad)'); 8 | ylabel('M_{22}'); 9 | -------------------------------------------------------------------------------- /robot/examples/.svn/text-base/gait.m.svn-base: -------------------------------------------------------------------------------- 1 | function q = gait(cycle, k, offset, flip) 2 | k = mod(k+offset-1, numrows(cycle)) + 1; 3 | q = cycle(k,:); 4 | if flip 5 | q(1) = -q(1); % for left-side legs 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /robot/examples/.svn/text-base/map1.mat.svn-base: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/examples/.svn/text-base/map1.mat.svn-base -------------------------------------------------------------------------------- /robot/examples/.svn/text-base/moveline.m.svn-base: -------------------------------------------------------------------------------- 1 | % target loine 2 | L = [1 -2 4]; 3 | clf 4 | axis([0 10 0 10]); 5 | hold on 6 | xyzlabel 7 | x = [0 10]; 8 | y = -(L(1)*x+L(3))/L(2); 9 | plot(x, y, 'k--'); 10 | grid on 11 | 12 | xc = 5; yc = 5; 13 | N = 4; 14 | radius = 3; 15 | 16 | for i=1:N 17 | th = (i-1)*2*pi/N; 18 | x0 = [xc+radius*cos(th) yc+radius*sin(th) th+pi/2]; 19 | 20 | plot_vehicle(x0, 'r'); 21 | r = sim('sl_driveline'); 22 | y = r.find('yout'); 23 | plot(y(:,1), y(:,2)); 24 | end 25 | -------------------------------------------------------------------------------- /robot/examples/.svn/text-base/movepoint.m.svn-base: -------------------------------------------------------------------------------- 1 | xg = [5 5]; % goal position 2 | clf 3 | axis([0 10 0 10]); 4 | hold on 5 | xyzlabel 6 | grid on 7 | xc = 5; yc = 5; 8 | N = 8; 9 | radius = 3; 10 | 11 | for i=1:N 12 | th = (i-1)*2*pi/N; 13 | x0 = [xc+radius*cos(th) yc+radius*sin(th) th+pi/2]; 14 | 15 | plot_vehicle(x0, 'r'); 16 | r = sim('sl_drivepoint'); 17 | y = r.find('yout'); 18 | plot(y(:,1), y(:,2)); 19 | end 20 | plot(xg(1), xg(2), '*') 21 | -------------------------------------------------------------------------------- /robot/examples/.svn/text-base/movepose.m.svn-base: -------------------------------------------------------------------------------- 1 | xg = [5 5 pi/2]; 2 | clf 3 | axis([0 10 0 10]); 4 | hold on 5 | xyzlabel 6 | grid on 7 | xc = 5; yc = 5; 8 | N = 8; 9 | radius = 4; 10 | 11 | for i=1:N 12 | th = (i-1)*2*pi/N; 13 | x0 = [xc+radius*cos(th) yc+radius*sin(th) 0]; 14 | 15 | plot_vehicle(x0, 'r'); 16 | r = sim('sl_drivepose'); 17 | y = r.find('yout'); 18 | plot(y(:,1), y(:,2)); 19 | end 20 | plot_vehicle(xg, 'r'); 21 | -------------------------------------------------------------------------------- /robot/examples/.svn/text-base/sensorfield.m.svn-base: -------------------------------------------------------------------------------- 1 | function sensor = sensorfield(x, y) 2 | 3 | xc = 60; yc = 90; 4 | 5 | sensor = 200 ./ ((x-xc).^2 + (y-yc).^2 + 200); 6 | -------------------------------------------------------------------------------- /robot/examples/eg_grav.m: -------------------------------------------------------------------------------- 1 | [Q2,Q3] = meshgrid(-pi:0.1:pi, -pi:0.1:pi); 2 | for i=1:numcols(Q2), 3 | for j=1:numcols(Q3); 4 | g = p560.gravload([0 Q2(i,j) Q3(i,j) 0 0 0]); 5 | g2(i,j) = g(2); 6 | g3(i,j) = g(3); 7 | end 8 | end 9 | surfl(Q2, Q3, g2); surfl(Q2, Q3, g3); 10 | -------------------------------------------------------------------------------- /robot/examples/eg_inertia.m: -------------------------------------------------------------------------------- 1 | [Q2,Q3] = meshgrid(-pi:0.1:pi, -pi:0.1:pi); 2 | for i=1:numcols(Q2), 3 | for j=1:numcols(Q3); 4 | M = p560.inertia([0 Q2(i,j) Q3(i,j) 0 0 0]); 5 | M11(i,j) = M(1,1); 6 | M12(i,j) = M(1,2); 7 | end 8 | end 9 | surfl(Q2, Q3, M11); surfl(Q2, Q3, M12); 10 | -------------------------------------------------------------------------------- /robot/examples/eg_inertia22.m: -------------------------------------------------------------------------------- 1 | Q3 = -pi:0.1:pi; 2 | for j=1:numcols(Q3); 3 | M = p560.inertia([0 0 Q3(j) 0 0 0]); 4 | M22(j) = M(2,2); 5 | end 6 | plot(Q3, M22) 7 | xlabel('q_3 (rad)'); 8 | ylabel('M_{22}'); 9 | -------------------------------------------------------------------------------- /robot/examples/gait.m: -------------------------------------------------------------------------------- 1 | function q = gait(cycle, k, offset, flip) 2 | k = mod(k+offset-1, numrows(cycle)) + 1; 3 | q = cycle(k,:); 4 | if flip 5 | q(1) = -q(1); % for left-side legs 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /robot/examples/map1.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/examples/map1.mat -------------------------------------------------------------------------------- /robot/examples/moveline.m: -------------------------------------------------------------------------------- 1 | % target loine 2 | L = [1 -2 4]; 3 | clf 4 | axis([0 10 0 10]); 5 | hold on 6 | xyzlabel 7 | x = [0 10]; 8 | y = -(L(1)*x+L(3))/L(2); 9 | plot(x, y, 'k--'); 10 | grid on 11 | 12 | xc = 5; yc = 5; 13 | N = 4; 14 | radius = 3; 15 | 16 | for i=1:N 17 | th = (i-1)*2*pi/N; 18 | x0 = [xc+radius*cos(th) yc+radius*sin(th) th+pi/2]; 19 | 20 | plot_vehicle(x0, 'r'); 21 | r = sim('sl_driveline'); 22 | y = r.find('yout'); 23 | plot(y(:,1), y(:,2)); 24 | end 25 | -------------------------------------------------------------------------------- /robot/examples/movepoint.m: -------------------------------------------------------------------------------- 1 | xg = [5 5]; % goal position 2 | clf 3 | axis([0 10 0 10]); 4 | hold on 5 | xyzlabel 6 | grid on 7 | xc = 5; yc = 5; 8 | N = 8; 9 | radius = 3; 10 | 11 | for i=1:N 12 | th = (i-1)*2*pi/N; 13 | x0 = [xc+radius*cos(th) yc+radius*sin(th) th+pi/2]; 14 | 15 | plot_vehicle(x0, 'r'); 16 | r = sim('sl_drivepoint'); 17 | y = r.find('yout'); 18 | plot(y(:,1), y(:,2)); 19 | end 20 | plot(xg(1), xg(2), '*') 21 | -------------------------------------------------------------------------------- /robot/examples/movepose.m: -------------------------------------------------------------------------------- 1 | xg = [5 5 pi/2]; 2 | clf 3 | axis([0 10 0 10]); 4 | hold on 5 | xyzlabel 6 | grid on 7 | xc = 5; yc = 5; 8 | N = 8; 9 | radius = 4; 10 | 11 | for i=1:N 12 | th = (i-1)*2*pi/N; 13 | x0 = [xc+radius*cos(th) yc+radius*sin(th) 0]; 14 | 15 | plot_vehicle(x0, 'r'); 16 | r = sim('sl_drivepose'); 17 | y = r.find('yout'); 18 | plot(y(:,1), y(:,2)); 19 | end 20 | plot_vehicle(xg, 'r'); 21 | -------------------------------------------------------------------------------- /robot/examples/sensorfield.m: -------------------------------------------------------------------------------- 1 | function sensor = sensorfield(x, y) 2 | 3 | xc = 60; yc = 90; 4 | 5 | sensor = 200 ./ ((x-xc).^2 + (y-yc).^2 + 200); 6 | -------------------------------------------------------------------------------- /robot/info.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | R14 7 | Robotics 8 | toolbox 9 | ApplicationIcon.MATLAB 10 | info 11 | 12 | 13 | 14 | 15 | 16 | doc robot/ 17 | $toolbox/matlab/general/bookicon.gif 18 | 19 | 20 | 21 | 22 | rtbstartup 23 | $toolbox/matlab/general/demoicon.gif 24 | 25 | 26 | 27 | 28 | web http://www.petercorke.com -browser; 29 | $toolbox/matlab/general/webicon.gif 30 | 31 | 32 | 33 | 34 | 35 | -------------------------------------------------------------------------------- /robot/info/acknowledgements.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | Acknowledgements 4 | 5 | 6 | 7 | 8 | 9 |

Robotics Toolbox for Matlab

10 |

Acknowledgements

11 |
12 | The following have contributed to the Robotics Toolbox 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 |
Joern MalzahnCodeGenerator module
Paul Pounds Quadcopter code
Wynand SmartVarious arm robot models
Paul NewmanInspiration for the mobile robot estimation classes
Robert Biro and Gary Von McMurraySolution for Puma560 robot
21 | 22 | 23 | -------------------------------------------------------------------------------- /robot/info/html/Prismatic.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: Prismatic 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: PrismaticView code for Prismatic
14 |

Prismatic

Robot manipulator Prismatic link class

15 | A subclass of the Link class: holds all information related to a robot 16 | link such as kinematics parameters, rigid-body inertial parameters, motor 17 | and transmission parameters. 18 | 19 |

20 |

Notes

21 |
    22 |
  • This is reference class object
  • 23 |
  • Link class objects can be used in vectors and arrays
  • 24 |
25 |

References

26 |
    27 |
  • Robotics, Vision & Control, Chap 7 28 | P. Corke, Springer 2011.
  • 29 |
30 |

See also

31 |

32 | Link, revolute, SerialLink

33 |
34 |
35 | 36 | 37 |
 
38 |

© 1990-2012 Peter Corke.

39 | -------------------------------------------------------------------------------- /robot/info/html/Revolute.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: Revolute 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: RevoluteView code for Revolute
14 |

Revolute

Robot manipulator Revolute link class

15 | A subclass of the Link class: holds all information related to a robot 16 | link such as kinematics parameters, rigid-body inertial parameters, motor 17 | and transmission parameters. 18 | 19 |

20 |

Notes

21 |
    22 |
  • This is reference class object
  • 23 |
  • Link class objects can be used in vectors and arrays
  • 24 |
25 |

References

26 |
    27 |
  • Robotics, Vision & Control, Chap 7 28 | P. Corke, Springer 2011.
  • 29 |
30 |

See also

31 |

32 | Link, prismatic, SerialLink

33 |
34 |
35 | 36 | 37 |
 
38 |

© 1990-2012 Peter Corke.

39 | -------------------------------------------------------------------------------- /robot/info/html/about.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: about 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: aboutView code for about
14 |

about

Compact display of variable type

15 | about(x) displays a compact line that describes the class and dimensions of 16 | x. 17 | 18 |

19 |

20 | about x as above but this is the command rather than functional form 21 | 22 |

23 |

See also

24 |

25 | whos

26 |
27 | 28 | 29 |
 
30 |

© 1990-2012 Peter Corke.

31 | -------------------------------------------------------------------------------- /robot/info/html/angvec2r.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: angvec2r 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: angvec2rView code for angvec2r
14 |

angvec2r

Convert angle and vector orientation to a rotation matrix

15 | R = angvec2r(theta, v) is an orthonormal rotation matrix, R, 16 | equivalent to a rotation of theta about the vector v. 17 | 18 |

19 |

See also

20 |

21 | eul2r, rpy2r

22 |
23 | 24 | 25 |
 
26 |

© 1990-2012 Peter Corke.

27 | -------------------------------------------------------------------------------- /robot/info/html/angvec2tr.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: angvec2tr 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: angvec2trView code for angvec2tr
14 |

angvec2tr

Convert angle and vector orientation to a homogeneous transform

15 | T = angvec2tr(theta, v) is a homogeneous transform matrix equivalent to a 16 | rotation of theta about the vector v. 17 | 18 |

19 |

Note

20 |
    21 |
  • The translational part is zero.
  • 22 |
23 |

See also

24 |

25 | eul2tr, rpy2tr, angvec2r

26 |
27 | 28 | 29 |
 
30 |

© 1990-2012 Peter Corke.

31 | -------------------------------------------------------------------------------- /robot/info/html/colnorm.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: colnorm 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: colnormView code for colnorm
14 |

colnorm

Column-wise norm of a matrix

15 | cn = colnorm(a) is an Mx1 vector of the normals of each column of the 16 | matrix a which is NxM. 17 | 18 |

19 |
20 | 21 | 22 |
 
23 |

© 1990-2012 Peter Corke.

24 | -------------------------------------------------------------------------------- /robot/info/html/delta2tr.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: delta2tr 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: delta2trView code for delta2tr
14 |

delta2tr

Convert differential motion to a homogeneous transform

15 | T = delta2tr(d) is a homogeneous transform representing differential 16 | translation and rotation. The vector d=(dx, dy, dz, dRx, dRy, dRz) 17 | represents an infinitessimal motion, and is an approximation to the spatial 18 | velocity multiplied by time. 19 | 20 |

21 |

See also

22 |

23 | tr2delta

24 |
25 | 26 | 27 |
 
28 |

© 1990-2012 Peter Corke.

29 | -------------------------------------------------------------------------------- /robot/info/html/diff2.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: diff2 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: diff2View code for diff2
14 |

diff2

Two point difference

15 | d = diff2(v) is the 2-point difference for each point in the vector v 16 | and the first element is zero. The vector d has the same length as v. 17 | 18 |

19 |

See also

20 |

21 | diff

22 |
23 | 24 | 25 |
 
26 |

© 1990-2012 Peter Corke.

27 | -------------------------------------------------------------------------------- /robot/info/html/doesblockexist.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: doesblockexist 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: doesblockexistView code for doesblockexist
14 |

doesblockexist

Check existence of block in Simulink model

15 | res = doesblockexist(mdlname, blockaddress) is a logical result that 16 | indicates whether or not the block blockaddress exists within the 17 | Simulink model mdlname. 18 | 19 |

20 |

Author

21 |

22 | Joern Malzahn 23 | 2012 RST, Technische Universitaet Dortmund, Germany. 24 | http://www.rst.e-technik.tu-dortmund.de 25 | 26 |

27 |

See also

28 |

29 | symexpr2slblock, distributeblocks

30 |
31 | 32 | 33 |
 
34 |

© 1990-2012 Peter Corke.

35 | -------------------------------------------------------------------------------- /robot/info/html/e2h.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: e2h 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: e2hView code for e2h
14 |

e2h

Euclidean to homogeneous

15 | H = e2h(E) is the homogeneous version (K+1xN) of the Euclidean 16 | points E (KxN) where each column represents one point in RˆK. 17 | 18 |

19 |

See also

20 |

21 | h2e

22 |
23 | 24 | 25 |
 
26 |

© 1990-2012 Peter Corke.

27 | -------------------------------------------------------------------------------- /robot/info/html/gauss2d.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: gauss2d 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: gauss2dView code for gauss2d
14 |

gauss2d

Gaussian kernel

15 | out = gauss2d(im, sigma, C) is a unit volume Gaussian kernel rendered into 16 | matrix out (WxH) the same size as im (WxH). The Gaussian has a standard 17 | deviation of sigma. The Gaussian is centered at C=[U,V]. 18 | 19 |

20 |
21 | 22 | 23 |
 
24 |

© 1990-2012 Peter Corke.

25 | -------------------------------------------------------------------------------- /robot/info/html/h2e.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: h2e 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: h2eView code for h2e
14 |

h2e

Homogeneous to Euclidean

15 | E = h2e(H) is the Euclidean version (K-1xN) of the homogeneous 16 | points H (KxN) where each column represents one point in PˆK. 17 | 18 |

19 |

See also

20 |

21 | e2h

22 |
23 | 24 | 25 |
 
26 |

© 1990-2012 Peter Corke.

27 | -------------------------------------------------------------------------------- /robot/info/html/homline.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: homline 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: homlineView code for homline
14 |

homline

Homogeneous line from two points

15 | L = homline(x1, y1, x2, y2) is a vector (3x1) which describes a line in 16 | homogeneous form that contains the two Euclidean points (x1,y1) and (x2,y2). 17 | 18 |

19 |

20 | Homogeneous points X (3x1) on the line must satisfy L'*X = 0. 21 | 22 |

23 |

See also

24 |

25 | plot_homline

26 |
27 | 28 | 29 |
 
30 |

© 1990-2012 Peter Corke.

31 | -------------------------------------------------------------------------------- /robot/info/html/ishomog.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: ishomog 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: ishomogView code for ishomog
14 |

ishomog

Test if argument is a homogeneous transformation

15 | ishomog(T) is true (1) if the argument T is of dimension 4x4 or 4x4xN, else 16 | false (0). 17 | 18 |

19 |

20 | ishomog(T, 'valid') as above, but also checks the validity of the rotation 21 | matrix. 22 | 23 |

24 |

Notes

25 |
    26 |
  • The first form is a fast, but incomplete, test for a transform in SE(3)
  • 27 |
  • Does not work for the SE(2) case
  • 28 |
29 |

See also

30 |

31 | isrot, isvec

32 |
33 | 34 | 35 |
 
36 |

© 1990-2012 Peter Corke.

37 | -------------------------------------------------------------------------------- /robot/info/html/isrot.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: isrot 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: isrotView code for isrot
14 |

isrot

Test if argument is a rotation matrix

15 | isrot(R) is true (1) if the argument is of dimension 3x3 or 3x3xN, else false (0). 16 | 17 |

18 |

19 | isrot(R, 'valid') as above, but also checks the validity of the rotation 20 | matrix. 21 | 22 |

23 |

Notes

24 |
    25 |
  • A valid rotation matrix has determinant of 1.
  • 26 |
27 |

See also

28 |

29 | ishomog, isvec

30 |
31 | 32 | 33 |
 
34 |

© 1990-2012 Peter Corke.

35 | -------------------------------------------------------------------------------- /robot/info/html/numcols.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: numcols 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: numcolsView code for numcols
14 |

numcols

Return number of columns in matrix

15 | nc = numcols(m) is the number of columns in the matrix m. 16 | 17 |

18 |

See also

19 |

20 | numrows

21 |
22 | 23 | 24 |
 
25 |

© 1990-2012 Peter Corke.

26 | -------------------------------------------------------------------------------- /robot/info/html/numrows.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: numrows 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: numrowsView code for numrows
14 |

numrows

Return number of rows in matrix

15 | nr = numrows(m) is the number of rows in the matrix m. 16 | 17 |

18 |

See also

19 |

20 | numcols

21 |
22 | 23 | 24 |
 
25 |

© 1990-2012 Peter Corke.

26 | -------------------------------------------------------------------------------- /robot/info/html/plot2.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: plot2 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: plot2View code for plot2
14 |

plot2

Plot trajectories

15 | plot2(p) plots a line with coordinates taken from successive rows of p. p 16 | can be Nx2 or Nx3. 17 | 18 |

19 |

20 | If p has three dimensions, ie. Nx2xM or Nx3xM then the M trajectories are 21 | overlaid in the one plot. 22 | 23 |

24 |

25 | plot2(p, ls) as above but the line style arguments ls are passed to plot. 26 | 27 |

28 |

See also

29 |

30 | plot

31 |
32 | 33 | 34 |
 
35 |

© 1990-2012 Peter Corke.

36 | -------------------------------------------------------------------------------- /robot/info/html/plot_arrow.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: plot_arrow 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: plot_arrowView code for plot_arrow
14 |

plot_arrow

Plot arrow

15 | plot_arrow(p, options) draws an arrow from P1 to P2 where p=[P1; P2]. 16 | 17 |

18 |

See also

19 |

20 | arrow3

21 |
22 | 23 | 24 |
 
25 |

© 1990-2012 Peter Corke.

26 | -------------------------------------------------------------------------------- /robot/info/html/plot_homline.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: plot_homline 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: plot_homlineView code for plot_homline
14 |

plot_homline

Draw a line in homogeneous form

15 | H = plot_homline(L, ls) draws a line in the current figure L.X = 0. The current 16 | axis limits are used to determine the endpoints of the line. Matlab line 17 | specification ls can be set. 18 | 19 |

20 |

21 | The return argument is a vector of graphics handles for the lines. 22 | 23 |

24 |

See also

25 |

26 | homline

27 |
28 | 29 | 30 |
 
31 |

© 1990-2012 Peter Corke.

32 | -------------------------------------------------------------------------------- /robot/info/html/plotbotopt.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: plotbotopt 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: plotbotoptView code for plotbotopt
14 |

plotbotopt

Define default options for robot plotting

15 | A user provided function that returns a cell array of default 16 | plot options for the SerialLink.plot method. 17 | 18 |

19 |

See also

20 |

21 | SerialLink.plot

22 |
23 | 24 | 25 |
 
26 |

© 1990-2012 Peter Corke.

27 | -------------------------------------------------------------------------------- /robot/info/html/plotp.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: plotp 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: plotpView code for plotp
14 |

plotp

Plot trajectories

15 | plotp(p) plots a set of points p, which by Toolbox convention are stored 16 | one per column. p can be Nx2 or Nx3. By default a linestyle of 'bx' 17 | is used. 18 | 19 |

20 |

21 | plotp(p, ls) as above but the line style arguments ls are passed to plot. 22 | 23 |

24 |

See also

25 |

26 | plot, plot2

27 |
28 | 29 | 30 |
 
31 |

© 1990-2012 Peter Corke.

32 | -------------------------------------------------------------------------------- /robot/info/html/polydiff.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: polydiff 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: polydiffView code for polydiff
14 |

polydiff

pd = polydiff(p)

15 | Return the coefficients of the derivative of polynomial p 16 | 17 |

18 |
19 | 20 | 21 |
 
22 |

© 1990-2012 Peter Corke.

23 | -------------------------------------------------------------------------------- /robot/info/html/qplot.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: qplot 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: qplotView code for qplot
14 |

qplot

Plot joint angles

15 | qplot(q) is a convenience function to plot joint angle trajectories (Mx6) for 16 | a 6-axis robot, where each row represents one time step. 17 | 18 |

19 |

20 | The first three joints are shown as solid lines, the last three joints (wrist) 21 | are shown as dashed lines. A legend is also displayed. 22 | 23 |

24 |

25 | qplot(T, q) as above but displays the joint angle trajectory versus time T (Mx1). 26 | 27 |

28 |

See also

29 |

30 | jtraj, plot

31 |
32 | 33 | 34 |
 
35 |

© 1990-2012 Peter Corke.

36 | -------------------------------------------------------------------------------- /robot/info/html/r2t.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: r2t 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: r2tView code for r2t
14 |

r2t

Convert rotation matrix to a homogeneous transform

15 | T = r2t(R) is a homogeneous transform equivalent to an orthonormal 16 | rotation matrix R with a zero translational component. 17 | 18 |

19 |

Notes

20 |
    21 |
  • Works for T in either SE(2) or SE(3)
  • 22 |
      23 |
    • if R is 2x2 then T is 3x3, or
    • 24 |
    • if R is 3x3 then T is 4x4.
    • 25 |
    26 |
  • Translational component is zero.
  • 27 |
  • For a rotation matrix sequence returns a homogeneous transform 28 | sequence.
  • 29 |
30 |

See also

31 |

32 | t2r

33 |
34 | 35 | 36 |
 
37 |

© 1990-2012 Peter Corke.

38 | -------------------------------------------------------------------------------- /robot/info/html/randinit.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: randinit 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: randinitView code for randinit
14 |

randinit

Reset random number generator

15 | RANDINIT reset the defaul random number stream. 16 | 17 |

18 |

See also

19 |

20 | randstream

21 |
22 | 23 | 24 |
 
25 |

© 1990-2012 Peter Corke.

26 | -------------------------------------------------------------------------------- /robot/info/html/rotx.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: rotx 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: rotxView code for rotx
14 |

rotx

Rotation about X axis

15 | R = rotx(theta) is a rotation matrix representing a rotation of theta 16 | radians about the x-axis. 17 | 18 |

19 |

20 | R = rotx(theta, 'deg') as above but theta is in degrees. 21 | 22 |

23 |

See also

24 |

25 | roty, rotz, angvec2r

26 |
27 | 28 | 29 |
 
30 |

© 1990-2012 Peter Corke.

31 | -------------------------------------------------------------------------------- /robot/info/html/roty.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: roty 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: rotyView code for roty
14 |

roty

Rotation about Y axis

15 | R = roty(theta) is a rotation matrix representing a rotation of theta 16 | radians about the y-axis. 17 | 18 |

19 |

20 | R = roty(theta, 'deg') as above but theta is in degrees. 21 | 22 |

23 |

See also

24 |

25 | rotx, rotz, angvec2r

26 |
27 | 28 | 29 |
 
30 |

© 1990-2012 Peter Corke.

31 | -------------------------------------------------------------------------------- /robot/info/html/rotz.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: rotz 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: rotzView code for rotz
14 |

rotz

Rotation about Z axis

15 | R = rotz(theta) is a rotation matrix representing a rotation of theta 16 | radians about the z-axis. 17 | 18 |

19 |

20 | R = rotz(theta, 'deg') as above but theta is in degrees. 21 | 22 |

23 |

See also

24 |

25 | rotx, roty, angvec2r

26 |
27 | 28 | 29 |
 
30 |

© 1990-2012 Peter Corke.

31 | -------------------------------------------------------------------------------- /robot/info/html/rtbdemo.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: rtbdemo 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: rtbdemoView code for rtbdemo
14 |

rtbdemo

Robot toolbox demonstrations

15 | Displays popup menu of toolbox demonstration scripts that illustrate: 16 | 17 |

18 |
    19 |
  • homogeneous transformations
  • 20 |
  • trajectories
  • 21 |
  • forward kinematics
  • 22 |
  • inverse kinematics
  • 23 |
  • robot animation
  • 24 |
  • inverse dynamics
  • 25 |
  • forward dynamics
  • 26 |
27 |

Notes

28 |
    29 |
  • The scripts require the user to periodically hit in order to move 30 | through the explanation.
  • 31 |
  • Set PAUSE OFF if you want the scripts to run completely automatically.
  • 32 |
33 |
34 | 35 | 36 |
 
37 |

© 1990-2012 Peter Corke.

38 | -------------------------------------------------------------------------------- /robot/info/html/skew.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: skew 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: skewView code for skew
14 |

skew

Create skew-symmetric matrix

15 | s = skew(v) is a skew-symmetric matrix formed from v (3x1). 16 | 17 |

18 |
19 | | 0   -vz  vy|
20 | | vz   0  -vx|
21 | |-vy   vx  0 |
22 | 
23 |

See also

24 |

25 | vex

26 |
27 | 28 | 29 |
 
30 |

© 1990-2012 Peter Corke.

31 | -------------------------------------------------------------------------------- /robot/info/html/startup_rtb.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: startup_rtb 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: startup_rtbView code for startup_rtb
14 |

startup_rtb

Initialize MATLAB paths for Robotics Toolbox

15 | Adds demos, examples to the MATLAB path, and adds also to 16 | Java class path. 17 | 18 |

19 |
20 | 21 | 22 |
 
23 |

© 1990-2012 Peter Corke.

24 | -------------------------------------------------------------------------------- /robot/info/html/tr2jac.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: tr2jac 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: tr2jacView code for tr2jac
14 |

tr2jac

Jacobian for differential motion

15 | J = tr2jac(T) is a Jacobian matrix (6x6) that maps spatial velocity or 16 | differential motion from the world frame to the frame represented by 17 | the homogeneous transform T. 18 | 19 |

20 |

See also

21 |

22 | wtrans, tr2delta, delta2tr

23 |
24 | 25 | 26 |
 
27 |

© 1990-2012 Peter Corke.

28 | -------------------------------------------------------------------------------- /robot/info/html/tripleangle.html: -------------------------------------------------------------------------------- 1 |
2 | 3 | 4 |
 
5 |

© 1990-2012 Peter Corke.

6 | -------------------------------------------------------------------------------- /robot/info/html/trnorm.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: trnorm 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: trnormView code for trnorm
14 |

trnorm

Normalize a homogeneous transform

15 | tn = trnorm(T) is a normalized homogeneous transformation matrix in which 16 | the rotation submatrix R = [N,O,A] is guaranteed to be a proper orthogonal 17 | matrix. The O and A vectors are normalized and the normal vector is formed from 18 | N = O x A, and then we ensure that O and A are orthogonal by O = A x N. 19 | 20 |

21 |

Notes

22 |
    23 |
  • Used to prevent finite word length arithmetic causing transforms to 24 | become `unnormalized'.
  • 25 |
26 |

See also

27 |

28 | oa2tr

29 |
30 | 31 | 32 |
 
33 |

© 1990-2012 Peter Corke.

34 | -------------------------------------------------------------------------------- /robot/info/html/trotx.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: trotx 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: trotxView code for trotx
14 |

trotx

Rotation about X axis

15 | T = trotx(theta) is a homogeneous transformation (4x4) representing a rotation 16 | radians about the x-axis. 17 | 18 |

19 |

20 | T = trotx(theta, 'deg') as above but theta is in degrees. 21 | 22 |

23 |

Notes

24 |
    25 |
  • Translational component is zero.
  • 26 |
27 |

See also

28 |

29 | rotx, troty, trotz

30 |
31 | 32 | 33 |
 
34 |

© 1990-2012 Peter Corke.

35 | -------------------------------------------------------------------------------- /robot/info/html/troty.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: troty 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: trotyView code for troty
14 |

troty

Rotation about Y axis

15 | T = troty(theta) is a homogeneous transformation (4x4) representing a rotation 16 | radians about the y-axis. 17 | 18 |

19 |

20 | T = troty(theta, 'deg') as above but theta is in degrees. 21 | 22 |

23 |

Notes

24 |
    25 |
  • Translational component is zero.
  • 26 |
27 |

See also

28 |

29 | roty, trotx, trotz

30 |
31 | 32 | 33 |
 
34 |

© 1990-2012 Peter Corke.

35 | -------------------------------------------------------------------------------- /robot/info/html/trotz.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: trotz 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: trotzView code for trotz
14 |

trotz

Rotation about Z axis

15 | T = trotz(theta) is a homogeneous transformation (4x4) representing a rotation 16 | radians about the z-axis. 17 | 18 |

19 |

20 | T = trotz(theta, 'deg') as above but theta is in degrees. 21 | 22 |

23 |

Notes

24 |
    25 |
  • Translational component is zero.
  • 26 |
27 |

See also

28 |

29 | rotz, trotx, troty

30 |
31 | 32 | 33 |
 
34 |

© 1990-2012 Peter Corke.

35 | -------------------------------------------------------------------------------- /robot/info/html/unit.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: unit 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: unitView code for unit
14 |

unit

Unitize a vector

15 | vn = unit(v) is a unit vector parallel to v. 16 | 17 |

18 |

Note

19 |
    20 |
  • Reports error for the case where norm(V) is zero.
  • 21 |
22 |
23 | 24 | 25 |
 
26 |

© 1990-2012 Peter Corke.

27 | -------------------------------------------------------------------------------- /robot/info/html/wtrans.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: wtrans 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: wtransView code for wtrans
14 |

wtrans

Transform a wrench between coordinate frames

15 | wt = wtrans(T, w) is a wrench (6x1) in the frame represented by the homogeneous 16 | transform T (4x4) corresponding to the world frame wrench w (6x1). 17 | 18 |

19 |

20 | The wrenches w and wt are 6-vectors of the form [Fx Fy Fz Mx My Mz]. 21 | 22 |

23 |

See also

24 |

25 | tr2delta, tr2jac

26 |
27 | 28 | 29 |
 
30 |

© 1990-2012 Peter Corke.

31 | -------------------------------------------------------------------------------- /robot/info/html/xaxis.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: xaxis 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: xaxisView code for xaxis
14 |

xaxis

Set X-axis scaling

15 | xaxis(max) set x-axis scaling from 0 to max. 16 | 17 |

18 |

19 | xaxis(min, max) set x-axis scaling from min to max. 20 | 21 |

22 |

23 | xaxis([min max]) as above. 24 | 25 |

26 |

27 | xaxis restore automatic scaling for x-axis. 28 | 29 |

30 |
31 | 32 | 33 |
 
34 |

© 1990-2012 Peter Corke.

35 | -------------------------------------------------------------------------------- /robot/info/html/xyzlabel.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: xyzlabel 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: xyzlabelView code for xyzlabel
14 |

xyzlabel

Label X, Y and Z axes

15 | XYZLABEL label the x-, y- and z-axes with 'X', 'Y', and 'Z' 16 | respectiveley 17 | 18 |

19 |
20 | 21 | 22 |
 
23 |

© 1990-2012 Peter Corke.

24 | -------------------------------------------------------------------------------- /robot/info/html/yaxis.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | M-File Help: yaxis 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
M-File Help: yaxisView code for yaxis
14 |

yaxis

Y-axis scaling

15 | yayis(max) 16 | yayis(min, max) 17 | 18 |

19 |

20 | YAXIS restore automatic scaling for this axis 21 | 22 |

23 |
24 | 25 | 26 |
 
27 |

© 1990-2012 Peter Corke.

28 | -------------------------------------------------------------------------------- /robot/info/icons/.svn/all-wcprops: -------------------------------------------------------------------------------- 1 | K 25 2 | svn:wc:ra_dav:version-url 3 | V 47 4 | /svn/!svn/ver/819/matlab/robot/trunk/info/icons 5 | END 6 | more_arrows.gif 7 | K 25 8 | svn:wc:ra_dav:version-url 9 | V 63 10 | /svn/!svn/ver/819/matlab/robot/trunk/info/icons/more_arrows.gif 11 | END 12 | bullet_orange.gif 13 | K 25 14 | svn:wc:ra_dav:version-url 15 | V 65 16 | /svn/!svn/ver/819/matlab/robot/trunk/info/icons/bullet_orange.gif 17 | END 18 | -------------------------------------------------------------------------------- /robot/info/icons/.svn/entries: -------------------------------------------------------------------------------- 1 | 10 2 | 3 | dir 4 | 1080 5 | https://matlab-toolboxes-robotics-vision.googlecode.com/svn/matlab/robot/trunk/info/icons 6 | https://matlab-toolboxes-robotics-vision.googlecode.com/svn 7 | 8 | 9 | 10 | 2012-04-29T10:14:18.347882Z 11 | 819 12 | pic 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 95aecb5c-93d2-d4e9-359e-440943d9824e 28 | 29 | more_arrows.gif 30 | file 31 | 32 | 33 | 34 | 35 | 2012-05-07T03:55:34.000000Z 36 | 0fe462cb290de1069bf3d2445f232d35 37 | 2012-04-29T10:14:18.347882Z 38 | 819 39 | pic 40 | has-props 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 121 62 | 63 | bullet_orange.gif 64 | file 65 | 66 | 67 | 68 | 69 | 2012-05-07T03:55:34.000000Z 70 | 4366f36348e41fc6cb6c998bb3953400 71 | 2012-04-29T10:14:18.347882Z 72 | 819 73 | pic 74 | has-props 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 52 96 | 97 | -------------------------------------------------------------------------------- /robot/info/icons/.svn/prop-base/bullet_orange.gif.svn-base: -------------------------------------------------------------------------------- 1 | K 13 2 | svn:mime-type 3 | V 24 4 | application/octet-stream 5 | END 6 | -------------------------------------------------------------------------------- /robot/info/icons/.svn/prop-base/more_arrows.gif.svn-base: -------------------------------------------------------------------------------- 1 | K 13 2 | svn:mime-type 3 | V 24 4 | application/octet-stream 5 | END 6 | -------------------------------------------------------------------------------- /robot/info/icons/.svn/text-base/bullet_orange.gif.svn-base: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/info/icons/.svn/text-base/bullet_orange.gif.svn-base -------------------------------------------------------------------------------- /robot/info/icons/.svn/text-base/more_arrows.gif.svn-base: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/info/icons/.svn/text-base/more_arrows.gif.svn-base -------------------------------------------------------------------------------- /robot/info/icons/bullet_orange.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/info/icons/bullet_orange.gif -------------------------------------------------------------------------------- /robot/info/icons/more_arrows.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/info/icons/more_arrows.gif -------------------------------------------------------------------------------- /robot/info/rtb-montage-notext.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/info/rtb-montage-notext.png -------------------------------------------------------------------------------- /robot/mdl_coil.m: -------------------------------------------------------------------------------- 1 | %MDL_COIL Create model of a coil manipulator 2 | % 3 | % MDL_COIL creates the workspace variable coil which describes the 4 | % kinematic characteristics of a serial link manipulator that folds into 5 | % a helix shape. By default has 50 joints. 6 | % 7 | % MDL_BALL(N) as above but creates a manipulator with N joints. 8 | % 9 | % Also define the workspace vectors: 10 | % q joint angle vector for default helical configuration 11 | % 12 | % Reference:: 13 | % - "A divide and conquer articulated-body algorithm for parallel O(log(n)) 14 | % calculation of rigid body dynamics, Part 2", 15 | % Int. J. Robotics Research, 18(9), pp 876-892. 16 | % 17 | % Notes:: 18 | % - Unlike most other mdl_xxx scripts this one is actually a function that 19 | % behaves like a script and writes to the global workspace. 20 | % 21 | % See also SerialLink, mdl_puma560akb, mdl_stanford, mdl_twolink, mdl_ball. 22 | function mdl_coil(N) 23 | 24 | if nargin == 0 25 | N = 50; 26 | end 27 | 28 | % create the links 29 | for i=1:N 30 | links(i) = Link('d', 0, 'a', 1/N, 'alpha', 5*pi/N); 31 | end 32 | 33 | % and build a serial link manipulator 34 | r = SerialLink(links, 'name', 'coil'); 35 | 36 | % place the variables into the global workspace 37 | if nargin == 0 38 | assignin('base', 'coil', r); 39 | assignin('base', 'q', 10*pi/N*ones(1,N)); 40 | end -------------------------------------------------------------------------------- /robot/mdl_phantomx.m: -------------------------------------------------------------------------------- 1 | %MDL_PHANTOMX Create model of PhantomX pincher manipulator 2 | % 3 | % mdl_phantomx 4 | % 5 | % Script creates the workspace variable px which describes the 6 | % kinematic characteristics of a PhantomX Pincher Robot, a 4 joint hobby 7 | % class manipulator by Trossen Robotics. 8 | % 9 | % Also define the workspace vectors: 10 | % qz zero joint angle configuration 11 | % 12 | % Notes:: 13 | % - the x-axis is forward, and the z-axis is upwards. 14 | % - uses standard DH conventions. 15 | % - Tool centrepoint is middle of the fingertips. 16 | % - all translational units in mm. 17 | % 18 | % Reference:: 19 | % 20 | % - http://www.trossenrobotics.com/productdocs/assemblyguides/phantomx-basic-robot-arm.html 21 | 22 | L(1) = Revolute('d', 40, 'alpha', -pi/2); 23 | L(2) = Revolute('a', -105, 'alpha', pi, 'offset', pi/2); 24 | L(3) = Revolute('a', -105); 25 | L(4) = Revolute('a', -105); 26 | 27 | % Note alpha_2 = pi, needed to account for rotation axes of joints 3 and 4 having 28 | % opposite sign to joint 2. 29 | % 30 | % s='Rz(q1) Tz(L1) Ry(q2) Tz(L2) Ry(q3) Tz(L3) Ry(q4) Tz(L4)' 31 | % DHFactor(s) 32 | 33 | px = SerialLink(L, 'name', 'PhantomX', 'manufacturer', 'Trossen Robotics'); 34 | qz = [0 0 0 0]; 35 | px.tool = trotz(-pi/2) * trotx(pi/2); 36 | -------------------------------------------------------------------------------- /robot/mex/.svn/text-base/Makefile.svn-base: -------------------------------------------------------------------------------- 1 | rne: frne.c ne.c vmath.c 2 | mex CFLAGS=-std=c99 frne.c ne.c vmath.c 3 | 4 | install: rne 5 | for f in *.mex*; do cp $$f ../@SerialLink/rne.$${f##*.}; done 6 | 7 | uninstall: 8 | rm ../@SerialLink/rne.mex* 9 | 10 | clean: 11 | rm *.mex* *~ 12 | -------------------------------------------------------------------------------- /robot/mex/.svn/text-base/TODO.svn-base: -------------------------------------------------------------------------------- 1 | verify prismatic joint for standard and modified DH 2 | handle base xform 3 | -------------------------------------------------------------------------------- /robot/mex/.svn/text-base/check.m.svn-base: -------------------------------------------------------------------------------- 1 | fprintf('***************************************************************\n') 2 | fprintf('************************ Puma 560 *****************************\n') 3 | fprintf('***************************************************************\n') 4 | clear 5 | mdl_puma560 6 | rdh = p560; 7 | mdl_puma560akb 8 | rmdh = p560m; 9 | 10 | if exist('rne') == 3 11 | error('need to remove rne.mex file from @SerialLink dir'); 12 | end 13 | 14 | check1 15 | 16 | fprintf('\n***************************************************************\n') 17 | fprintf('********************** Stanford arm ***************************\n') 18 | fprintf('***************************************************************\n') 19 | 20 | clear 21 | mdl_stanford 22 | stanfordm 23 | rdh = stanf; 24 | rdhm = stanm; 25 | 26 | check1 27 | -------------------------------------------------------------------------------- /robot/mex/.svn/text-base/check1.m.svn-base: -------------------------------------------------------------------------------- 1 | %CHECK script to compare M-file and MEX-file versions of RNE 2 | 3 | % load the model and remove non-linear friction 4 | rdh = nofriction(rdh, 'coulomb'); 5 | rmdh = nofriction(rdh, 'coulomb'); 6 | 7 | % number of trials 8 | n = 10; 9 | 10 | fprintf('************************ normal case *****************************\n') 11 | args = {}; 12 | fprintf('DH: ') 13 | check2(rdh, n, args); 14 | fprintf('MDH: ') 15 | check2(rmdh, n, args); 16 | 17 | fprintf('************************ no gravity *****************************\n') 18 | args = {[0 0 0]}; 19 | fprintf('DH: ') 20 | check2(rdh, n, args); 21 | fprintf('MDH: ') 22 | check2(rmdh, n, args); 23 | 24 | fprintf('************************ ext force *****************************\n') 25 | args = {[0 0 9.81], [10 10 10 10 10 10]'}; 26 | fprintf('DH: ') 27 | check2(rdh, n, args); 28 | fprintf('MDH: ') 29 | check2(rmdh, n, args); 30 | -------------------------------------------------------------------------------- /robot/mex/.svn/text-base/check2.m.svn-base: -------------------------------------------------------------------------------- 1 | %CHECK2 script to compare M-file and MEX-file versions of RNE 2 | 3 | function check2(robot, n, args) 4 | robot = nofriction(robot, 'coulomb'); 5 | 6 | % create random points in state space 7 | q = rand(n, 6); 8 | qd = rand(n, 6); 9 | qdd = rand(n, 6); 10 | 11 | % test M-file 12 | tic; 13 | tau = rne(robot, q, qd, qdd, args{:}); 14 | t = toc; 15 | 16 | % test MEX-file 17 | tic; 18 | tau_f = frne(robot, q, qd, qdd, args{:}); 19 | t_f = toc; 20 | 21 | % print comparative results 22 | fprintf('Speedup is %10.0f, worst case error is %f\n', ... 23 | t/t_f, max(max(abs(tau-tau_f)))); 24 | -------------------------------------------------------------------------------- /robot/mex/.svn/text-base/make.m.svn-base: -------------------------------------------------------------------------------- 1 | mex frne.c ne.c vmath.c 2 | -------------------------------------------------------------------------------- /robot/mex/.svn/text-base/prismatic.m.svn-base: -------------------------------------------------------------------------------- 1 | stanford 2 | stanfordm 3 | 4 | % number of trials 5 | n = 1; 6 | 7 | % create random points in state space 8 | q = rand(n, 6); 9 | qd = rand(n, 6); 10 | qdd = rand(n, 6); 11 | 12 | jacobn1 = jacobn(stan,q); 13 | jacobn2 = jacobn(stanm,q); 14 | fprintf('Jacob N - Worst case error is %f\n', max(max(abs(jacobn1-jacobn2)))); 15 | 16 | jacob01 = jacob0(stan,q(1,:)); 17 | jacob02 = jacob0(stanm,q(1,:)); 18 | fprintf('Jacob 0 - Worst case error is %f\n', max(max(abs(jacob01-jacob02)))); 19 | 20 | tau1=rne(stan,q,qd,qdd); 21 | tau2=rne(stanm,q,qd,qdd); 22 | 23 | % print comparative results 24 | fprintf('Torques and forces - Worst case error is %f\n', max(max(abs(tau1-tau2)))); 25 | -------------------------------------------------------------------------------- /robot/mex/.svn/text-base/stanford.m.svn-base: -------------------------------------------------------------------------------- 1 | L{1}=link([-pi/2 0 0 0 0 1 0 1 0 1 1 1 0 0 0 291e-6 -62.6111]); 2 | L{2}=link([ pi/2 0 0 1 0 1 0 -1 0 1 1 1 0 0 0 409e-6 107.815]); 3 | L{3}=link([ 0 0 0 0 1 1 0 0 -1 1 1 1 0 0 0 299e-6 -53.7063]); 4 | L{4}=link([-pi/2 0 0 0 0 1 0 1 0 7 0.5 11 9 3 2 291e-6 -62.6111]); 5 | L{5}=link([ pi/2 0 0 0 0 1 0 1 0 3 2 4 5 -3 -6 409e-6 107.815]); 6 | L{6}=link([ 0 0 0 1 0 1 0 0 -1 1 1 1 0 0 0 299e-6 -53.7063]); 7 | stan=robot(L, 'Stanford'); 8 | clear L 9 | -------------------------------------------------------------------------------- /robot/mex/.svn/text-base/stanfordm.m.svn-base: -------------------------------------------------------------------------------- 1 | clear L 2 | L(1) = Link([ 0 0 0 0 0 1 0 0 -1 1 1 1 0 0 0 291e-6 -62.6111], 'modified'); 3 | L(2) = Link([ 0 1 0 -pi/2 0 1 0 0 -1 1 1 1 0 0 0 409e-6 107.815], 'modified'); 4 | L(3) = Link([ 0 0 0 pi/2 1 1 0 0 -1 1 1 1 0 0 0 299e-6 -53.7063], 'modified'); 5 | L(4) = Link([ 0 0 0 0 0 1 0 0 -1 7 11 0.5 2 -3 -9 291e-6 -62.6111], 'modified'); 6 | L(5) = Link([ 0 0 0 -pi/2 0 1 0 0 1 3 4 2 6 3 5 409e-6 107.815], 'modified'); 7 | L(6) = Link([ 0 1 0 pi/2 0 1 0 0 -1 1 1 1 0 0 0 299e-6 -53.7063], 'modified'); 8 | stanm = SerialLink(L, 'name', 'stanford'); 9 | -------------------------------------------------------------------------------- /robot/mex/Makefile: -------------------------------------------------------------------------------- 1 | rne: frne.c ne.c vmath.c 2 | mex CFLAGS=-std=c99 frne.c ne.c vmath.c 3 | 4 | install: rne 5 | for f in *.mex*; do cp $$f ../@SerialLink/rne.$${f##*.}; done 6 | 7 | uninstall: 8 | rm ../@SerialLink/rne.mex* 9 | 10 | clean: 11 | rm *.mex* *~ 12 | -------------------------------------------------------------------------------- /robot/mex/TODO: -------------------------------------------------------------------------------- 1 | verify prismatic joint for standard and modified DH 2 | handle base xform 3 | -------------------------------------------------------------------------------- /robot/mex/check.m: -------------------------------------------------------------------------------- 1 | fprintf('***************************************************************\n') 2 | fprintf('************************ Puma 560 *****************************\n') 3 | fprintf('***************************************************************\n') 4 | clear 5 | mdl_puma560 6 | rdh = p560; 7 | mdl_puma560akb 8 | rmdh = p560m; 9 | 10 | if exist('rne') == 3 11 | error('need to remove rne.mex file from @SerialLink dir'); 12 | end 13 | 14 | check1 15 | 16 | fprintf('\n***************************************************************\n') 17 | fprintf('********************** Stanford arm ***************************\n') 18 | fprintf('***************************************************************\n') 19 | 20 | clear 21 | mdl_stanford 22 | stanfordm 23 | rdh = stanf; 24 | rdhm = stanm; 25 | 26 | check1 27 | -------------------------------------------------------------------------------- /robot/mex/check1.m: -------------------------------------------------------------------------------- 1 | %CHECK script to compare M-file and MEX-file versions of RNE 2 | 3 | % load the model and remove non-linear friction 4 | rdh = nofriction(rdh, 'coulomb'); 5 | rmdh = nofriction(rdh, 'coulomb'); 6 | 7 | % number of trials 8 | n = 10; 9 | 10 | fprintf('************************ normal case *****************************\n') 11 | args = {}; 12 | fprintf('DH: ') 13 | check2(rdh, n, args); 14 | fprintf('MDH: ') 15 | check2(rmdh, n, args); 16 | 17 | fprintf('************************ no gravity *****************************\n') 18 | args = {[0 0 0]}; 19 | fprintf('DH: ') 20 | check2(rdh, n, args); 21 | fprintf('MDH: ') 22 | check2(rmdh, n, args); 23 | 24 | fprintf('************************ ext force *****************************\n') 25 | args = {[0 0 9.81], [10 10 10 10 10 10]'}; 26 | fprintf('DH: ') 27 | check2(rdh, n, args); 28 | fprintf('MDH: ') 29 | check2(rmdh, n, args); 30 | -------------------------------------------------------------------------------- /robot/mex/check2.m: -------------------------------------------------------------------------------- 1 | %CHECK2 script to compare M-file and MEX-file versions of RNE 2 | 3 | function check2(robot, n, args) 4 | robot = nofriction(robot, 'coulomb'); 5 | 6 | % create random points in state space 7 | q = rand(n, 6); 8 | qd = rand(n, 6); 9 | qdd = rand(n, 6); 10 | 11 | % test M-file 12 | tic; 13 | tau = rne(robot, q, qd, qdd, args{:}); 14 | t = toc; 15 | 16 | % test MEX-file 17 | tic; 18 | tau_f = frne(robot, q, qd, qdd, args{:}); 19 | t_f = toc; 20 | 21 | % print comparative results 22 | fprintf('Speedup is %10.0f, worst case error is %f\n', ... 23 | t/t_f, max(max(abs(tau-tau_f)))); 24 | -------------------------------------------------------------------------------- /robot/mex/frne.mexmaci64: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/mex/frne.mexmaci64 -------------------------------------------------------------------------------- /robot/mex/frne.mexw32: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/mex/frne.mexw32 -------------------------------------------------------------------------------- /robot/mex/make.m: -------------------------------------------------------------------------------- 1 | mex CFLAGS=-std=c99 frne.c ne.c vmath.c 2 | -------------------------------------------------------------------------------- /robot/mex/prismatic.m: -------------------------------------------------------------------------------- 1 | stanford 2 | stanfordm 3 | 4 | % number of trials 5 | n = 1; 6 | 7 | % create random points in state space 8 | q = rand(n, 6); 9 | qd = rand(n, 6); 10 | qdd = rand(n, 6); 11 | 12 | jacobn1 = jacobn(stan,q); 13 | jacobn2 = jacobn(stanm,q); 14 | fprintf('Jacob N - Worst case error is %f\n', max(max(abs(jacobn1-jacobn2)))); 15 | 16 | jacob01 = jacob0(stan,q(1,:)); 17 | jacob02 = jacob0(stanm,q(1,:)); 18 | fprintf('Jacob 0 - Worst case error is %f\n', max(max(abs(jacob01-jacob02)))); 19 | 20 | tau1=rne(stan,q,qd,qdd); 21 | tau2=rne(stanm,q,qd,qdd); 22 | 23 | % print comparative results 24 | fprintf('Torques and forces - Worst case error is %f\n', max(max(abs(tau1-tau2)))); 25 | -------------------------------------------------------------------------------- /robot/mex/stanford.m: -------------------------------------------------------------------------------- 1 | L{1}=link([-pi/2 0 0 0 0 1 0 1 0 1 1 1 0 0 0 291e-6 -62.6111]); 2 | L{2}=link([ pi/2 0 0 1 0 1 0 -1 0 1 1 1 0 0 0 409e-6 107.815]); 3 | L{3}=link([ 0 0 0 0 1 1 0 0 -1 1 1 1 0 0 0 299e-6 -53.7063]); 4 | L{4}=link([-pi/2 0 0 0 0 1 0 1 0 7 0.5 11 9 3 2 291e-6 -62.6111]); 5 | L{5}=link([ pi/2 0 0 0 0 1 0 1 0 3 2 4 5 -3 -6 409e-6 107.815]); 6 | L{6}=link([ 0 0 0 1 0 1 0 0 -1 1 1 1 0 0 0 299e-6 -53.7063]); 7 | stan=robot(L, 'Stanford'); 8 | clear L 9 | -------------------------------------------------------------------------------- /robot/mex/stanfordm.m: -------------------------------------------------------------------------------- 1 | clear L 2 | L(1) = Link([ 0 0 0 0 0 1 0 0 -1 1 1 1 0 0 0 291e-6 -62.6111], 'modified'); 3 | L(2) = Link([ 0 1 0 -pi/2 0 1 0 0 -1 1 1 1 0 0 0 409e-6 107.815], 'modified'); 4 | L(3) = Link([ 0 0 0 pi/2 1 1 0 0 -1 1 1 1 0 0 0 299e-6 -53.7063], 'modified'); 5 | L(4) = Link([ 0 0 0 0 0 1 0 0 -1 7 11 0.5 2 -3 -9 291e-6 -62.6111], 'modified'); 6 | L(5) = Link([ 0 0 0 -pi/2 0 1 0 0 1 3 4 2 6 3 5 409e-6 107.815], 'modified'); 7 | L(6) = Link([ 0 1 0 pi/2 0 1 0 0 -1 1 1 1 0 0 0 299e-6 -53.7063], 'modified'); 8 | stanm = SerialLink(L, 'name', 'stanford'); 9 | -------------------------------------------------------------------------------- /robot/plot_vehicle.m: -------------------------------------------------------------------------------- 1 | %plot_vehicle Plot ground vehicle pose 2 | % 3 | % plot_vehicle(X,OPTIONS) draw representation of ground robot as an 4 | % oriented triangle with pose X (1x3) [x,y,theta] or X (3x3) as homogeneous 5 | % transform in SE(2). 6 | % 7 | % Options:: 8 | % 'scale',S Draw vehicle with length S x maximum axis dimension 9 | % 'size',S Draw vehicle with length S 10 | % 11 | % See also Vehicle.plot. 12 | 13 | % TODO needs to work for 3D point 14 | 15 | function plot_vehicle(x, varargin) 16 | 17 | opt.scale = 1/60; 18 | opt.size = []; 19 | 20 | [opt,args] = tb_optparse(opt, varargin); 21 | 22 | % get the current axes 23 | a = axis; 24 | 25 | % compute the dimensions of the robot 26 | if ~isempty(opt.size) 27 | d = opt.size; 28 | else 29 | d = (a(2)+a(4) - a(1)-a(3)) * opt.scale; 30 | end 31 | 32 | if numel(x) == 3 33 | % convert vector form of pose to SE(2) 34 | T = se2(x(1), x(2), x(3)); 35 | else 36 | T = x; 37 | end 38 | 39 | % draw it 40 | % points = [ 41 | % d 0 1 42 | % -d -0.6*d 1 43 | % -d 0.6*d 1 44 | % d 0 1]'; 45 | 46 | points = [ 47 | d 0 48 | -d -0.6*d 49 | -d 0.6*d]'; 50 | 51 | points = homtrans(T, points); 52 | 53 | plot_poly(points, args{:}); 54 | 55 | end 56 | -------------------------------------------------------------------------------- /robot/plotbotopt.m: -------------------------------------------------------------------------------- 1 | %PLOTBOTOPT Define default options for robot plotting 2 | % 3 | % A user provided function that returns a cell array of default 4 | % plot options for the SerialLink.plot method. 5 | % 6 | % See also SerialLink.plot. 7 | 8 | 9 | % Copyright (C) 1993-2011, by Peter I. Corke 10 | % 11 | % This file is part of The Robotics Toolbox for Matlab (RTB). 12 | % 13 | % RTB is free software: you can redistribute it and/or modify 14 | % it under the terms of the GNU Lesser General Public License as published by 15 | % the Free Software Foundation, either version 3 of the License, or 16 | % (at your option) any later version. 17 | % 18 | % RTB is distributed in the hope that it will be useful, 19 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 20 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 21 | % GNU Lesser General Public License for more details. 22 | % 23 | % You should have received a copy of the GNU Leser General Public License 24 | % along with RTB. If not, see . 25 | 26 | function options = plotbotopt 27 | options = {'base' 'perspective'}; 28 | -------------------------------------------------------------------------------- /robot/robot.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/robot.pdf -------------------------------------------------------------------------------- /robot/rotx.m: -------------------------------------------------------------------------------- 1 | %ROTX Rotation about X axis 2 | % 3 | % R = ROTX(THETA) is a rotation matrix representing a rotation of THETA 4 | % radians about the x-axis. 5 | % 6 | % R = ROTX(THETA, 'deg') as above but THETA is in degrees. 7 | % 8 | % See also ROTY, ROTZ, ANGVEC2R. 9 | 10 | 11 | % Copyright (C) 1993-2011, by Peter I. Corke 12 | % 13 | % This file is part of The Robotics Toolbox for Matlab (RTB). 14 | % 15 | % RTB is free software: you can redistribute it and/or modify 16 | % it under the terms of the GNU Lesser General Public License as published by 17 | % the Free Software Foundation, either version 3 of the License, or 18 | % (at your option) any later version. 19 | % 20 | % RTB is distributed in the hope that it will be useful, 21 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 22 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 23 | % GNU Lesser General Public License for more details. 24 | % 25 | % You should have received a copy of the GNU Leser General Public License 26 | % along with RTB. If not, see . 27 | 28 | function R = rotx(t, deg) 29 | 30 | if nargin > 1 && strcmp(deg, 'deg') 31 | t = t *pi/180; 32 | end 33 | 34 | ct = cos(t); 35 | st = sin(t); 36 | R = [ 37 | 1 0 0 38 | 0 ct -st 39 | 0 st ct 40 | ]; 41 | -------------------------------------------------------------------------------- /robot/roty.m: -------------------------------------------------------------------------------- 1 | %ROTY Rotation about Y axis 2 | % 3 | % R = ROTY(THETA) is a rotation matrix representing a rotation of THETA 4 | % radians about the y-axis. 5 | % 6 | % R = ROTY(THETA, 'deg') as above but THETA is in degrees. 7 | % 8 | % See also ROTX, ROTZ, ANGVEC2R. 9 | 10 | 11 | % Copyright (C) 1993-2011, by Peter I. Corke 12 | % 13 | % This file is part of The Robotics Toolbox for Matlab (RTB). 14 | % 15 | % RTB is free software: you can redistribute it and/or modify 16 | % it under the terms of the GNU Lesser General Public License as published by 17 | % the Free Software Foundation, either version 3 of the License, or 18 | % (at your option) any later version. 19 | % 20 | % RTB is distributed in the hope that it will be useful, 21 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 22 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 23 | % GNU Lesser General Public License for more details. 24 | % 25 | % You should have received a copy of the GNU Leser General Public License 26 | % along with RTB. If not, see . 27 | 28 | function R = roty(t, deg) 29 | if nargin > 1 && strcmp(deg, 'deg') 30 | t = t *pi/180; 31 | end 32 | ct = cos(t); 33 | st = sin(t); 34 | R = [ 35 | ct 0 st 36 | 0 1 0 37 | -st 0 ct 38 | ]; 39 | -------------------------------------------------------------------------------- /robot/rotz.m: -------------------------------------------------------------------------------- 1 | %ROTZ Rotation about Z axis 2 | % 3 | % R = ROTZ(THETA) is a rotation matrix representing a rotation of THETA 4 | % radians about the z-axis. 5 | % 6 | % R = ROTZ(THETA, 'deg') as above but THETA is in degrees. 7 | % 8 | % See also ROTX, ROTY, ANGVEC2R. 9 | 10 | 11 | % Copyright (C) 1993-2011, by Peter I. Corke 12 | % 13 | % This file is part of The Robotics Toolbox for Matlab (RTB). 14 | % 15 | % RTB is free software: you can redistribute it and/or modify 16 | % it under the terms of the GNU Lesser General Public License as published by 17 | % the Free Software Foundation, either version 3 of the License, or 18 | % (at your option) any later version. 19 | % 20 | % RTB is distributed in the hope that it will be useful, 21 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 22 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 23 | % GNU Lesser General Public License for more details. 24 | % 25 | % You should have received a copy of the GNU Leser General Public License 26 | % along with RTB. If not, see . 27 | 28 | function R = rotz(t, deg) 29 | if nargin > 1 && strcmp(deg, 'deg') 30 | t = t *pi/180; 31 | end 32 | 33 | ct = cos(t); 34 | st = sin(t); 35 | R = [ 36 | ct -st 0 37 | st ct 0 38 | 0 0 1 39 | ]; 40 | -------------------------------------------------------------------------------- /robot/skew.m: -------------------------------------------------------------------------------- 1 | %SKEW Create skew-symmetric matrix 2 | % 3 | % S = SKEW(V) is a skew-symmetric matrix formed from V (3x1). 4 | % 5 | % | 0 -vz vy| 6 | % | vz 0 -vx| 7 | % |-vy vx 0 | 8 | % 9 | % See also VEX. 10 | 11 | 12 | % Copyright (C) 1993-2011, by Peter I. Corke 13 | % 14 | % This file is part of The Robotics Toolbox for Matlab (RTB). 15 | % 16 | % RTB is free software: you can redistribute it and/or modify 17 | % it under the terms of the GNU Lesser General Public License as published by 18 | % the Free Software Foundation, either version 3 of the License, or 19 | % (at your option) any later version. 20 | % 21 | % RTB is distributed in the hope that it will be useful, 22 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 23 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 24 | % GNU Lesser General Public License for more details. 25 | % 26 | % You should have received a copy of the GNU Leser General Public License 27 | % along with RTB. If not, see . 28 | 29 | function S = skew(v) 30 | if isvec(v,3) 31 | % SO(3) case 32 | S = [ 0 -v(3) v(2) 33 | v(3) 0 -v(1) 34 | -v(2) v(1) 0]; 35 | elseif isvec(v,1) 36 | % SO(2) case 37 | S = [0 -v; v 0]; 38 | else 39 | error('argument must be a 1- or 3-vector'); 40 | end 41 | -------------------------------------------------------------------------------- /robot/startup_rtb.m: -------------------------------------------------------------------------------- 1 | %STARTUP_RVC Initialize MATLAB paths for Robotics Toolbox 2 | % 3 | % Adds demos, examples to the MATLAB path, and adds also to 4 | % Java class path. 5 | release = load('RELEASE'); 6 | fprintf('- Robotics Toolbox for Matlab (release %.1f)\n', release) 7 | tbpath = fileparts(which('Link')); 8 | addpath( fullfile(tbpath, 'demos') ); 9 | addpath( fullfile(tbpath, 'examples') ); 10 | addpath( fullfile(tbpath, 'mex') ); 11 | javaaddpath( fullfile(tbpath, 'DH.jar') ); 12 | %currentversion = urlread('http://www.petercorke.com/RTB/currentversion.php'); 13 | currentversion = '0'; 14 | currentversion = str2double(currentversion); 15 | %{ 16 | if release ~= currentversion 17 | fprintf('** Release %.1f now available\n\n', ... 18 | currentversion); 19 | end 20 | %} 21 | clear release currentversion 22 | -------------------------------------------------------------------------------- /robot/tr2jac.m: -------------------------------------------------------------------------------- 1 | %TR2JAC Jacobian for differential motion 2 | % 3 | % J = TR2JAC(T) is a Jacobian matrix (6x6) that maps spatial velocity or 4 | % differential motion from the world frame to the frame represented by 5 | % the homogeneous transform T. 6 | % 7 | % See also WTRANS, TR2DELTA, DELTA2TR. 8 | 9 | 10 | % Copyright (C) 1993-2011, by Peter I. Corke 11 | % 12 | % This file is part of The Robotics Toolbox for Matlab (RTB). 13 | % 14 | % RTB is free software: you can redistribute it and/or modify 15 | % it under the terms of the GNU Lesser General Public License as published by 16 | % the Free Software Foundation, either version 3 of the License, or 17 | % (at your option) any later version. 18 | % 19 | % RTB is distributed in the hope that it will be useful, 20 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 21 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 22 | % GNU Lesser General Public License for more details. 23 | % 24 | % You should have received a copy of the GNU Leser General Public License 25 | % along with RTB. If not, see . 26 | 27 | function J = tr2jac(T) 28 | 29 | R = t2r(T); 30 | J = [ 31 | R' (skew(transl(T))*R)' 32 | zeros(3,3) R' 33 | ]; 34 | -------------------------------------------------------------------------------- /robot/tripleangle.fig: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zchen24/rvctools/c37635be2c361e6ba944c6a465104eb5504bc896/robot/tripleangle.fig -------------------------------------------------------------------------------- /robot/trotx.m: -------------------------------------------------------------------------------- 1 | %TROTX Rotation about X axis 2 | % 3 | % T = TROTX(THETA) is a homogeneous transformation (4x4) representing a rotation 4 | % radians about the x-axis. 5 | % 6 | % T = TROTX(THETA, 'deg') as above but THETA is in degrees. 7 | % 8 | % Notes:: 9 | % - Translational component is zero. 10 | % 11 | % See also ROTX, TROTY, TROTZ. 12 | 13 | 14 | % Copyright (C) 1993-2011, by Peter I. Corke 15 | % 16 | % This file is part of The Robotics Toolbox for Matlab (RTB). 17 | % 18 | % RTB is free software: you can redistribute it and/or modify 19 | % it under the terms of the GNU Lesser General Public License as published by 20 | % the Free Software Foundation, either version 3 of the License, or 21 | % (at your option) any later version. 22 | % 23 | % RTB is distributed in the hope that it will be useful, 24 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 25 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 26 | % GNU Lesser General Public License for more details. 27 | % 28 | % You should have received a copy of the GNU Leser General Public License 29 | % along with RTB. If not, see . 30 | 31 | function T = trotx(t, varargin) 32 | T = [rotx(t, varargin{:}) [0 0 0]'; 0 0 0 1]; 33 | -------------------------------------------------------------------------------- /robot/troty.m: -------------------------------------------------------------------------------- 1 | %TROTY Rotation about Y axis 2 | % 3 | % T = TROTY(THETA) is a homogeneous transformation (4x4) representing a rotation 4 | % radians about the y-axis. 5 | % 6 | % T = TROTY(THETA, 'deg') as above but THETA is in degrees. 7 | % 8 | % Notes:: 9 | % - Translational component is zero. 10 | % 11 | % See also ROTY, TROTX, TROTZ. 12 | 13 | 14 | % Copyright (C) 1993-2011, by Peter I. Corke 15 | % 16 | % This file is part of The Robotics Toolbox for Matlab (RTB). 17 | % 18 | % RTB is free software: you can redistribute it and/or modify 19 | % it under the terms of the GNU Lesser General Public License as published by 20 | % the Free Software Foundation, either version 3 of the License, or 21 | % (at your option) any later version. 22 | % 23 | % RTB is distributed in the hope that it will be useful, 24 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 25 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 26 | % GNU Lesser General Public License for more details. 27 | % 28 | % You should have received a copy of the GNU Leser General Public License 29 | % along with RTB. If not, see . 30 | 31 | function T = troty(t, varargin) 32 | T = [roty(t, varargin{:}) [0 0 0]'; 0 0 0 1]; 33 | -------------------------------------------------------------------------------- /robot/trotz.m: -------------------------------------------------------------------------------- 1 | %TROTZ Rotation about Z axis 2 | % 3 | % T = TROTZ(THETA) is a homogeneous transformation (4x4) representing a rotation 4 | % radians about the z-axis. 5 | % 6 | % T = TROTZ(THETA, 'deg') as above but THETA is in degrees. 7 | % 8 | % Notes:: 9 | % - Translational component is zero. 10 | % 11 | % See also ROTZ, TROTX, TROTY. 12 | 13 | 14 | % Copyright (C) 1993-2011, by Peter I. Corke 15 | % 16 | % This file is part of The Robotics Toolbox for Matlab (RTB). 17 | % 18 | % RTB is free software: you can redistribute it and/or modify 19 | % it under the terms of the GNU Lesser General Public License as published by 20 | % the Free Software Foundation, either version 3 of the License, or 21 | % (at your option) any later version. 22 | % 23 | % RTB is distributed in the hope that it will be useful, 24 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 25 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 26 | % GNU Lesser General Public License for more details. 27 | % 28 | % You should have received a copy of the GNU Leser General Public License 29 | % along with RTB. If not, see . 30 | 31 | function T = trotz(t, varargin) 32 | T = [rotz(t, varargin{:}) [0 0 0]'; 0 0 0 1]; 33 | -------------------------------------------------------------------------------- /robot/unit.m: -------------------------------------------------------------------------------- 1 | %UNIT Unitize a vector 2 | % 3 | % VN = UNIT(V) is a unit vector parallel to V. 4 | % 5 | % Note:: 6 | % - Reports error for the case where norm(V) is zero. 7 | 8 | 9 | % Copyright (C) 1993-2011, by Peter I. Corke 10 | % 11 | % This file is part of The Robotics Toolbox for Matlab (RTB). 12 | % 13 | % RTB is free software: you can redistribute it and/or modify 14 | % it under the terms of the GNU Lesser General Public License as published by 15 | % the Free Software Foundation, either version 3 of the License, or 16 | % (at your option) any later version. 17 | % 18 | % RTB is distributed in the hope that it will be useful, 19 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 20 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 21 | % GNU Lesser General Public License for more details. 22 | % 23 | % You should have received a copy of the GNU Leser General Public License 24 | % along with RTB. If not, see . 25 | 26 | function u = unit(v) 27 | n = norm(v, 'fro'); 28 | if n < eps 29 | error('RTB:unit:zero_norm', 'vector has zero norm'); 30 | end 31 | 32 | u = v / n; 33 | -------------------------------------------------------------------------------- /robot/wtrans.m: -------------------------------------------------------------------------------- 1 | %WTRANS Transform a wrench between coordinate frames 2 | % 3 | % WT = WTRANS(T, W) is a wrench (6x1) in the frame represented by the homogeneous 4 | % transform T (4x4) corresponding to the world frame wrench W (6x1). 5 | % 6 | % The wrenches W and WT are 6-vectors of the form [Fx Fy Fz Mx My Mz]. 7 | % 8 | % See also TR2DELTA, TR2JAC. 9 | 10 | % Copyright (C) 1993-2011, by Peter I. Corke 11 | % 12 | % This file is part of The Robotics Toolbox for Matlab (RTB). 13 | % 14 | % RTB is free software: you can redistribute it and/or modify 15 | % it under the terms of the GNU Lesser General Public License as published by 16 | % the Free Software Foundation, either version 3 of the License, or 17 | % (at your option) any later version. 18 | % 19 | % RTB is distributed in the hope that it will be useful, 20 | % but WITHOUT ANY WARRANTY; without even the implied warranty of 21 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 22 | % GNU Lesser General Public License for more details. 23 | % 24 | % You should have received a copy of the GNU Leser General Public License 25 | % along with RTB. If not, see . 26 | 27 | function Wt = wtrans(T, W) 28 | 29 | f = W(1:3); m = W(4:6); 30 | k = cross(f, transl(T) ) + m; 31 | 32 | ft = t2r(T)' * f; 33 | mt = t2r(T)' * k; 34 | 35 | Wt = [ft; mt]; 36 | -------------------------------------------------------------------------------- /simulink/sensorfield.m: -------------------------------------------------------------------------------- 1 | function sensor = sensorfield(x, y) 2 | xc = 60; yc = 90; 3 | sensor = 200./((x-xc).^2 + (y-yc).^2 + 200); 4 | -------------------------------------------------------------------------------- /startup_rvc.m: -------------------------------------------------------------------------------- 1 | disp('Robotics, Vision & Control: (c) Peter Corke 1992-2011 http://www.petercorke.com') 2 | tb = false; 3 | rvcpath = fileparts( mfilename('fullpath') ); 4 | 5 | robotpath = fullfile(rvcpath, 'robot'); 6 | if exist(robotpath,'dir') 7 | addpath(robotpath); 8 | tb = true; 9 | startup_rtb 10 | end 11 | 12 | visionpath = fullfile(rvcpath, 'vision'); 13 | if exist(visionpath,'dir') 14 | addpath(visionpath); 15 | tb = true; 16 | startup_mvtb 17 | end 18 | 19 | if tb 20 | addpath(fullfile(rvcpath, 'common')); 21 | addpath(fullfile(rvcpath, 'simulink')); 22 | end 23 | 24 | clear tb rvcpath robotpath visionpath 25 | --------------------------------------------------------------------------------