help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Get pointer to data in Matrix classes [possible solution]


From: José Luis García Pallero
Subject: Re: Get pointer to data in Matrix classes [possible solution]
Date: Thu, 12 Mar 2009 11:17:54 +0100

Hi,
Thanks for your answer. Sorry, I didn't know the fortran_vec() method. It not appears in liboctave.pdf. I don't understand exactly your words in "This will also correctly make a copy of the matrix if it is aliased". What is the meaning? Make a copy of the matrix or gets the pointer?

2009/3/12 Jaroslav Hajek <address@hidden>
The standard method for getting writable data pointer is (somewhat
unfortunately) called fortran_vec.
This will also correctly make a copy of the matrix if it is aliased.
Const-casting data () will work in your case (you've just created the
matrix, so you know that it's unaliased, but never do it on matrices
passed from outside).

regards

--
RNDr. Jaroslav Hajek
computing expert & GNU Octave developer
Aeronautical Research and Test Institute (VZLU)
Prague, Czech Republic
url: www.highegg.matfyz.cz



--
*****************************************
José Luis García Pallero
address@hidden
(o<
/ / \
V_/_
Use Debian GNU/Linux and enjoy!
*****************************************

reply via email to

[Prev in Thread] Current Thread [Next in Thread]