deleting rows or columns in GSL matrices

A

A

I am wondering if there's an efficient way of deleting rows or columns
of a gsl_matrix? The only way I can think of is copying individual
elements or may be rows, columns or sumatrices to a new matrix, then
free the original matrix and have the pointer of the original matrix
point towards the new matrix.

Any suggestions for making this better? How does MATLAB do similar
things in it's mwArray datatype?

Thanks,
A
 
L

Luke Meyers

A said:
I am wondering if there's an efficient way of deleting rows or columns
of a gsl_matrix?

What on earth is a gsl_matrix, and why do you imagine we know about it?
The only way I can think of is copying individual
elements or may be rows, columns or sumatrices to a new matrix, then
free the original matrix and have the pointer of the original matrix
point towards the new matrix.

Any suggestions for making this better?

Do you have a question about C++, or some code you'd like us to take a
look at?
How does MATLAB do similar things in it's mwArray datatype?

That's odd, I'm sure I had a copy of the MATLAB source code sitting
right here just a minute ago, right next to my hours of spare time to
answer off-topic questions. Where could they have gone?

Please read:
http://www.parashift.com/c++-faq-lite/how-to-post.html#faq-5.9

Luke
 
A

A

gsl_matrix is the data type of GNU Scientific Library. Since a lot of
people in the scientific community that programs in C++ use GSL, I
didn't mention in clearly. Does anyone out here know about GSL matrices
and can answer my query posted above?
 
H

hbar

A said:
I am wondering if there's an efficient way of deleting rows or columns
of a gsl_matrix? The only way I can think of is copying individual
elements or may be rows, columns or sumatrices to a new matrix, then
free the original matrix and have the pointer of the original matrix
point towards the new matrix.

Probably you are right as the following GSL documentation states no
implemented function for your task:

http://www.gnu.org/software/gsl/manual/html_node/Matrices.html#Matrices
Any suggestions for making this better?

Ask here:

http://www.gnu.org/software/gsl/#mailinglists

HTH,

thomas
 
L

Luke Meyers

A said:
gsl_matrix is the data type of GNU Scientific Library. Since a lot of
people in the scientific community that programs in C++ use GSL, I
didn't mention in clearly. Does anyone out here know about GSL matrices
and can answer my query posted above?

Please learn how to quote properly on Usenet.

Please read the FAQ for this newsgroup (I provided the link earlier:
parashift.com/c++-faq-lite) to learn why your query is not on-topic
here.

I'm sure you can find an appropriate GNU newsgroup in which to ask.
This one is for the C++ language itself, not support for particular
libraries (even GNU ones).

Luke
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,433
Messages
2,571,683
Members
48,796
Latest member
Greg L.

Latest Threads

Top