SlideShare una empresa de Scribd logo
1 de 14
MATLAB® Introduction

             游懷祖
       AOCS/ME Dept, NSPO
         2006, March 02
捕魚的方法
• Online help:
  – http://www.mathworks.com
  – Home  Support  Product Documentation 
    “fishes” (HTML or PDF files)
• Offline help:
  – F1 key  help
  – Demos
     • Help  Demos
     • $MATLAB71/demos/*.swf (flash example movies)
  – Books
Before Getting Started…

 MATLAB: core program.
 MATLAB Toolboxes: extended
   program  M-files (or p-files).
 Simulink: GUI block diagram.
 Simulink Blocksets: extended
   Simulink.
Tonight: only (1) (75%) & (3) (25%).
Outline

• MATLAB
  – Mathematics
  – Graphics
  – Programming
• Simulink
  – Graphic User Interface (GUI) block diagram
    modeling
Integrated Design Environment
Mathematics
• Matrix-based representation
Mathematics Examples
Ex1: State transition matrix   Ex2: eigenvalue &
                               singular value decomposition
Graphics
• Basic graphic commands:




• Specialized plots & animation (make AVI movies):
  pie, histogram, contour plot, getframe, etc.
• Graphic handles: get, set commands; gcf, gca.
• Figure save, export, print, etc.
Graphic Examples
  Ex1: signal plot   Ex2: image conversion
Programming

• Data type (class):
  number (double),
  string (char), cell,
  logic, handle, etc.    Function handle Ex.

• Function handle:
  using @ or inline
  command
• Script vs. Function
• Array vs. For-loop
Programming Example (script)
Programming Example (function)
Simulink

• Choosing a solver: continuous/discrete
• Import/Export data
• Configuration sets/parameters
• Integrated with MATLAB
  workspace, M-files, C/C++  S-
  function
• Advanced level: Stateflow, Real-Time
  Workshop, xPC Target
Simulink Example
                                                              Scope
                                                          w

                  y                                                                XY Graph
     -C-          J    RotEOM y dot                                            x
                                                1
                  T                          xo s
     MOI                                                  q
                  Euler Rotational          Integrator                         y
                                                              q     tip pos
                   Eq. of motion
                                      -C- [w0,q0]                              z
                                                               body z-axis
   Pulse                                                      tip trajectory
                                                                               Terminator
  Generator




                  [0 0 1]

                      b3
                                       Matrix
                      DCM             Multiply       1
       1      q             be
                                                    tip
       q                              Product
                      q2c                           pos

  Masked subsystem

Más contenido relacionado

La actualidad más candente

Ecad &vlsi lab 18
Ecad &vlsi lab 18Ecad &vlsi lab 18
Ecad &vlsi lab 18Shekar Midde
 
Graphics in C programming
Graphics in C programmingGraphics in C programming
Graphics in C programmingKamal Acharya
 
Reed Solomon Matlab Projects Research Ideas
Reed Solomon Matlab Projects Research IdeasReed Solomon Matlab Projects Research Ideas
Reed Solomon Matlab Projects Research IdeasMatlab Simulation
 
Finite State Machines with Output
Finite State Machines with OutputFinite State Machines with Output
Finite State Machines with OutputMustafa Saeed
 
2014.06.24.graph support
2014.06.24.graph support2014.06.24.graph support
2014.06.24.graph supportJim Cooley
 
Pre-Cal 40S Slides April 18, 2008
Pre-Cal 40S Slides April 18, 2008Pre-Cal 40S Slides April 18, 2008
Pre-Cal 40S Slides April 18, 2008Darren Kuropatwa
 

La actualidad más candente (9)

Ecad &vlsi lab 18
Ecad &vlsi lab 18Ecad &vlsi lab 18
Ecad &vlsi lab 18
 
19 moore mealy
19 moore mealy19 moore mealy
19 moore mealy
 
Proof
ProofProof
Proof
 
Graphics in C programming
Graphics in C programmingGraphics in C programming
Graphics in C programming
 
Reed Solomon Matlab Projects Research Ideas
Reed Solomon Matlab Projects Research IdeasReed Solomon Matlab Projects Research Ideas
Reed Solomon Matlab Projects Research Ideas
 
Turing machine
Turing machineTuring machine
Turing machine
 
Finite State Machines with Output
Finite State Machines with OutputFinite State Machines with Output
Finite State Machines with Output
 
2014.06.24.graph support
2014.06.24.graph support2014.06.24.graph support
2014.06.24.graph support
 
Pre-Cal 40S Slides April 18, 2008
Pre-Cal 40S Slides April 18, 2008Pre-Cal 40S Slides April 18, 2008
Pre-Cal 40S Slides April 18, 2008
 

Similar a Matlab Intro

HWメニーコアシミュレータScalableCoreシステムの高速化 @IPSJ73
HWメニーコアシミュレータScalableCoreシステムの高速化 @IPSJ73HWメニーコアシミュレータScalableCoreシステムの高速化 @IPSJ73
HWメニーコアシミュレータScalableCoreシステムの高速化 @IPSJ73Shinya Takamaeda-Y
 
Intro matlab and convolution islam
Intro matlab and convolution islamIntro matlab and convolution islam
Intro matlab and convolution islamIslam Alabbasy
 
MATHEON Center Days: Index determination and structural analysis using Algori...
MATHEON Center Days: Index determination and structural analysis using Algori...MATHEON Center Days: Index determination and structural analysis using Algori...
MATHEON Center Days: Index determination and structural analysis using Algori...Dagmar Monett
 
Sebastian Schelter – Distributed Machine Learing with the Samsara DSL
Sebastian Schelter – Distributed Machine Learing with the Samsara DSLSebastian Schelter – Distributed Machine Learing with the Samsara DSL
Sebastian Schelter – Distributed Machine Learing with the Samsara DSLFlink Forward
 
Towards typesafe deep learning in scala
Towards typesafe deep learning in scalaTowards typesafe deep learning in scala
Towards typesafe deep learning in scalaTongfei Chen
 
FPGAによるメニーコアシミュレータScalableCoreシステムの正当性検証
FPGAによるメニーコアシミュレータScalableCoreシステムの正当性検証FPGAによるメニーコアシミュレータScalableCoreシステムの正当性検証
FPGAによるメニーコアシミュレータScalableCoreシステムの正当性検証Shinya Takamaeda-Y
 
2011/11/20 modul8 workshop at Apple Store Ginza
2011/11/20 modul8 workshop at Apple Store Ginza2011/11/20 modul8 workshop at Apple Store Ginza
2011/11/20 modul8 workshop at Apple Store Ginzaopticious
 
Challenges for advanced domain-specific frameworks
Challenges for advanced domain-specific frameworksChallenges for advanced domain-specific frameworks
Challenges for advanced domain-specific frameworksIstvan Rath
 
Co-occurrence Based Recommendations with Mahout, Scala and Spark
Co-occurrence Based Recommendations with Mahout, Scala and SparkCo-occurrence Based Recommendations with Mahout, Scala and Spark
Co-occurrence Based Recommendations with Mahout, Scala and Sparksscdotopen
 
Summer training matlab
Summer training matlab Summer training matlab
Summer training matlab Arshit Rai
 
Summer training matlab
Summer training matlab Summer training matlab
Summer training matlab Arshit Rai
 
Leveraging R in Big Data of Mobile Ads (R在行動廣告大數據的應用)
Leveraging R in Big Data of Mobile Ads (R在行動廣告大數據的應用)Leveraging R in Big Data of Mobile Ads (R在行動廣告大數據的應用)
Leveraging R in Big Data of Mobile Ads (R在行動廣告大數據的應用)Craig Chao
 
Bringing Algebraic Semantics to Mahout
Bringing Algebraic Semantics to MahoutBringing Algebraic Semantics to Mahout
Bringing Algebraic Semantics to Mahoutsscdotopen
 

Similar a Matlab Intro (20)

HWメニーコアシミュレータScalableCoreシステムの高速化 @IPSJ73
HWメニーコアシミュレータScalableCoreシステムの高速化 @IPSJ73HWメニーコアシミュレータScalableCoreシステムの高速化 @IPSJ73
HWメニーコアシミュレータScalableCoreシステムの高速化 @IPSJ73
 
MATLAB & Image Processing
MATLAB & Image ProcessingMATLAB & Image Processing
MATLAB & Image Processing
 
Intro matlab and convolution islam
Intro matlab and convolution islamIntro matlab and convolution islam
Intro matlab and convolution islam
 
MATHEON Center Days: Index determination and structural analysis using Algori...
MATHEON Center Days: Index determination and structural analysis using Algori...MATHEON Center Days: Index determination and structural analysis using Algori...
MATHEON Center Days: Index determination and structural analysis using Algori...
 
Sebastian Schelter – Distributed Machine Learing with the Samsara DSL
Sebastian Schelter – Distributed Machine Learing with the Samsara DSLSebastian Schelter – Distributed Machine Learing with the Samsara DSL
Sebastian Schelter – Distributed Machine Learing with the Samsara DSL
 
Towards typesafe deep learning in scala
Towards typesafe deep learning in scalaTowards typesafe deep learning in scala
Towards typesafe deep learning in scala
 
FPGAによるメニーコアシミュレータScalableCoreシステムの正当性検証
FPGAによるメニーコアシミュレータScalableCoreシステムの正当性検証FPGAによるメニーコアシミュレータScalableCoreシステムの正当性検証
FPGAによるメニーコアシミュレータScalableCoreシステムの正当性検証
 
2011/11/20 modul8 workshop at Apple Store Ginza
2011/11/20 modul8 workshop at Apple Store Ginza2011/11/20 modul8 workshop at Apple Store Ginza
2011/11/20 modul8 workshop at Apple Store Ginza
 
Challenges for advanced domain-specific frameworks
Challenges for advanced domain-specific frameworksChallenges for advanced domain-specific frameworks
Challenges for advanced domain-specific frameworks
 
Matlab robotics toolbox
Matlab robotics toolboxMatlab robotics toolbox
Matlab robotics toolbox
 
Fit Main
Fit MainFit Main
Fit Main
 
Co-occurrence Based Recommendations with Mahout, Scala and Spark
Co-occurrence Based Recommendations with Mahout, Scala and SparkCo-occurrence Based Recommendations with Mahout, Scala and Spark
Co-occurrence Based Recommendations with Mahout, Scala and Spark
 
Summer training matlab
Summer training matlab Summer training matlab
Summer training matlab
 
Matlab/R Dictionary
Matlab/R DictionaryMatlab/R Dictionary
Matlab/R Dictionary
 
Summer training matlab
Summer training matlab Summer training matlab
Summer training matlab
 
Lec2
Lec2Lec2
Lec2
 
MSc Presentation
MSc PresentationMSc Presentation
MSc Presentation
 
Leveraging R in Big Data of Mobile Ads (R在行動廣告大數據的應用)
Leveraging R in Big Data of Mobile Ads (R在行動廣告大數據的應用)Leveraging R in Big Data of Mobile Ads (R在行動廣告大數據的應用)
Leveraging R in Big Data of Mobile Ads (R在行動廣告大數據的應用)
 
Matlab
MatlabMatlab
Matlab
 
Bringing Algebraic Semantics to Mahout
Bringing Algebraic Semantics to MahoutBringing Algebraic Semantics to Mahout
Bringing Algebraic Semantics to Mahout
 

Último

Modern Roaming for Notes and Nomad – Cheaper Faster Better Stronger
Modern Roaming for Notes and Nomad – Cheaper Faster Better StrongerModern Roaming for Notes and Nomad – Cheaper Faster Better Stronger
Modern Roaming for Notes and Nomad – Cheaper Faster Better Strongerpanagenda
 
Generative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfGenerative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfIngrid Airi González
 
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024BookNet Canada
 
2024 April Patch Tuesday
2024 April Patch Tuesday2024 April Patch Tuesday
2024 April Patch TuesdayIvanti
 
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24Mark Goldstein
 
QCon London: Mastering long-running processes in modern architectures
QCon London: Mastering long-running processes in modern architecturesQCon London: Mastering long-running processes in modern architectures
QCon London: Mastering long-running processes in modern architecturesBernd Ruecker
 
Genislab builds better products and faster go-to-market with Lean project man...
Genislab builds better products and faster go-to-market with Lean project man...Genislab builds better products and faster go-to-market with Lean project man...
Genislab builds better products and faster go-to-market with Lean project man...Farhan Tariq
 
Generative AI - Gitex v1Generative AI - Gitex v1.pptx
Generative AI - Gitex v1Generative AI - Gitex v1.pptxGenerative AI - Gitex v1Generative AI - Gitex v1.pptx
Generative AI - Gitex v1Generative AI - Gitex v1.pptxfnnc6jmgwh
 
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...Wes McKinney
 
Zeshan Sattar- Assessing the skill requirements and industry expectations for...
Zeshan Sattar- Assessing the skill requirements and industry expectations for...Zeshan Sattar- Assessing the skill requirements and industry expectations for...
Zeshan Sattar- Assessing the skill requirements and industry expectations for...itnewsafrica
 
A Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software DevelopersA Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software DevelopersNicole Novielli
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxLoriGlavin3
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc
 
Time Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsTime Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsNathaniel Shimoni
 
Data governance with Unity Catalog Presentation
Data governance with Unity Catalog PresentationData governance with Unity Catalog Presentation
Data governance with Unity Catalog PresentationKnoldus Inc.
 
UiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to HeroUiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to HeroUiPathCommunity
 
Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Kaya Weers
 
Potential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsPotential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsRavi Sanghani
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsPixlogix Infotech
 
Moving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfMoving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfLoriGlavin3
 

Último (20)

Modern Roaming for Notes and Nomad – Cheaper Faster Better Stronger
Modern Roaming for Notes and Nomad – Cheaper Faster Better StrongerModern Roaming for Notes and Nomad – Cheaper Faster Better Stronger
Modern Roaming for Notes and Nomad – Cheaper Faster Better Stronger
 
Generative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfGenerative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdf
 
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
 
2024 April Patch Tuesday
2024 April Patch Tuesday2024 April Patch Tuesday
2024 April Patch Tuesday
 
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
 
QCon London: Mastering long-running processes in modern architectures
QCon London: Mastering long-running processes in modern architecturesQCon London: Mastering long-running processes in modern architectures
QCon London: Mastering long-running processes in modern architectures
 
Genislab builds better products and faster go-to-market with Lean project man...
Genislab builds better products and faster go-to-market with Lean project man...Genislab builds better products and faster go-to-market with Lean project man...
Genislab builds better products and faster go-to-market with Lean project man...
 
Generative AI - Gitex v1Generative AI - Gitex v1.pptx
Generative AI - Gitex v1Generative AI - Gitex v1.pptxGenerative AI - Gitex v1Generative AI - Gitex v1.pptx
Generative AI - Gitex v1Generative AI - Gitex v1.pptx
 
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
 
Zeshan Sattar- Assessing the skill requirements and industry expectations for...
Zeshan Sattar- Assessing the skill requirements and industry expectations for...Zeshan Sattar- Assessing the skill requirements and industry expectations for...
Zeshan Sattar- Assessing the skill requirements and industry expectations for...
 
A Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software DevelopersA Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software Developers
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
 
Time Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsTime Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directions
 
Data governance with Unity Catalog Presentation
Data governance with Unity Catalog PresentationData governance with Unity Catalog Presentation
Data governance with Unity Catalog Presentation
 
UiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to HeroUiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to Hero
 
Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)
 
Potential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsPotential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and Insights
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and Cons
 
Moving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfMoving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdf
 

Matlab Intro

  • 1. MATLAB® Introduction 游懷祖 AOCS/ME Dept, NSPO 2006, March 02
  • 2. 捕魚的方法 • Online help: – http://www.mathworks.com – Home  Support  Product Documentation  “fishes” (HTML or PDF files) • Offline help: – F1 key  help – Demos • Help  Demos • $MATLAB71/demos/*.swf (flash example movies) – Books
  • 3. Before Getting Started…  MATLAB: core program.  MATLAB Toolboxes: extended program  M-files (or p-files).  Simulink: GUI block diagram.  Simulink Blocksets: extended Simulink. Tonight: only (1) (75%) & (3) (25%).
  • 4. Outline • MATLAB – Mathematics – Graphics – Programming • Simulink – Graphic User Interface (GUI) block diagram modeling
  • 7. Mathematics Examples Ex1: State transition matrix Ex2: eigenvalue & singular value decomposition
  • 8. Graphics • Basic graphic commands: • Specialized plots & animation (make AVI movies): pie, histogram, contour plot, getframe, etc. • Graphic handles: get, set commands; gcf, gca. • Figure save, export, print, etc.
  • 9. Graphic Examples Ex1: signal plot Ex2: image conversion
  • 10. Programming • Data type (class): number (double), string (char), cell, logic, handle, etc. Function handle Ex. • Function handle: using @ or inline command • Script vs. Function • Array vs. For-loop
  • 13. Simulink • Choosing a solver: continuous/discrete • Import/Export data • Configuration sets/parameters • Integrated with MATLAB workspace, M-files, C/C++  S- function • Advanced level: Stateflow, Real-Time Workshop, xPC Target
  • 14. Simulink Example Scope w y XY Graph -C- J RotEOM y dot x 1 T xo s MOI q Euler Rotational Integrator y q tip pos Eq. of motion -C- [w0,q0] z body z-axis Pulse tip trajectory Terminator Generator [0 0 1] b3 Matrix DCM Multiply 1 1 q be tip q Product q2c pos Masked subsystem