share simulink simulations as standalone applications, web ... · applications, web apps, and...

31
Share Simulink Simulations as Standalone Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan Ramanuja Jagannathan

Upload: others

Post on 08-Oct-2020

0 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Share Simulink Simulations as Standalone

Applications, Web Apps, and Enterprise Applications

Dr. Sunil Unnikrishnan

Ramanuja Jagannathan

Page 2: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Key Takeaways

▪ Simulation goes beyond the design phase

▪ Simulation deployment made easy with Simulink Compiler

▪ Share simulations as standalone desktop apps, web apps, or enterprise applications

2

Page 3: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Your Simulation is Your Asset

▪ Simulation is critical to your system design, but it doesn’t stop at design

▪ Maximize your simulation’s value by re-using it

3

Page 4: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Re-use Your Simulation Beyond Design

▪ As a training / teaching tool

Page 5: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Re-use Your Simulation Beyond Design

▪ As a training / teaching tool

▪ As a product evaluation tool

Page 6: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Re-use Your Simulation Beyond Design

▪ As a training / teaching tool

▪ As a product evaluation tool

▪ In-operation usage, for example as a digital twin

Page 7: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

The Right Solution to Deploy Simulations

▪ Common traits of re-using your simulations beyond design

– Simulation used as a black box for specific tasks

– Simulation used for desktop or server applications

– Many end users of simulations are not Simulink users

– Reuse of existing Simulink models from Model-Based Design

▪ What is the right way to deploy the simulation for reuse?

– No products seem to address your requirements entirely

7

Page 8: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Simulation Deployment Made Easy with Simulink Compiler

▪ An out-of-the-box solution to share simulations

– Supports flexible simulation input / parameter tuning workflow

– Supports a variety of Simulink simulation features including variable-step solvers

– Royalty-free distribution

Page 9: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

New Additions to Application Deployment Product Portfolio

MATLAB

MATLAB Compiler SDK

MATLAB Production Server

MATLAB Web App Server

Deployment

Target:

MATLAB Compiler

MATLAB Runtime

Simulink

Simulink Compiler

New

New

Page 10: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Supports a Full Spectrum of Simulation Deployment Scenarios

Standalone Apps

Cropped picture

suggesting

integration into

custom app

Web AppsCropped

picture

suggesting

scaling

production

(JS/HTML-

based app?)

Service APIs

Page 11: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Personas in Simulation Deployment

▪ Simulation Author: They define, build, edit and

compile Simulink simulations

▪ Simulation User: They run, tune, and analyze

the deployed simulations

▪ IT: They support integrating deployed

simulations with IT systems

Page 12: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

A “Hello, World” Example

Four tunable parameters:

▪ Mass

▪ Initial position

▪ Damping coefficient

▪ Spring stiffness

Page 13: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Scenario 1: Standalone Desktop App

▪ Runs on PC

▪ Can use App Designer GUI

▪ Needs local installation

Standalone Apps

Page 14: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Scenario 1: Standalone Desktop App

Code and Applications

Use App Designer to create simulation apps

Simulation Author

Page 15: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Scenario 1: Standalone Desktop App

Code and Applications

Use App Designer to create simulation apps

Simulation Author

Use Simulink Compiler to package

Simulation Author

Page 16: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Scenario 1: Standalone Desktop App

Code and Applications

Run simulation Apps on desktop

Simulation User

Use App Designer to create simulation apps

Simulation Author

Use Simulink Compiler to package

Simulation Author

Page 17: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Scenario 2: Web App

▪ Runs on a Server (MATLAB Web App Server)

▪ Uses App Designer GUI

▪ Browser-based access, no local installation needed

Cropped picture

suggesting

integration into

custom app

Web Apps

Page 18: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Scenario 2: Web App

Code and Applications

The same step as designing a standalone desktop App

Use App Designer to create simulation apps

Simulation Author

Page 19: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Scenario 2: Web App

Code and Applications

The simulation app is packaged as a MATLAB Web App archive file (.ctf)

Use App Designer to create simulation apps

Simulation Author

Use Simulink Compiler to package

Simulation Author

Page 20: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Scenario 2: Web App

Use App Designer to create simulation apps

Simulation Author

Use Simulink Compiler to package

Simulation Author

Host web apps on MATLAB Web App Server

IT

MATLAB Web App Server:

Host and share Simulink simulation

apps created using MATLAB App

Designer

NEW

Page 21: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Scenario 2: Web App

Code and Applications

Use App Designer to create simulation apps

Simulation Author

Use Simulink Compiler to package

Simulation Author

Host web apps on MATLAB Web App Server

IT

Access web apps through URL

Simulation User

No local installation needed

Page 22: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Scenario 3: Service API

▪ Runs on a Server (MATLAB Production Server)

▪ Supports customer developed client-server App and

web app e.g. HTML/JavaScript

▪ Centrally hosted, no local installation needed

Cropped picture

suggesting

scaling

production

(JS/HTML-based

app?)

Service APIs

Page 23: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Scenario 3: Service API

Code and Applications

Wrap simulation as a MATLAB function

Use MATLAB to create a function of simulation

Simulation Author

Page 24: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Scenario 3: Service API

Code and Applications

Package the simulation function as a deployable archive (.ctf)

Use MATLAB to create a function of simulation

Simulation Author

Use Simulink Compiler to package

Simulation Author

Page 25: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Scenario 3: Service API

Use Simulink Compiler to package

Simulation Author

Host the deployed archive on MATLAB

Production Server and Integrate with front-end

enterprise application, web applications

developed with 3rd party tools, or dashboards

IT

Use MATLAB to create a function of simulation

Simulation Author

Page 26: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Scenario 3: Service API

Run simulation via enterprise application /

third party web application, or dashboard

Simulation User

Use Simulink Compiler to package

Simulation Author

Host the deployed archive on MATLAB

Production Server and Integrate with

enterprise application / third party web

application, or dashboard

IT

Use MATLAB to create a function of simulation

Simulation Author

Page 27: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Supports a Full Spectrum of Simulation Deployment Scenarios

Standalone Apps

Cropped picture

suggesting

integration into

custom app

Web AppsCropped

picture

suggesting

scaling

production

(JS/HTML-

based app?)

Service APIs

Page 28: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Summary

▪ Simulation goes beyond the design phase

▪ Simulation deployment made easy with Simulink Compiler

▪ Share simulations as standalone desktop apps, web apps, or enterprise applications

28

Page 29: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Learn More

https://www.mathworks.com/products/simulink-compiler.html

MathWorks Consulting Service

https://www.mathworks.com/services/consulting.html

MathWorks Training Service

https://www.mathworks.com/services/training.html

Page 30: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment

Know mo

30

Page 31: Share Simulink Simulations as Standalone Applications, Web ... · Applications, Web Apps, and Enterprise Applications Dr. Sunil Unnikrishnan ... New Additions to Application Deployment