Appendix EMATLAB Reference Guide
This appendix summarizes MATLAB commands and functions that are especially useful to the study of signals and systems and that have been used throughout the text. A number of these functions are specific to some optional MATLAB toolbox1; all the commands used here may be found in the MATLAB Student Version. MATLAB is a rich and powerful tool that boasts many more commands and options than can be listed here. For more advanced use of system tools, the MATLAB documentation or help screens should be referenced.
Using only the commands found here, a variety of signals can be defined and plotted. A system can be defined in one of several ways; the system behavior can be confirmed, and a test signal can be input to the system to observe the output. Each of these operations can be readily accomplished in a few lines.
% MATLAB comments are text like this after a percent sign.
E.1 Defining Signals
E.1.1 MATLAB Variables
Variable names in MATLAB are case sensitive, such that Power is different from power.
A few mathematical constants are predefined, including:
i % = square root of -1j % = square root of -1pi % = 3.14159...
Significantly, these constants exist as commands rather than variables and do not appear in the workspace. Nonetheless, variables with the same names may be defined (accidentally) and will take priority over the above assignments; for example, if a loop is set up as for i = 1:10, then the value of i is reassigned. The default ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access