4-july-data analysis and mathematical modelling using matlab
DESCRIPTION
Very good information recent matlab updations. its a seminar material given by matlabTRANSCRIPT
1© 2013 The MathWorks, Inc.
Design and Analysis of Systems using MATLAB & Simulink
4th July, 2013
Chennai
2
MathWorks Team Introduction
U. M. Sundar
Manoop Kunhambu
WadirajPuranik
Amit Doshi
3
AgendaTime Agenda
10:00 AM – 10:10 AM Welcome Address
10.10 AM – 10:40 AM Key Note Customer Presentation: “Modeling, Simulation & Analysis of induction motor drive using MATLAB/Simulink” – Dr. Paramasivam, Danfoss
10.40 AM – 12:00 AM • Data Analysis using MATLAB• Data analysis• Visualizations• Application deployment
• Mathematical Modeling using MATLAB
12:00 PM – 12:15 PM Break
12:15 PM – 01:15 PM Dynamic System Modeling using Simulink• Modeling Systems Using Equations• Modeling Systems Using Test Data• Modeling Multi-domain Systems using Physical Modeling Tools
01:15 PM – 02:15 PM Lunch
02:15 PM – 03:15 PM Control System Design and Analysis Using MATLAB/Simulink• Interactive Tuning and Design of PID Controllers• Meeting Desired System Response Through Simulation Based Optimization Techniques• Overview of Real-Time Testing Using xPC Target Turnkey Solutions
03:15 PM – 3:30 PM Wrap Up
4© 2013 The MathWorks, Inc.
Data Analysis and Mathematical Modeling using MATLAB
Amit DoshiApplication Engineer - Technical [email protected]
5
Agenda
Agenda
1. Data Analysis using MATLAB• Data analysis• Visualizations• Application deployment
DEMO - I: Wind Data Analysis Tool for Site Selection
2. Mathematical Modeling using MATLAB• Derive and Solve Governing Equations• Optimize System-Design using MATLAB
DEMO - II: Gantry Crane Modeling
6
What is Data Analysis?
Data Analysis is a PROCESS of inspecting, cleaning, transforming and/or modeling data with the GOAL of highlighting useful information and/or supporting decision making.
Some simple examples
According to ‘National Council of Applied Economic Research (NCAER)’ -2010 data240 mi household surveyed
7
Data Analysis: Challenges
Diversified nature of data, missing data and data with errors
Time taken for creating analysis algorithms and documentation
Repetitive Analysis on multiple data files
Acquiring field data from files and get it into software
8
Data Analysis Workflow
Reporting and Documentation
Outputs for Design
Deployment
Share
Files
Software
Instruments/Devices
Access
Code & Applications
Explore & Discover
Signal Analysis
& Visualization
Algorithm Development
Application Development
Automate
1 2 3
9
Software tool
User’s guide
Goal
Site 1
Site 2
Site ..n
Demo 1: Wind Data Analysis Tool for Site Selection
Raw Data
10
Software tool
User’s guide
Goal
Site 1
Site 2
Site ..n
Demo 1: Wind Data Analysis Tool for Site Selection
Raw Data
Import data Extract relevant data Remove error data Analyze the data Create a GUI Create .exe and .pdf
Tasks
11
WindAnalysis.exe
12
Import and Acquire Real Time Data
Import signals from multimedia files.wav, .wma, .aif, .aifc, .aiff, .mp3,.au, .sn.qt, .mov, .avi, .asf, .asx, .wmv, .mpg, .mp2, .mp4
Generate standard waveforms in MATLABSine, sawtooth, square, chirp, Gaussian pulse, …
Acquire signals from an instrument or deviceSignal analyzers, oscilloscopes, data acquisition boards, audio sound cards, …
Files
Software
Instruments/Devices
Access
Code & Applications
1
13
Get Data from Hardware Devices
Data Acquisition ToolboxPlug-in data acquisition devices and sound cards
Instrument Control ToolboxInstruments and RS-232 serial devices
MATLABInterfaces for communicating with everything
Image Acquisition ToolboxImage capture devices
Vehicle Network ToolboxVector CAN bus interface devices
14
Proximity Sensor
Torque Sensor
Strain gauge
DAQ card
Example 2
Example 1
Examples: Hardware Devices & MATLAB
15
Analyze and Forecast using Data
Explore & Discover
Signal Analysis & Visualization
Algorithm Development
Application Development
Data AnalysisManipulate, preprocess, and manage data Analyze data quickly and accurately with prebuilt math and engineering functions
VisualizationBuilt-in graphics (2D,3D and Volviz), Interactive tools to annotate and customize graphics
Curve & Surface FittingPolynomial fits, Custom fits, Cubic Splines, …
Statistical AnalysisPDF, CDF, Regressors, Tree Baggers, Classifiers, Random number generators, univariate and multivariate analysis…
Neural NetworksNeural network fitting, training, testing,…
2
16
Sharing Data Analysis Results
Reporting and Documentation
Outputs for Design
Deployment
Share Basic ReportingBasic Reporting in .pdf, ppt, doc, html, xml and LATEX formats
Customized ReportingCreate customized reports using MATLAB Report Genrator
Standalone ExecutableDeploy MATLAB Applications as Exe, .dll or .lib using MATLAB Compiler
Create Specific Format ExecutableDeploy MATLAB Applications as .jar, .net or as an excel macro using Builder products
3
17
JavaExcel .NETWeb
Deploying Applications with MATLAB
Give MATLAB codeto other users
Share applicationswith end users whodo not need MATLAB– Stand-alone
executables
– Shared libraries
– Software components
.exe.dll.lib
MATLAB Compiler
MATLAB Builder NE
MATLABBuilder EX
MATLABBuilder JA
Explore & Discover ShareAccess
18
MATLABDesktop
End-UserMachine
11
22
33Toolboxes
Deploying Applications with MATLAB
MATLAB Compiler
.exe
19
Summary: Wind data analysis
ShareExplore and CreateData Access
Got the wind data into MATLAB
Extracted relevant data Removed the Excess data Analyzed the data Encapsulate algorithm in GUI
Created report using ‘publish’
Created MATLAB Application
Products Used: MATLAB MATLAB Compiler
Automate
Software tool
User’s guide
20
Data Analysis: Challenges Addressed
Acquiring field data from files and get it into software
Diversified nature of data, missing data and data with errors
Time taken for creating analysis algorithms and documentation
Repetitive Analysis on multiple data files
21
Agenda
Agenda
1. Data Analysis using MATLAB• Data analysis• Visualizations• Application deployment
DEMO : Wind Data Analysis Tool for site selection
2. Mathematical Modeling using MATLAB• Deriving and Solving Governing Equations• Optimizing the system design using MATLAB
DEMO: Gantry crane Modeling
22
What is Mathematical Modeling?
Use of mathematical language to describe a system or process
Mathematical model
Input Output
Some simple examples
Lift on aircraft wing
2222
L
xLnWq to
l
where ..q = liftL = length of wingx = position along wingW = total aircraft weightn = load factor
Fixed deposit calculator
where ..
23
Why develop mathematical models?
Forecast system behaviorPredict and gain insight into system behavior for various “what-if” scenarios– Enables critical decisions
– Reduces the need for testing
Optimize system behaviorIdentify parameters that optimizesystem performance
Design control systems Develop model to represent plantduring control system design
24
Mathematical Modeling: Challenges
Getting mathematical concepts to a software model
Optimizing the mathematical model
Calculations take long time to converge
Documenting models for sharing across a whole organization
25
Mathematical Modeling with MATLAB
Equations
Data
ShareAccess Explore & Create
Derivation & solving
Optimization
Reports
Applications
26
Determine acceleration profile that minimizes payload swing
Demo 2: Modeling Gantry Crane
s25s4
s20s1
s20s1
:sConstraint
2
1
21
f
p
p
ppf
t
t
t
ttt
payload
27
Demo 2: Modeling Gantry Crane
28
Demo 2: Modeling Gantry Crane
29
Approach towards Modeling Gantry Crane
Derive equations of motion
Solving equation of motion using ODE solver
Determine ideal acceleration profile– Constrained minimization
s25s4
s20s1
s20s1
:sConstraint
2
1
21
f
p
p
ppf
t
t
t
ttt
bang-coast-bang
30
Determining the Acceleration Profile of Gantry Crane in
MATLAB
31
Solving Big Problems
Large data set
Problem
Long running
Computationally intensive
Wait
Load data onto multiple machines that work together in parallel
Solutions
Run similar tasks on independent processors in parallel
Reduce sizeof problem
You could…
32
Task 1 Task 2 Task 3 Task 4Task 1 Task 2 Task 3 Task 4
Task Parallel Applications
Time Time
TOOLBOXES
BLOCKSETS
Worker
Worker
Worker
Worker
33
Summary: Modeling Gantry Crane
ShareExplore and Create
Equations
Access
Derivation & solving
Define equations in notebook
Equation derivation (symbolic)
Equation solving and optimization
Parallel computation
Share MATLAB files
Report
Optimization
Products Used MATLAB Symbolic Math Toolbox Optimization Toolbox Parallel Computing Toolbox
34
Mathematical modeling: Challenges Addressed
Getting mathematical concepts to a software model
Optimizing the mathematical model
Documenting models for sharing across a whole organization
Calculations take long time to converge
35
Modeling Higher Order Dynamic Systems
Reduced To 1st Order Differential EquationHigher Order Dynamic Systems
36
Questions?
37
THANK YOU !!!