CSCE 990 (Spring 2006) Matlab Miscellany
(Thanks to Deng Kun for these pointers.)
- Matlab is available on cse. Its optimization package is called
optim.
- Matlab has a very good documentation system. Any Matlab function is
documented. For example if you type "help norm" at its command console, it
will display the syntax and meaning of function "norm". Another way of
getting its help is by its java based-help system,
which has everything from tutorial to language
guide to package documentation. To get help on the optimization package, type
help optim. You'll get a list of functions from the package. The
function most relevant to Homework 3 is quadprog.
- Tutorials:
- On calling Matlab from C/C++, Java, etc. and the other way around:
- It's really easy to use Java in Matlab. Matlab supports Java
classes, and anything in Java can be directly called in the Matlab environment.
(The best tutorial is its own documentation.)
- Another way to extend the functionality of matlab is to write C/C++
routines and compile them into a "mex" file which can in turn be called in
the Matlab environment.
- To e.g. use Matlab's built-in "lr"
decomposition function in a C/C++ environment, the easiest way is to use
Matlab's compiler to compile this function into a C/C++ source and add it
to other C/C++ source files.
Another option is that you can generate executable files directly from
Matlab .m files.
Note that
there are limitations on what we can do with this method. For
example, it's tricky how to compile code that draws graphics into a
C/C++ source file.
Return to the CSCE 990 (Spring 2006) Home Page
Last modified 16 August 2011.
Back