140 likes | 279 Views
About Me. Tutor Name: Steven Halim Full-time Teaching Assistant and part-time PhD (final year?) in SoC, NUS Former Teaching Assistant for IT1005, Sem 2, 2007/2008 IT1005 (Introduction to Programming with Matlab) is a compulsory module for Chemical Engineering students!
E N D
About Me • Tutor Name: Steven Halim • Full-time Teaching Assistant and part-time PhD (final year?) in SoC, NUS • Former Teaching Assistant for IT1005, Sem 2, 2007/2008 • IT1005 (Introduction to Programming with Matlab)is a compulsory module for Chemical Engineering students! • Probably I will teach IT1005 again next (last?) semester
Materials • The ~40 pages note was NOT created by me! • We will be discussing the overview of the materials in that note • You need to learn the details by reading the note carefully
Objective • As advertised, this workshop is mainly for students who: • Are new with Matlab, but have to use it for FYP or some course projects, etc • Know basic Math stuffs • Has some programming languages background, e.g. C/C++ (CS1101C/1102C) • I will share the basic skills necessary to • Understand existing Matlab codes (e.g. passed down by your senior), and • To code some Matlab codes on your own (e.g. to improve existing codes)
Objective… Err… • Err… I am expert with Matlab… • It is okay… but you will feel bored at the beginning (or most) of this session… • We will only touch tougher topics nearing the end of this session • Alternatively, please help the other participants if they are lost… • Err… I was your IT1005 student last semester • Err… I will be teaching a compressed IT1005 in this session… • Err… I do not know Mathematics at all • Err… speechless… • Err… I have not learned programming at all • It is okay… but you will have harder times in the second half of this session… • Note: You can still use Matlab with just minimal programming skill! • Please use this session to get overview of Matlab!
Be Realistic! • Can I do my FYP (course) project (with Matlab) after this 2 hours session? • Err… I CANNOT give you the entire Matlab knowledge in 2 hours. • Matlab is a big software… • IT1005 module is conducted over ONE full semester… • To have a sufficient mastery of Matlab, you will need to do a lot of hands on! • So, what should I do? • Try my exercises and follow up list (see the last slide of this ppt) at home • Bookmark this URL and visit it later: • http://www.comp.nus.edu.sg/~stevenha/myteaching
Outline • 10-15m Total 10-15m Introduction • 10m Total 20-25m Quick test to gauge your initial skill • 60-75m Total 80-100m Matlab Basics Common Useful Functions in Matlab Control Structures Matlab Programming • 05m Total 85-105m Post test about today’s session • Until end Total 120m A show of Matlab powerful features!
Grade Your Test • I will only tell you the correct answers at the end of this session. • Grade your paper using this guideline: • If blank 0 • If not sure your answer is correct 0 • If really sure your answer is correct see the indicated marks • Total the marks! • Then, keep your test paper until the end of session.
Outline • 10-15m Total 10-15m Introduction • 10m Total 20-25m Quick test to gauge your initial skill • 60-75m Total 80-100m Matlab Basics • Matrix, Matrix operations Common Useful Functions in Matlab • Math functions: sin, cos, abs, sqrt, etc • Graphical plots Control Structures • Sequence, Selection (if/switch),Repetition (for/while loop) Matlab Programming • Script or Function (M-files) • 05m Total 85-105m Post test about today’s session • Until end Total 120m A show of Matlab powerful features!
Teaching Mode • We will use Matlab for these 4 main topics in the next 1-1¼ hour: • Matlab Basics • Common Useful Functions in Matlab • Control Structures • Matlab Programming • So, login to the PC in front of you and run Matlab (icon in desktop)! • Follow my explanation and try it directly. • This will be much more meaningful than giving you all theory…
Outline • 10-15m Total 10-15m Introduction • 10m Total 20-25m Quick test to gauge your initial skill • 60-75m Total 80-100m Matlab Basics Common Useful Functions in Matlab Control Structures Matlab Programming • 05m Total 85-105m Post test about today’s session • Until end Total 120m A show of Matlab powerful features!
Other Matlab Features • Common Engineering Problems/Functions in Matlab (or Toolboxes): • Linear Algebra, e.g. x=A\b • Numerical Methods, e.g. root finding: fzero, fsolve • Symbolic Mathematics, e.g. diff, simplify, pretty • Ordinary Differential Equation (ODE) solvers: Initial Value Problem • Statistics, e.g. mean, std, etc • Function Optimization, e.g. fmincon, fminsearch • Simulation: Simulink • GUIDE: Create Graphical User Interface in Matlab • Connection with external devices: webcam, microphone, signal, etc • Parallel Computation • And MANY others…
Beyond this Session (1) • Matlab internal help system • help <the_thing_that_you_want_to_know> • MathWorks website • Matlab tutorials, demos, webinars, etc • Other Matlab related websites • Google Search Matlab related keyword (GIYF) • Books in NUS Libraries • There are a lot of books in our libraries • I searched the term “Matlab” in LINC and got a lot of hits…
Beyond this Session (2) • Want to use Matlab? • In NUS, Matlab is available in this Lab, COM1, some other Research Labs… • Don’t have Matlab at home? • There is an alternative to Matlab… • Do not use illegal copy of Matlab at home! • Use this: GNU Octave (http://en.wikipedia.org/wiki/GNU_Octave) • My contact: • Email: stevenhalim@gmail.com • Website: http://ww.comp.nus.edu.sg/~stevenha/myteaching • Office: COM1-2-46, Teaching Assistants Office