simulink入门指南2012b
更新时间:2023-05-18 05:48:01 阅读量: 实用文档 文档下载
- simulink入门书籍推荐度:
- 相关推荐
simulink学习,入门指南适合新手,2012b
Simulink®
GettingStartedGuide
R2012b
simulink学习,入门指南适合新手,2012b
HowtoContact
MathWorks
Web
comp.soft-sys.matlabNewsgroup
/contact_TS.htmlTechnical
suggest@
bugs@
doc@
service@
info@ProductenhancementsuggestionsBugreportsDocumentationerrorreportsOrderstatus,licenserenewals,passcodesSales,pricing,andgeneral
information508-647-7000
(Phone)
508-647-7001
(Fax)
TheMathWorks,Inc.3AppleHillDriveNatick,MA01760-2098
Forcontactinformationaboutworldwideoffices,seetheMathWorksWebsite.
Simulink®GettingStartedGuide
©COPYRIGHT1990–2012byTheMathWorks,Inc.
Thesoftwaredescribedinthisdocumentisfurnishedunderalicenseagreement.Thesoftwaremaybeusedorcopiedonlyunderthetermsofthelicenseagreement.NopartofthismanualmaybephotocopiedorreproducedinanyformwithoutpriorwrittenconsentfromTheMathWorks,Inc.
FEDERALACQUISITION:ThisprovisionappliestoallacquisitionsoftheProgramandDocumentationby,for,orthroughthefederalgovernmentoftheUnitedStates.ByacceptingdeliveryoftheProgramorDocumentation,thegovernmentherebyagreesthatthissoftwareordocumentationqualifiesascommercialcomputersoftwareorcommercialcomputersoftwaredocumentationassuchtermsareusedordefinedinFAR12.212,DFARSPart227.72,andDFARS252.227-7014.Accordingly,thetermsandconditionsofthisAgreementandonlythoserightsspecifiedinthisAgreement,shallpertaintoandgoverntheuse,modification,reproduction,release,performance,display,anddisclosureoftheProgramandDocumentationbythefederalgovernment(orotherentityacquiringfororthroughthefederalgovernment)andshallsupersedeanyconflictingcontractualtermsorconditions.IfthisLicensefailstomeetthegovernment’sneedsorisinconsistentinanyrespectwithfederalprocurementlaw,thegovernmentagreestoreturntheProgramandDocumentation,unused,toTheMathWorks,Inc.
Trademarks
MATLABandSimulinkareregisteredtrademarksofTheMathWorks,Inc.See
/trademarksforalistofadditionaltrademarks.Otherproductorbrandnamesmaybetrademarksorregisteredtrademarksoftheirrespectiveholders.
Patents
MathWorksproductsareprotectedbyoneormoreU.S.patents.Pleasesee
/patentsformoreinformation.
simulink学习,入门指南适合新手,2012b
RevisionHistory
SeptemberMarch2005Online
September2006Onlineonly
March2006Onlineonly
September2007Firstonly
March2007Secondprinting
October2008Thirdprinting
March2008Fourthprinting
September2009Fifthprinting
March2009Onlineprinting
September2010Onlineonly
April2010Onlineonly
September2011Onlineonly
March2011Sixth
September20122012Seventhprintingonly
EighthprintingprintingNewRevisedforVersionRevisedforSimulink6.3(Release6.4(Release14SP3)RevisedforRevisedforSimulinkSimulink6.52006a)6.6(Release2006b)RevisedforRevisedforSimulink(Release2007a)Simulink7.0(Release2007b)RevisedforRevisedforSimulink7.1(Release2008a)Simulink7.2(Release2008b)Revisedfor7.3(Release2009a)RevisedforSimulinkSimulink7.47.5(Release(Release2009b)2010a)RevisedforSimulink7.6(Release2010b)Revisedfor
RevisedforSimulinkSimulink7.77.8(Release(Release2011a)2011b)
RevisedforforSimulinkSimulink7.98.0(Release(Release2012a)2012b)
simulink学习,入门指南适合新手,2012b
simulink学习,入门指南适合新手,2012b
1IntroductionProductDescription...............................1-2KeyFeatures.....................................1-2Modeling,Simulation,andAnalysiswithSimulink...1-3ToolforModel-BasedDesign........................1-3ToolforSimulation................................1-4ToolforAnalysis..................................1-4InteractionwithMATLABEnvironment...............1-4Model-BasedDesign...............................1-5WhatIsModel-BasedDesign?.......................1-5Model-BasedDesignProcess........................1-6DocumentationandAdditionalResources...........1-9SimulinkOnlineHelp..............................................................1-9SimulinkExamples
WebSiteResources................................1-10
1-10
2SimulinkSoftwareBasicsStarttheSimulinkSoftware........................OpentheSimulinkLibraryBrowser..................2-2
2-2
CreateaNewSimulinkModel.......................2-4OpenanExistingModel............................2-5SimulinkUserInterface............................2-6SimulinkLibrary...................................Browser..........................2-6SimulinkEditor2-10Contents
v
simulink学习,入门指南适合新手,2012b
viContents3CreateaSimulinkModelCreateaSimpleModel.............................3-2OverviewoftheSimpleModel.......................3-2CreatetheSimpleModel...........................3-3ConnectBlocksintheSimpleModel..................3-8SimulatetheSimpleModel.........................3-12ModelingaDynamicControlSystem4DynamicControlSystemModel.....................4-2AnatomyoftheControlSystemModel...............4-3OpentheExampleModel...........................4-3OverviewoftheExampleModel......................4-4SubsystemsintheExampleModel...................4-6SubsystemsandMasks...........................................................4-10CreatingaSubsystem4-11CreateaSubsystemMask..........................4-12SimulatetheControl................................SystemModel.................4-14RuntheSimulation4-14ChangetheThermostatSetting......................4-15ChangetheAverageOutdoorTemperature............4-17ChangetheDailyTemperatureVariation..............4-19MoveDataBetweenMATLABandSimulinkModel...4-21ImportDatafromtheMATLABWorkspace............4-21ExportSimulationDatatotheMATLABWorkspace.....4-25
simulink学习,入门指南适合新手,2012b
5BasicSimulationWorkflowSimulationwithDataImportandSignalInspection..5-2DataImportandLoggingWorkflow..................5-2ExampleUsedinthisTutorial.......................5-2ImportSignalData...................................................................5-4SimulateModel5-10CompareSignals..................................5-14Create,Save,andPrintaFigure.....................5-16vii
simulink学习,入门指南适合新手,2012b
viiiContents
simulink学习,入门指南适合新手,2012b
1Introduction
“ProductDescription”onpage1-2
“Modeling,Simulation,andAnalysiswithSimulink”onpage1-3 “Model-BasedDesign”onpage1-5
“DocumentationandAdditionalResources”onpage1-9
simulink学习,入门指南适合新手,2012b
Introduction
ProductDescription
1-2SimulationandModel-BasedDesignSimulink®isablockdiagramenvironmentformultidomainsimulationandModel-BasedDesign.Itsupportssystem-leveldesign,simulation,automaticcodegeneration,andcontinuoustestandverificationofembeddedsystems.Simulinkprovidesagraphicaleditor,customizableblocklibraries,andsolversformodelingandsimulatingdynamicsystems.ItisintegratedwithMATLAB®,enablingyoutoincorporateMATLABalgorithmsintomodelsandexportsimulationresultstoMATLABforfurtheranalysis.KeyFeatures Graphicaleditorforbuildingandmanaginghierarchicalblockdiagrams Librariesdiscrete-timeofpredefinedsystemsblocksformodelingcontinuous-timeand Simulationenginewithfixed-stepandvariable-stepODEsolvers Scopesanddatadisplaysforviewingsimulationresults Projectanddatamanagementtoolsformanagingmodelfilesanddata Modelsimulationanalysisspeedtoolsforrefiningmodelarchitectureandincreasing MATLABFunctionblockforimportingMATLABalgorithmsintomodels LegacyCodeToolforimportingCandC++codeintomodels
simulink学习,入门指南适合新手,2012b
Modeling,Simulation,andAnalysiswithSimulink®
Simulation,andAnalysiswithSimulinkInthissection...
“ToolforModel-BasedDesign”onpage1-3
“ToolforSimulation”onpage1-4
“ToolforAnalysis”onpage1-4
“InteractionwithMATLABEnvironment”onpage1-4
ToolforModel-BasedDesign
WithSimulink,youcanmovebeyondidealizedlinearmodelstoexploremorerealisticnonlinearmodels,factoringinfriction,airresistance,gearslippage,hardstops,andtheotherthingsthatdescribereal-worldphenomena.
Simulinkturnsyourcomputerintoalaboratoryformodelingandanalyzingsystemsthatwouldnotbepossibleorpracticalotherwise.
Whetheryouareinterestedinthebehaviorofanautomotiveclutchsystem,theflutterofanairplanewing,ortheeffectofthemonetarysupplyontheeconomy,Simulinkprovidesyouwiththetoolstomodelandsimulatealmostanyreal-worldproblem.Simulinkalsoprovidesexamplesthatmodelawidevarietyofreal-worldphenomena(clicktheExampleslinkatthetopoftheSimulinkDocumentationCentertop-levelpage).
Simulinkprovidesagraphicaluserinterface(GUI)forbuildingmodelsasblockdiagrams,allowingyoutodrawmodelsasyouwouldwithpencilandpaper.Simulinkalsoincludesacomprehensiveblocklibraryofsinks,sources,linearandnonlinearcomponents,andconnectors.Iftheseblocksdonotmeetyourneeds,however,youcanalsocreateyourownblocks.Theinteractivegraphicalenvironmentsimplifiesthemodelingprocess,eliminatingtheneedtoformulatedifferentialanddifferenceequationsinalanguageorprogram.Modelsarehierarchical,soyoucanbuildmodelsusingbothtop-downandbottom-upapproaches.Youcanviewthesystematahighlevel,thendouble-clickblockstoseeincreasinglevelsofmodeldetail.Thisapproachprovidesinsightintohowamodelisorganizedandhowitspartsinteract.
1-3Modeling,
simulink学习,入门指南适合新手,2012b
Introduction
1-4See“Model-BasedDesign”onpage1-5formoreinformationaboutthemodelingprocess.ToolforSimulationAfteryoudefineamodel,youcansimulateitsdynamicbehaviorusingachoiceofmathematicalintegrationmethods,eitherfromtheSimulinkmenusorbyenteringcommandsintheMATLABCommandWindow.Themenusareconvenientforinteractivework,whilethecommandlineisusefulforrunningabatchofsimulations.Forexample,ifyouaredoingMonteCarlosimulationsorwanttoapplyaparameteracrossarangeofvalues,ingscopesandotherdisplayblocks,youcanseethesimulationresultswhilethesimulationruns.Youcanthenchangeparametersandseewhathappensfor“whatif”exploration.ThesimulationresultscanbeputintheMATLABworkspaceforpostprocessingandvisualization.ToolforAnalysisModelanalysistoolsincludelinearizationandtrimmingtools,whichyoucanaccessfromtheMATLABcommandline,plusthemanytoolsinMATLABanditsapplicationtoolboxes.BecauseMATLABandSimulinkareintegrated,youcansimulate,analyze,andreviseyourmodelsineitherenvironmentatanypoint.InteractionwithMATLABEnvironmentSimulinksoftwareistightlyintegratedwiththeMATLABenvironment.ItrequiresMATLABtorun,dependingonittodefineandevaluatemodelandblockparameters.SimulinkcanalsousemanyMATLABfeatures.Forexample,SimulinkcanusetheMATLABenvironmentto: Definemodelinputs. Storemodeloutputsforanalysisandvisualization. Performoperatorsfunctionsandfunctions.withinamodel,throughintegratedcallstoMATLAB
simulink学习,入门指南适合新手,2012b
Model-BasedDesign
Model-BasedDesignInthissection...
“WhatIsModel-BasedDesign?”onpage1-5
“Model-BasedDesignProcess”onpage1-6
WhatIsModel-BasedDesign?
Model-BasedDesignisaprocessthatenablesfaster,morecost-effective
developmentofdynamicsystems,includingcontrolsystems,signalprocessing,andcommunicationssystems.InModel-BasedDesign,asystemmodelisatthecenterofthedevelopmentprocess,fromrequirementsdevelopment,throughdesign,implementation,andtesting.Themodelisanexecutablespecificationthatyoucontinuallyrefinethroughoutthedevelopmentprocess.Aftermodeldevelopment,simulationshowswhetherthemodelworkscorrectly.
Whensoftwareandhardwareimplementationrequirementsareincluded,suchasfixed-pointandtimingbehavior,youcanautomaticallygeneratecodeforembeddeddeploymentandcreatetestbenchesforsystemverification,savingtimeandavoidingtheintroductionofmanuallycodederrors.
Model-BasedDesignallowsyoutoimproveefficiencyby:
Usingacommondesignenvironmentacrossprojectteams
Linkingdesignsdirectlytorequirements
Integratingtestingwithdesigntocontinuouslyidentifyandcorrecterrors Refiningalgorithmsthroughmultidomainsimulation
Automaticallygeneratingembeddedsoftwarecode
Developingandreusingtestsuites
Automaticallygeneratingdocumentation
Reusingtargetsdesignstodeploysystemsacrossmultipleprocessorsandhardware
1-5
simulink学习,入门指南适合新手,2012b
Introduction
1-6Model-BasedDesignProcessTherearesixstepstomodelinganysystem:1DefiningtheSystem2IdentifyingSystemComponents3ModelingtheSystemwithEquations4BuildingtheSimulinkBlockDiagram5RunningtheSimulation6ValidatingtheSimulationResultsYouperformthefirstthreestepsofthisprocessoutsideoftheSimulinksoftwareenvironmentbeforeyoubeginbuildingyourmodel.DefiningtheSystemThefirststepinmodelingadynamicsystemistofullydefinethesystem.Ifyouaremodelingalargesystemthatcanbebrokenintoparts,youshouldmodeleachsubcomponentonitsown.Then,afterbuildingeachcomponent,youcanintegratethemintoacompletemodelofthesystem.Forexample,thesldemo_househeatexamplemodeloftheheatingsystemofahouseisbrokendownintothreemainparts: Heatersubsystem Thermostatsubsystem ThermodynamicmodelsubsystemThemosteffectivewaytobuildamodelofthissystemistoconsidereachofthesesubsystemsindependently.
simulink学习,入门指南适合新手,2012b
Model-BasedDesign
IdentifyingSystemComponents
Thesecondstepinthemodelingprocessistoidentifythesystemcomponents.Threetypesofcomponentsdefineasystem:
Parametersthem—Systemvaluesthatremainconstantunlessyouchange States—Variablesinthesystemthatchangeovertime
Signalssimulation—InputandoutputvaluesthatchangedynamicallyduringaInSimulink,parametersandstatesarerepresentedbyblocks,whilesignalsarerepresentedbythelinesthatconnectblocks.Foreachsubsystemthatyouidentified,askyourselfthefollowingquestions:
Howmanyinputsignalsdoesthesubsystemhave?
Howmanyoutputsignalsdoesthesubsystemhave?
Howmanystates(variables)doesthesubsystemhave?
Whataretheparameters(constants)inthesubsystem?
Arethereanyintermediate(internal)signalsinthesubsystem?
Onceyouhaveansweredthesequestions,youshouldhaveacomprehensivelistofsystemcomponents,andyouarereadytobeginmodelingthesystem.ModelingtheSystemwithEquations
Thethirdstepinmodelingasystemistoformulatethemathematical
equationsthatdescribethesystem.Foreachsubsystem,usethelistofsystemcomponentsthatyouidentifiedtodescribethesystemmathematically.Yourmodelmayinclude:
Algebraicequations
Logicalequations
Differentialequations,forcontinuoussystems
Differenceequations,fordiscretesystems
1-7
simulink学习,入门指南适合新手,2012b
Introduction
1-8YouusetheseequationstocreatetheblockdiagraminSimulink.BuildingtheSimulinkBlockDiagramAfteryouhavedefinedthemathematicalequationsthatdescribeeachsubsystem,youcanbeginbuildingablockdiagramofyourmodelinSimulink.Buildtheblockdiagramforeachofyoursubcomponentsseparately.Afteryouhavemodeledeachsubcomponent,youcanthenintegratethemintoacompletemodelofthesystem.See“CreatetheSimpleModel”onpage3-3formoreinformationonbuildingtheblockdiagram.RunningtheSimulationAfteryoubuildtheSimulinkblockdiagram,youcansimulatethemodelandanalyzetheresults.Simulinkallowsyoutointeractivelydefinesysteminputs,simulatethemodel,andobservechangesinbehavior.Thisallowsyoutoquicklyevaluateyourmodel.See“SimulatetheSimpleModel”onpage3-12formoreinformationonrunningasimulation.ValidatingtheSimulationResultsFinally,youmustvalidatethatyourmodelaccuratelyrepresentsthephysicalcharacteristicsofthedynamicsystem.YoucanusethelinearizationandtrimmingtoolsavailablefromtheMATLABcommandline,plusthemanytoolsinMATLABanditsapplicationtoolboxestoanalyzeandvalidateyourmodel.
simulink学习,入门指南适合新手,2012b
DocumentationandAdditionalResources
DocumentationandAdditionalResourcesInthissection...
“SimulinkOnlineHelp”onpage1-9
“SimulinkExamples”onpage1-10
“WebSiteResources”onpage1-10
SimulinkOnlineHelp
Simulinksoftwareprovidescomprehensiveonlinehelpdescribingfeatures,blocks,andfunctionswithdetailedproceduresforcommontasks.
AccessonlinehelpfromHelpmenusandcontext-sensitiveblocklabels. FromtheSimulinkLibraryBrowser,selectHelp>SimulinkHelp.
FromtheSimulinkEditor,selectHelp>Simulink>SimulinkHelp. Right-clickaSimulinkblock,andthenselectHelp.
Frombox,right-clickthemodelaConfigurationparameterlabel,ParametersthenselectorWhat’sablockparametersThis?dialog
1-9
simulink学习,入门指南适合新手,2012b
Introduction
1-10SimulinkExamplesSimulinksoftwareprovidesavarietyofexamplemodelsthatillustratekeymodelingconceptsandSimulinkfeatures.YoucanaccesstheseexamplesfromtheHelpmenuorfromthedocumentation. FromtheSimulinkEditor,selectHelp>Simulink>Examples. Frompage.thedocumentation,clickExamplesatthetopofthe
productlandingFeaturedexamplesincludeabuttonatthetopoftheHelpbrowserforopeningthemodelin
theSimulinkEditor..WebSiteResourcesYoucanaccessadditionalSimulinkresourcesontheMathWorksWebsite,includingSimulinkrelatedbooks,webinars,andtechnicalsupport.ToaccesstheSimulinkproductpage,goto/products/simulink
simulink学习,入门指南适合新手,2012b
2
SimulinkSoftwareBasics
“StarttheSimulinkSoftware”onpage2-2
“SimulinkUserInterface”onpage2-6
simulink学习,入门指南适合新手,2012b
Simulink®SoftwareBasics
StarttheSimulinkSoftwareInthissection...
“OpentheSimulinkLibraryBrowser”onpage2-2
“CreateaNewSimulinkModel”onpage2-4
“OpenanExistingModel”onpage
2-5
OpentheSimulinkLibraryBrowser
YouneedMATLABrunningbeforeyoucanopentheSimulinkLibraryBrowser.
1StartMATLAB,andthenintheMATLABCommandWindow,entersimulink
TheSimulinkLibraryBrowseropens.
YoucanalsoopentheSimulinkLibraryBrowserfromtheMATLABToolstrip,byclickingtheSimulinkLibrarybutton().
2-2
simulink学习,入门指南适合新手,2012b
StarttheSimulink®Software
IfyouhavenotalreadyloadedSimulink,ashortdelayoccurswhileitloads.TheLibraryBrowseropens.
TokeeptheLibraryBrowseraboveallotherwindowsonyourdesktop,intheLibraryBrowser,selectView>StayonTop.
2-3
正在阅读:
simulink入门指南2012b05-18
外贸函电词汇03-11
2016年广东省初中毕业学业考试12-17
泉州文武庙关帝灵签详解0-100签06-01
220kv降压变电所设计毕业论文04-07
设计计算书 - 图文05-06
河道治理工程05-03
万吨柠檬深加工建设项目可研报告06-17
人教版七年级地理下册_6.1_位置与范围_同步练习(有答案)05-28
转基因食品的科学认识03-24
- 教学能力大赛决赛获奖-教学实施报告-(完整图文版)
- 互联网+数据中心行业分析报告
- 2017上海杨浦区高三一模数学试题及答案
- 招商部差旅接待管理制度(4-25)
- 学生游玩安全注意事项
- 学生信息管理系统(文档模板供参考)
- 叉车门架有限元分析及系统设计
- 2014帮助残疾人志愿者服务情况记录
- 叶绿体中色素的提取和分离实验
- 中国食物成分表2020年最新权威完整改进版
- 推动国土资源领域生态文明建设
- 给水管道冲洗和消毒记录
- 计算机软件专业自我评价
- 高中数学必修1-5知识点归纳
- 2018-2022年中国第五代移动通信技术(5G)产业深度分析及发展前景研究报告发展趋势(目录)
- 生产车间巡查制度
- 2018版中国光热发电行业深度研究报告目录
- (通用)2019年中考数学总复习 第一章 第四节 数的开方与二次根式课件
- 2017_2018学年高中语文第二单元第4课说数课件粤教版
- 上市新药Lumateperone(卢美哌隆)合成检索总结报告
- 入门指南
- simulink
- 2012b
- 甘肃省兰州市2015年中考数学试题(word版,含答案)
- 基于51单片机的多功能电子万年历毕业论文
- 第三方物流实训总结报告
- 5-1节 孤立奇点及分类17
- 内外宣并举 奉化电视台积极做好宁波党代会奉化代表团活动报道
- 幼儿园年会诗朗诵- 一路高歌 同行有你
- 财务管理教材中最佳现金持有量的计算
- 文秘毕业生个人工作实习报告范文
- 各种颜色对应英文单词
- 高中一轮物理练习 第二章 《实验研究匀速直线运动》.
- 标签不良分析报告
- 卡特发动机工作原理
- 最新-大学生2019年第一季度思想汇报范文 精品
- 人物描写赏析技法
- 规划意见书 (建筑工程)
- 公寓委员工作总结
- 幼小衔接视角下小学一年级数学教学的策略_彭英加
- 四类抗生素应用的注意事项
- 仙剑奇侠传5仙剑五数字版激活码
- 煤矿隐患侦知预警与诊断治理及典型事故分析实用手册