help-octave
[Top][All Lists]
Advanced

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

Question about how to use an existing octave function in a cc code


From: Wen-shiang Chen
Subject: Question about how to use an existing octave function in a cc code
Date: Thu, 5 Feb 2004 16:43:21 -0600

Sorry to ask such a newbie question!  I have very limited knowledge about
c++ programming and just start to learn how to program under octave.

My question is how to use existing octave functions, in this case, the
randn function, in my cc code?  The m-file looks like the following,
x=y+randn(2,10);
and my incomplete cc code looks like the follwing,
DEFUN_DLD (mycc, args, ,)
{
  Matrix x (2,10);
  Matrix y (2,10);

  x=y+??
}

So could someone shed some light for me on how to write
 x=y+randn(2,10);
in my cc code?  Thanks!

Wen-shiang Chen



-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.

Octave's home on the web:  http://www.octave.org
How to fund new projects:  http://www.octave.org/funding.html
Subscription information:  http://www.octave.org/archive.html
-------------------------------------------------------------



reply via email to

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