Feeds

Vanilla (0.9.3) is a product of Lussumo. More Information: Documentation, Community Support.
Bottom of Page
Makers and Making: Matlab & Octave-Like Vector Programming for Arduino-Due
  1.  
1 to 1 of 1
Jan 26th 2013
I'm very interested in programming complicated matrix operations in Arduino Due, but with the simplicity offered in Octave and Matlab. For example, the Kalman gain matrix (one of many implementations) is:

K = Pp * H' * inv(H * Pp * H' + R);

Implementing the above in standard C/C++ would be very complicated, very messy, and difficult to read. In Matlab or Octave, the code is literally the above equation. I literally copied it from one my programs. This syntax is known as vector programming - it's a huge time saver.

Various libraries exist (links below) that allow such syntax in C/C++. A noteable one is the Eigen library. And I got it to work on the Arduino Due. Detailed instructions can be found at adafruit:

http://forums.adafruit.com/viewtopic.php?f=8&t=35959&start=15#p180113

or at arduino.cc :

http://arduino.cc/forum/index.php/topic,143602.msg1089368.html#msg1089368
  1.  
1 to 1 of 1
Top of PageBack to Discussions