tags:

views:

169

answers:

2

Is there any standard library of Matrix in c. Which I can implement across the platform. If not then kindly tell me OS dependent libraries of Matrix.

+4  A: 

There are so many.

In particular, you might want to look at the GNU scientific library.

Alternatively, you can just implement your own matrix operations.


Re cross platform:

GSL is very cross platform. According to the site, it compiles on around 12 operating systems (Solaris, Linux, darwin, various *BSDs and something called a SR8000 Super Technical Server). I would guess it could be compiled on embedded systems as well. For windows, you can either use cygwin or Gsl for Windows.

Which platforms are you planning on using?

Seth
I actually want the standard library which I can implement across the platform.
Arman
+1 for Gnu Scientific Library
Amit
What do you mean by "which I can implement"? Don't you want a library that's *already* implemented so you can use it to do whatever you want with matrices?
Alok
@Arman - see updates above. GSL should run on just about anything.
Seth
+2  A: 

Meschach seems to be the only popular C-based matrix library. There are tons of C++ based matrix libraries however.

The main question however is for what purpose you need that library. If for mathematical linear algebra, you should rather find a linear algebra library, so you have all your operations in one place (BLAS based, for example spblas). If however you need matrix3 and matrix4 types for 3D calculations, you should try to find one that is optimized for 3x3 or 4x4 operations, like this one).

Kornel Kisielewicz