if: the if construct, which is fundamental to all computing languages, is the basis for a decision making. The simple form of if
in a single line is:
if condition statement, end
Note that conditions are usually a logical expression, which are either true or false. If condition is true, statement is executed, otherwise nothing happens. Condition maybe a vector or matrix, in which case it is true if all its elements are non-zero.
The basic if-else form is:
On the other hand we can have elseif and use it like a ladder:
Decisions, Part 1
Lecture Slides are screen-captured images of important points in the lecture. Students can download and print out these lecture slide images to do practice problems as well as take notes while watching the lecture.
Educator.com recommends MATLAB and Simulink to use with our MATLAB course. MATLAB - Solve numerical problems quickly, so you can focus on coursework and projects rather than programming. Simulink - Model, simulate, and analyze dynamic systems. Target hardware support - Run Simulink models on Arduino, LEGO MINDSTORMS NXT, Raspberry Pi, and other hardware. 10 add-on products for math, statistics, and optimization; controls; signal and image processing; and test and measurement. The package includes a software activation key with instructions to download and install Student Version from www.mathworks.com