© 2019 The MathWorks, Inc. 1© 2015 The MathWorks, Inc.
What’s New in MATLAB
and Simulink
@_prashantrao_
prashantrao
© 2019 The MathWorks, Inc. 2
© 2019 The MathWorks, Inc. 3
Algorithms in Everything
© 2019 The MathWorks, Inc. 4
Using MATLAB & Simulink to Build Algorithms in Everything
Simplifying your work…
…often at higher levels of abstraction.
© 2019 The MathWorks, Inc. 5
Using MATLAB & Simulink to Build Algorithms in Everything
Inputs Design Outputs
© 2019 The MathWorks, Inc. 6
The capability of a machine to
match or exceed intelligent human behavior by
training a machine
to learn the desired behavior
Artificial Intelligence
training a machine
to learn the desired behavior
© 2019 The MathWorks, Inc. 7
Output
Program
There are two ways to get a computer to do what you want
Traditional Programming
COMPUTER
Data
© 2019 The MathWorks, Inc. 8
Program
Output
There are two ways to get a computer to do what you want
Machine Learning
COMPUTER
Data
Model
© 2019 The MathWorks, Inc. 9
Artificial Intelligence
Data Model
Machine
Learning
Deep
Learning
© 2019 The MathWorks, Inc. 10
Input
Using MATLAB and Simulink to Build Deep Learning Models
Inputs
Input
Design
Design
Outputs
Outputs
Data
Machine
Learning
Deep
Learning
Model
© 2019 The MathWorks, Inc. 11
Using Apps for Ground Truth LabelingImage and Video Data
InputDesi
gn
Outp
uts
Computer Vision Toolbox
Input
© 2019 The MathWorks, Inc. 12
Using Apps for Ground Truth LabelingSignal Data
Input
Signal Processing Toolbox
Input
© 2019 The MathWorks, Inc. 13
Using Apps for Ground Truth LabelingAudio Data
Input 2 3
Audio Toolbox
Input
© 2019 The MathWorks, Inc. 14
Using Apps for Designing Deep Learning Networks 2 Design
Deep Learning Toolbox
3
© 2019 The MathWorks, Inc. 15
Using Transfer Learning with Pre-trained Models
2018 201920172016
Inception-v3
ResNet-101
VGG-16
ResNet-18
GoogLeNetDenseNet-
201
SqueezeNet
AlexNet
ResNet-50
Inception-
ResNet-v2
VGG-19Places365-
GoogLeNet
Xception
MobileNet-v2
ShuffleNet
NasNetLarge
NasNetMobile
2 Design 3
© 2019 The MathWorks, Inc. 16
Using Models from Other Frameworks
(…)Caffe
Keras-
Tensorflow
PyTorch
Open Neural Network Exchange
MATLAB ONNX
CNTK
Caffe2
MXNet
Core ML
Deep Learning Toolbox
2 Design 3
© 2019 The MathWorks, Inc. 17
OutputDeploying Deep Learning Applications
ARM
Compute
Library
Intel
MKL-DNN
Library
Design Output
Deep
Learning
Application
Coder
Products
NVIDIA
TensorRT &
cuDNN
Libraries
MATLAB CoderGPU Coder
Inputs
Pre-
processing
Post-
processing
Input Output
© 2019 The MathWorks, Inc. 18
Output
Using MATLAB and Simulink to Build Deep Learning Models
Inputs
Input
Design
Design
Outputs
Output
Data
Machine
Learning
Deep
Learning
Model
Using MATLAB and Simulink for Reinforcement Learning
Reinforcement Learning Toolbox
© 2019 The MathWorks, Inc. 19
Using MATLAB and Simulink for Reinforcement Learning
Reinforcement Learning Toolbox
© 2019 The MathWorks, Inc. 20
Using MATLAB and Simulink for Reinforcement Learning
Inputs
Inputs
Design
Design
Outputs
Outputs
Data
Machine
Learning
Deep
Learning
Model
Reinforcement Learning Toolbox
© 2019 The MathWorks, Inc. 21
Inputs
Using MATLAB and Simulink for Reinforcement Learning
Inputs Design
Design
Outputs
Outputs
Machine
Learning
Deep
Learning
Model
SimulinkReinforcement Learning Toolbox
Scenario Design
Simulation-based
data generation
Generate Data
© 2019 The MathWorks, Inc. 22
Using MATLAB and Simulink for Reinforcement Learning
Reinforcement Learning Toolbox
© 2019 The MathWorks, Inc. 23
Using MATLAB and Simulink for Reinforcement Learning
Inputs
1
Design
2
Outputs
3
Machine
Learning
Deep
Learning
ModelScenario Design
Simulation-based
data generation
Generate Data
Reinforcement Learning Toolbox
Find out more:
Deep Learning and Reinforcement
Learning Workflows in A.I.
Avi Nehemiah
Deep Learning & Autonomous Systems
Track
© 2019 The MathWorks, Inc. 24
Input
Using MATLAB & Simulink to Build Algorithms in Everything
Inputs
Input
Design
Design
Outputs
Outputs
© 2019 The MathWorks, Inc. 25
InputDesi
gn
Outp
utsWorking with Text Data Input
© 2019 The MathWorks, Inc. 26
InputDesi
gn
Outp
utsWorking with Text Data
MATLAB
Input
© 2019 The MathWorks, Inc. 27
InputDesi
gn
Outp
utsWorking with Text Data
Deep Learning ToolboxStatistics and Machine Learning ToolboxText Analytics ToolboxMATLAB
Input
© 2019 The MathWorks, Inc. 28
InputDesi
gn
Outp
utsWorking with Text Data
Text Analytics ToolboxMATLAB
Input
© 2019 The MathWorks, Inc. 29
Creating Your Own Data 2
Simulink
InputInput
© 2019 The MathWorks, Inc. 30
2InputInput
© 2019 The MathWorks, Inc. 31
Identifying the Useful Data 2 Design
Acquire Data
Identify
Condition
Indicators
Deploy &
IntegrateTrain Model
Preprocess
Data
Visualize data
Extract Features
Select the most
useful features
Machine
Learning
© 2019 The MathWorks, Inc. 32
Identifying the Useful Data 2 Design
Predictive Maintenance Toolbox
© 2019 The MathWorks, Inc. 33
Identifying the Useful Data 2 Design
Predictive Maintenance Toolbox
© 2019 The MathWorks, Inc. 34
Identifying the Useful Data
Predictive Maintenance Toolbox
2 Design
© 2019 The MathWorks, Inc. 35
Designing Decision Logic with Stateflow
StateflowMATLAB
in MATLAB 2 Design
© 2019 The MathWorks, Inc. 36
Using Stateflow in MATLAB
StateflowMATLAB
2 Design
© 2019 The MathWorks, Inc. 37
Editing at the Speed of Thought
Simulink
2 Design
© 2019 The MathWorks, Inc. 38
Editing at the Speed of Thought
Simulink
2 Design
© 2019 The MathWorks, Inc. 39
Editing at the Speed of Thought
Simulink
2 Design
© 2019 The MathWorks, Inc. 40
Editing at the Speed of Thought
Simulink
2 Design
© 2019 The MathWorks, Inc. 41
Editing at the Speed of Thought
Simulink
2 Design
© 2019 The MathWorks, Inc. 42
Controlling the Execution of Model Components
Export Function Model
Schedulable Rate-Based Model
Simulink
2 Design
© 2019 The MathWorks, Inc. 43
Controlling the Execution of Model Components
Simulink
2 Design
© 2019 The MathWorks, Inc. 44
Simplifying Integration with External C/C++ Code
Column-Major
Simulink Coder
2 OutputOutput
© 2019 The MathWorks, Inc. 45
Simplifying Integration with External C/C++ Code
Row-Major
Simulink Coder
2 OutputOutput
© 2019 The MathWorks, Inc. 46
Viewing Generated Code Alongside the Model
Embedded Coder
2 OutputOutput
© 2019 The MathWorks, Inc. 47
Viewing Generated Code Alongside the Model
Embedded Coder
2 OutputOutput
© 2019 The MathWorks, Inc. 48
Sharing Live Scripts
MATLAB
2 OutputOutput
© 2019 The MathWorks, Inc. 49
Sharing Live Scripts
MATLAB
2 OutputOutput
© 2019 The MathWorks, Inc. 50
Sharing Live Scripts
MATLAB
2 OutputOutput
© 2019 The MathWorks, Inc. 51
Creating Apps
MATLAB
2 OutputOutput
© 2019 The MathWorks, Inc. 52
OutputDeploying Web Apps
MATLAB Compiler
OutputOutput
© 2019 The MathWorks, Inc. 53
Output
Output
Using MATLAB & Simulink to Build Algorithms in Everything
Inputs Design Outputs
© 2019 The MathWorks, Inc. 54
Evaluating Architectures
Architecture
Inputs Design Outputs
© 2019 The MathWorks, Inc. 55
Arch
Design OutputInput Arch
Evaluating Architectures
Inputs Design OutputsArchitecture
© 2019 The MathWorks, Inc. 56
Designing System and Software Architectures
System1Composer1
Design OutputInput
ArchArch
© 2019 The MathWorks, Inc. 57
Designing System and Software Architectures
System1Composer1
ArchArch
© 2019 The MathWorks, Inc. 58
Designing System and Software Architectures
Find out more:
Systems Engineering:
Requirements to Architecture
to Simulation
Gaurav Dubey
Systems Modeling, Implementation, and
Verification Track
System1Composer1
© 2019 The MathWorks, Inc. 59
Designing Beyond System and
Software Architectures
AUTOSAR SoftwareSystems and
SoftwareSoC Hardware
and Software
System Composer SoC Blockset AUTOSAR Blockset
Design OutputInput
ArchArch
© 2019 The MathWorks, Inc. 60
ArchArchitecture
OutputDesignArchInput
Using MATLAB & Simulink to Build Algorithms in Everything
Inputs Design Outputs
Spanning
Test & Verification Collaboration Scaling
© 2019 The MathWorks, Inc. 61
Architecture
OutputDesignArchInput
Using MATLAB & Simulink to Build Algorithms in Everything
Inputs Design Outputs
Test & Verification
Test & Verification Collaboration Scaling
© 2019 The MathWorks, Inc. 62
Integrating with Third-party Requirements Tools
Simulink Requirements
SimulinkRequirements
External Requirements
Authored Requirements
External Requirements
Requirements
Management
Tools
ReqIF
Import
Edit
Export
Test & Verification
Design OutputInput Arch
Test & Verification
© 2019 The MathWorks, Inc. 63
Include Custom Code in Test & Verification
Simulink Design Verifier
Simulink C/C++ Simulink Design Verifier
Stateflow C/C++
Test & Verification
Design OutputInput Arch
Test & Verification
© 2019 The MathWorks, Inc. 64
Include Custom Code in Test & Verification
Simulink Design Verifier
Simulink C/C++ Simulink Design Verifier
Stateflow C/C++
Find out more:
Simplifying Requirements-Based
Verification with Model-Based Design
Vamshi Kumbham
Systems Modeling, Implementation, and
Verification Track
© 2019 The MathWorks, Inc. 65
Using the MATLAB Unit Test Framework
MATLAB
Design OutputInput Arch
Test & VerificationTest & Verification
© 2019 The MathWorks, Inc. 66
Using the MATLAB App Testing Framework
testCase.press(myApp.checkbox)
testCase.choose(myApp.discreteKnob, "Medium")
testCase.drag(myApp.continuousKnob, 10, 90)
testCase.type(myApp.editfield, myTextVar)
MATLAB
Design OutputInput Arch
Test & VerificationTest & Verification
© 2019 The MathWorks, Inc. 67
Using the MATLAB Performance
Testing Framework
MATLAB
Design OutputInput Arch
Test & VerificationTest & Verification
© 2019 The MathWorks, Inc. 68
Using Continuous Integration
MATLAB https://plugins.jenkins.io/
Design OutputInput Arch
Test & VerificationTest & Verification
© 2019 The MathWorks, Inc. 69
Using Continuous Integration
MATLAB https://plugins.jenkins.io/matlab
Design OutputInput Arch
Test & VerificationTest & Verification
© 2019 The MathWorks, Inc. 70
Using Projects in MATLAB
MATLAB
Design OutputInput Arch
Test & VerificationCollaboration
© 2019 The MathWorks, Inc. 72
Parallel Simulations in Simulink
SimulinkParallel Computing Toolbox
Simulation Manageraafa
Worker
Worker
Worker
Head
Worker
MATLAB Desktop
Simulation Jobs
Simulation Results
batchsim
Design OutputInput Arch
Test & VerificationScaling
© 2019 The MathWorks, Inc. 73
Scaling Computations on Clusters and Clouds
MATLAB Parallel Server
MATLAB
Parallel Computing Toolbox
Cloud
GPU
Multi-core CPU
…
MATLAB Parallel Server
Design OutputInput Arch
ScalingScaling
© 2019 The MathWorks, Inc. 74
Scaling
Input Design OutputArch
Using MATLAB & Simulink to Build Algorithms in Everything
Inputs Design OutputsArchitecture
Scaling
Test & Verification Collaboration Scaling
© 2019 The MathWorks, Inc. 75
Specialized Tools for Building Algorithms
in Everything
Analog Mixed-SignalCommunications Physical interconnects
5G Toolbox SerDes Toolbox Mixed-Signal Blockset
Scaling
Design OutputInput Arch
© 2019 The MathWorks, Inc. 76
Developing Autonomous Systems
Perception
Planning
Control
© 2019 The MathWorks, Inc. 77
Evaluate Sensor Fusion Architectures
Sensor Fusion and Tracking Toolbox
© 2019 The MathWorks, Inc. 78
Simulate Path Planning Algorithms
Automated Driving Toolbox
© 2019 The MathWorks, Inc. 79
Design Lane-following and Spacing
Control Algorithms
Model Predictive Control Toolbox
© 2019 The MathWorks, Inc. 80
Developing Autonomous Systems
UAV AlgorithmsLidar Processing
& Tracking
Computer Vision Toolbox
HERE HD Maps &
OpenDRIVE Roads
Automated Driving Toolbox Robotics System Toolbox
© 2019 The MathWorks, Inc. 81
Developing Autonomous Systems
UAV AlgorithmsLidar Processing
& Tracking
Computer Vision Toolbox
HERE HD Maps &
OpenDRIVE Roads
Automated Driving Toolbox Robotics System Toolbox
Find out more:
Automated Driving System Design
and Simulation
Dr. Amod Anandkumar
Deep Learning and Autonomous Systems
Track
© 2019 The MathWorks, Inc. 82
Using MATLAB & Simulink to Build Algorithms in Everything
Inputs Design OutputsArchitecture
Spanning
Test & Verification Collaboration Scaling
© 2019 The MathWorks, Inc. 85
Get Started
Deep Learning Onramp
Learn to use deep learning techniques
in MATLAB for image recognition.
MATLAB Onramp
Quickly learn the
essentials of MATLAB.
Simulink Onramp
Learn to create, edit, and
troubleshoot Simulink models.
© 2019 The MathWorks, Inc. 86© 2015 The MathWorks, Inc.