revUp - Updates and news for the LiveCode community
Issue 158 | October 4th 2013 Contact the Editor | How to Contribute

Matrix ReCoded
A LiveCode Library with over 40 matrix manipulation commands

by Constantina Spanoude

Matrix ReCoded is the latest addition to LiveCode Marketplace, and available now in store here.

LiveCode programmers may need specialized mathematical operations. For example, our Ekkotek team is developing software that requires processing of vector images such as rotation, resizing, displacement etc. We also work on a social networking environment that processes peoples' ideas using matrix mathematics. To fulfill our needs, we have developed a library of matrix functions and handlers, which we continuously extend to include additional functions. Since we imagine that other LiveCode programmers may be in need of such commands, we packaged our functions and handlers into a Library, which we are now making available through the LiveCode Store.

Matrix ReCoded 1.0 is a library of 30 functions and 12 handlers that manipulate matrices. LiveCode has a number of commands to deal with matrices, but it is not a mathematical language. Matrix ReCoded extends Livecode's capabilities and opens it to those who might wish to develop mathematical or engineering solutions or simulations, or even vector-based drawing packages. Users, who might require commands not implemented yet, may contact Ekkotek with their special request.


Searching the Library (click to zoom)

Matrix ReCoded Help Stack provides help for the syntax of all functions and handlers used in Matrix ReCoded Library. Matrix ReCoded Help Stack also provides a search field for directly finding information about the syntax of all functions and handlers used in Matrix Recoded Library.

Creating a Matrix

Creating a Matrix (click to zoom)

Matrix ReCoded library provides various commands for creating n x m matrices. Specifically, a user can create a:

  • Blank Matrix
  • Zero Matrix
  • Random Matrix (1-10)
  • Random Binary Matrix
  • Identity Matrix

Transforming matrix

Transforming a Matrix (click to zoom)

Once a Matrix is generated, Matrix ReCoded library allow the user to transform it. Specifically, the user can:

  • Add Edge
  • Transpose
  • Fill the main diagonal with 0's or 1's
  • Add row/column
  • Delete row/column

performing operation

Performing Operations (click to zoom) 

Matrix ReCoded library provides various commands for performing different operations on two or more matrices. Specifically, a user can perrfom several matrix transformations:

  • Addition
  • Subtraction
  • Multiplication
  • Entry - Wise Multiplication
  • Entry - Wise Right/Left Division
  • Binary Addition

Vector Graphics

Stretching, Scaling or Rotating Vector Graphics (click to zoom)

Matrix ReCoded library also provides an easy way to stretch, scale or rotate a vector graphic using some of the matrix operations. This is a useful tool to represent images in an application. The tranformations supported in Matrix ReCoded are:

  • Translation (Stretching)
  • Scaling
  • Rotation

Matrix ReCoded 1.0 comes with a very detailed Help Stack. More importantly, included is an interactive Demo Stack that allows the user to actually view how the commands operate and test his/her ideas before even s/he starts to code. Download it now to see the commands in action. NOTE: Matrix ReCoded requires the LiveCode Commercial edition. It is incompatible with the free LiveCode edition.


About the Author

Constantina Spanoude is an expert in Applied Mathematics and Scientific Computing. She has a BSc in Math and an MSc in Computer Science and is a LiveCode programmer working for Ekkotek Ltd.


Main Menu

What's New

App To Market