A group of students at the Institute of Imaging and Computer Vision of the Technical University of Aachen, Germany, has developed a toolbox that allows for controlling MINDSTORMS NXT robots over MATLAB®, a numerical computing environment and programming language widely used in industry and academia. The toolbox, a result of a Project in Electrical Engineering and Information Technology called MATLAB meets LEGO Mindstorms,
"enables you to combine robot applications with complex mathematical operations and visualizations within MATLAB. This toolbox opens unlimited possibilities to provide the robots artifical intelligence and other improvements using the manifold MATLAB features and calculations for digital signal processing",
as the project's web site states.
The toolbox is licensed as OpenSource Software as part of the GNU GPL (GNU General Public License) and can be downloaded for free.