Roger's Matlab Stuff






LEFT: A colormap image generated for fun using transforms in Matlab. RIGHT: A scale = 1 image of the Mandelbrot set generated with mandel.m (below).



Do you use Matlab?



If so, you may find some of these files useful. They are standard .m-files which you can download and place into a directory under \matlab\toolbox(\matlab)\DIRNAME
Then add a line to your MATLABRC.M file under the MATLABPATH statement like:
'C:\MATLAB\TOOLBOX\DIRNAME',...




Roger's Bag of Magic Tricks
All files by Roger McNichols
Texas A&M University



General Interest

linreg - linear regression for vectors or matrices
sinc - sin(x)/x for a vector or matrix
rdft - Roger's slow DFT routine
rdft2 - Rogers slow 2-D DFT routine
efdiff - explicit formulation forward difference PDE solver


Wavelet Transforms

wavewin - Windowing function for the wavelet transform
wavelet - Wavelet transform of a function


Spectrum Operations

smooth - performs n-point smoothing on spectra
ddif - double differentation of spectra (among other things...)
lorentz - creates a lorentzian band of unit area and specified bandwidth, centered at lambda
gauss2 - creates a gaussian window to user specs
ndiff - differentiates n times saving constants for reconstruction
denoise - a unique way of cleaning spectra
autophas - performs automatic phase correction on complex NMR spectra

Fuzzy Control/Simulation

flsim - lsim but using feedback with fuzzy rule-base
fltitr - external kernal function for flsim
URUL1 - Sample fuzzy logic controller

Electromagnetic Stuff

incoil - allows user to draw coil for field analysis
outcoil - displays the above coil
bcoil - calculates and plots the magnetic field produced by a specified coil pattern

Miscellaneous/Zany

airy - creates and airy disk [(J1(r)/r)^2] over a specified domain
phallus - constructs a uniquie 3-D plot
f - a short-cut for typing figure(n)
shg - exactly what it should be!
shit - makes you feel better
moron - turns on the MORE filter
mandel - generates the Mandelbrot set and allows zooming

contents.m - The helpfile for this 'toolbox'


Linux users: Check out OCTAVE! a Matlab clone.



Take Me Back to Roger's Home Page.