plot_complex.m
plot_complex(in, FigNum, Option, Title)
difff.m
difff(data0, data1, Title0, Title1, option)
help [plot] show matlab help page for command "plot" figure(n) make figure n the current plot destination clf clear the current plot plot plot x vs. y, e.g., plot([1:5], [0:10:40], 'ro--') hold execute after first plot() to print multiple functions on one plot axis set range of axes for plots, e.g., axis([0 pi -1 1]) grid on turns on plot's grid xlabel print x axis label e.g., xlabel('phase (radians)') ylabel print y axis label conv convolve two sequences .* term-by-term multiply of two vectors ./ term-by-term divide of two vectors keyboard Invoke interactive debugging mode from a .m file .' Transpose row ↔ column without performing a conjugate (use this) ' Transpose with a conjugate (don't use this) Examples: >> a = [1 + i, 2 + i] % row vector a = 1.0000 + 1.0000i 2.0000 + 1.0000i >> a.' ans = 1.0000 + 1.0000i 2.0000 + 1.0000i >> a' ans = 1.0000 - 1.0000i 2.0000 - 1.0000i
Matlab does not support an index of zero in arrays (in my opinion, this is the single greatest drawback/mistake of matlab).
In many cases, indexing down to zero is extremely convenient, such as when modeling the addressing of a memory. In these cases, I recommend calculating addresses as normal, and then adding "+1" whenever reading or writing the memory, for example:
addr = ....; b = mem(addr+1) * 2; mem(addr+1) = c + d;
2019/03/06 Written 2019/03/12 Moved functions and apps to this page 2024/03/08 Added drawbar.m 2025/03/16 Some edits, moved functions to top