- 1、本文档共31页,可阅读全部内容。
- 2、有哪些信誉好的足球投注网站(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。
- 3、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载。
- 4、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
- 5、该文档为VIP文档,如果想要下载,成为VIP会员后,下载免费。
- 6、成为VIP后,下载本文档将扣除1次下载权益。下载后,不支持退款、换文档。如有疑问请联系我们。
- 7、成为VIP后,您将拥有八大权益,权益包括:VIP文档下载权益、阅读免打扰、文档格式转换、高级专利检索、专属身份标志、高级客服、多端互通、版权登记。
- 8、VIP文档为合作方或网友上传,每下载1次, 网站将根据用户上传文档的质量评分、类型等,对文档贡献者给予高额补贴、流量扶持。如果你也想贡献VIP文档。上传文档
查看更多
SIMULINK Lab 1
MATLAB and SIMULINK Basics
Important: Save your models and simulation data of each main step of the simulation in “.m” and “.slx” files
and use the saved files to demonstrate your simulation results to the Lab Supervisor. You lab performance
will be assessed based on your demonstrations, which is 20% of your overall course assessment.
MATLAB Basics Tutorial
Key MATLAB commands used in this tutorial are: plot , polyval , roots , conv , deconv , inv , eig , poly , tf ,
zero
Vectors
Lets start off by creating something simple, like a vector. Enter each element of the vector (separated by a space)
between brackets, and set it equal to a variable. For example, to create the vector a, enter the following into the MATLAB
command window (you can Copy and Paste from your browser into MATLAB to make it easy) and MATLAB should
return the following:
a = [1 2 3 4 5 6 9 8 7]
a =
1 2 3 4 5 6 9 8 7
Lets say you want to create a vector with elements between 0 and 20 evenly spaced in increments of two (this method is
frequently used to create a time vector):
t = 0:2:20
t =
0 2 4 6 8 10 12 14 16 18 20
Manipulating vectors is almost as easy as creating them. First, suppose you would like to add 2 to each of the elements
in the vector a. The equation for that looks like:
b = a + 2
b =
3 4 5 6 7 8 11 10 9
Now suppose, you would like to add two vectors together. If the two vectors are the same length, it is easy. Simply add
the two as shown below:
c = a + b
c =
4 6 8 10 12 14 20 18 16
Subtraction of vectors of the same length works exactly the same way.
Functions
To make life easier, MATLAB includes many standard functions. Each function is a block of code that accomplishes a
specific task. MATLAB contains all of the standard functions such as sin, cos, log, exp, sqrt, as well as many others.
Com
您可能关注的文档
- 聂明-计算机应用技术导论(教学资源)第10部分 职业资格与认证.ppt
- 农产品电商之我见.pdf
- 农业技术产权实施模式及保障.pdf
- 农业技术市场的类型_交易方式及特征.pdf
- 农资电子交易平台的身份认证研究与实现.pdf
- 农资团购是概念炒作-还是营销创新---关于农业投入品团购营销的比对探析.pdf
- 农资物联网技术体系.pdf
- 农资营销迎来电子商务时代.pdf
- 培养结构化思考 世界500强人力资源总监管理笔记 2.pdf
- 培养结构化思考 世界500强人力资源总监管理笔记-第一季.pdf
- 2024年小学教师工作计划模板(八篇) .pdf
- 2024年药学类之药学(师)题库检测试卷B卷附答案 .pdf
- 2024年必威体育精装版仁爱版五年级数学(上册)期中考卷及答案(各版本) .pdf
- 2024年高中生个人职业生涯规划 .pdf
- 2024年法律职业资格之法律职业客观题二题库与答案 .pdf
- 2024年资产评估师之资产评估基础真题练习试卷B卷附答案 .pdf
- 2024年度社工(初级)《社会工作实务(初级)》考试典型题题库及答案.pdf
- 2024年新员工下半年工作计划范文(3篇) .pdf
- 2024年律师委托代理合同标准版本(三篇) .pdf
- 2024年股权抵押借款合同范本(4篇) .pdf
文档评论(0)